
A Scene currently encapsulates:
Public Member Functions | |
| void | SetRoot (vtGroup *pRoot) |
| Set the root node, the top node of the scene graph. | |
| void | SetGlobalWireframe (bool bWire) |
| Set global wireframe, which will force all objects to be drawn wireframe. | |
| bool | GetGlobalWireframe () |
| Get the global wireframe state. | |
| bool | Init (bool bStereo=false, int iStereoMode=0) |
| Call this method once before calling any other vtlib methods. | |
| void | Shutdown () |
| Call this method after all other vtlib methods, to free memory. | |
| float | GetFrameRate () |
| Return the instantaneous framerate in frames per seconds estimated. | |
| float | GetTime () |
| Time in seconds since the scene began. | |
| float | GetFrameTime () |
| Time in seconds between the start of the previous frame and the current frame. | |
| bool | CameraRay (const IPoint2 &win, FPoint3 &pos, FPoint3 &dir, vtWindow *pWindow=NULL) |
| void | WorldToScreen (const FPoint3 &point, IPoint2 &result) |
| void | ComputeViewMatrix (FMatrix4 &mat) |
|
||||||||||||||||||||
|
Convert window coordinates (in pixels) to a ray from the camera in world coordinates. Pixel coordinates are measured from the top left corner of the window: X right, Y down. |
|
|
Compute the full current view transform as a matrix, which includes the projection of the camera and the transform to window coordinates. This transform is the one used to convert XYZ points in world coodinates into XY window coordinates. By inverting this matrix, you can "un-project" window coordinates back into the world.
|
|
||||||||||||
|
Initialize the vtlib library, including the display and scene graph. You should call this function only once, before any other vtlib calls.
|
|
||||||||||||
|
Convert a point in world coordinates to a window pixel coordinate, measured from the top left corner of the window: X right, Y down. |
1.4.5