Description
The Camera
property of the Scene
class provides access to the CameraComponent
associated with the scene. This component is responsible for handling camera-related functionalities such as view and projection matrices, rendering settings, and other camera-specific operations within the scene.
Usage
To access the camera component of a scene, you can use the Camera
property. This allows you to manipulate camera settings or retrieve information about the current camera state.
Example
// Example of accessing the Camera property in a Scene
Scene currentScene = new Scene();
CameraComponent camera = currentScene.Camera;
// Example of modifying camera properties
camera.FieldOfView = 90.0f;
camera.Position = new Vector3(0, 0, 10);
camera.LookAt(Vector3.Zero);