Skip to content

CameraComponent

class · namespace Hazel · Component

Inherits Component

public class CameraComponent : Component

Properties

OrthographicFarClip

public float OrthographicFarClip { get; set; }

OrthographicNearClip

public float OrthographicNearClip { get; set; }

OrthographicSize

public float OrthographicSize { get; set; }

PerspectiveFarClip

public float PerspectiveFarClip { get; set; }

PerspectiveNearClip

public float PerspectiveNearClip { get; set; }

Primary

public bool Primary { get; set; }

ProjectionType

public CameraComponentType ProjectionType { get; set; }

VerticalFOV

public float VerticalFOV { get; set; }

Methods

GetRayDirection(Vector2)

public Vector3 GetRayDirection(Vector2 screenPos)

SetOrthographic(float, float, float)

public void SetOrthographic(float size, float nearClip, float farClip)

SetPerspective(float, float, float)

public void SetPerspective(float verticalFov, float nearClip, float farClip)

ToScreenSpace(Vector3)

public Vector2 ToScreenSpace(Vector3 worldTranslation)

Source: Hazel/Scene/Components.cs