Description
The World
property of the SceneCamera
class specifies the SceneWorld
instance that the camera will render. This property is essential for determining which world context the camera is operating in, allowing it to render the appropriate scene objects and environment.
Usage
To use the World
property, you need to have an instance of SceneCamera
. You can then get or set the World
property to specify which SceneWorld
the camera should render.
Example
// Create a new SceneCamera instance
SceneCamera camera = new SceneCamera();
// Create or get a SceneWorld instance
SceneWorld myWorld = new SceneWorld();
// Assign the SceneWorld to the camera's World property
camera.World = myWorld;
// Now the camera will render the specified SceneWorld
// You can also retrieve the current SceneWorld
SceneWorld currentWorld = camera.World;