void Dispose()

book_4_sparkGenerated
code_blocksInput

Description

The Dispose method of the SceneCamera class is used to release all resources used by the camera. This method is crucial for managing memory and ensuring that resources are properly cleaned up when the camera is no longer needed. It is a sealed method, meaning it cannot be overridden in derived classes.

Usage

Call the Dispose method when you are finished using the SceneCamera instance. This will free up resources and prevent memory leaks. After calling Dispose, the camera should not be used again.

Example

// Example of using the Dispose method
SceneCamera camera = new SceneCamera();

// Use the camera for rendering or other operations

// Once done, dispose of the camera
camera.Dispose();

// After disposing, the camera should not be used again