Modifica

Condividi tramite


CameraExtensions Class

Definition

Extension methods for the Unity's Camera class

public ref class CameraExtensions abstract sealed
public static class CameraExtensions
type CameraExtensions = class
Public Module CameraExtensions
Inheritance
CameraExtensions

Methods

GetDistanceForFrustumHeight(Camera, Single)

Gets the distance to the camera that a specific frustum height would be at.

GetFrustumSizeForDistance(Camera, Single)

Gets the frustum size at a given distance from the camera.

GetHorizontalFieldOfViewDegrees(Camera)

Get the horizontal FOV from the stereo camera in degrees

GetHorizontalFieldOfViewRadians(Camera)

Get the horizontal FOV from the stereo camera in radians

IsInFOV(Camera, Vector3)

Returns if a point will be rendered on the screen in either eye

IsInFOVCone(Camera, Vector3, Single)

Returns true if a point is in the a cone inscribed into the Camera's frustum, false otherwise The cone is inscribed to a radius equal to the vertical height of the camera's FOV. By default, the cone's tip is "chopped off" by an amount defined by the camera's far and near clip planes.

Applies to