Struct CameraData | Universal RP | 8.3.1
docs.unity3d.com
    Show / Hide Table of Contents

    Struct CameraData

    Inherited Members
    ValueType.Equals(Object)
    ValueType.GetHashCode()
    ValueType.ToString()
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetType()
    Namespace: UnityEngine.Rendering.Universal
    Syntax
    [MovedFrom("UnityEngine.Rendering.LWRP")]
    public struct CameraData

    Fields

    antialiasing

    Declaration
    public AntialiasingMode antialiasing
    Field Value
    Type Description
    AntialiasingMode

    antialiasingQuality

    Declaration
    public AntialiasingQuality antialiasingQuality
    Field Value
    Type Description
    AntialiasingQuality

    camera

    Declaration
    public Camera camera
    Field Value
    Type Description
    Camera

    cameraTargetDescriptor

    Declaration
    public RenderTextureDescriptor cameraTargetDescriptor
    Field Value
    Type Description
    RenderTextureDescriptor

    cameraType

    Declaration
    public CameraType cameraType
    Field Value
    Type Description
    CameraType

    captureActions

    Declaration
    public IEnumerator<Action<RenderTargetIdentifier, CommandBuffer>> captureActions
    Field Value
    Type Description
    IEnumerator<Action<RenderTargetIdentifier, CommandBuffer>>

    clearDepth

    Declaration
    public bool clearDepth
    Field Value
    Type Description
    Boolean

    defaultOpaqueSortFlags

    Declaration
    public SortingCriteria defaultOpaqueSortFlags
    Field Value
    Type Description
    SortingCriteria

    isDefaultViewport

    Declaration
    public bool isDefaultViewport
    Field Value
    Type Description
    Boolean

    isDitheringEnabled

    Declaration
    public bool isDitheringEnabled
    Field Value
    Type Description
    Boolean

    isHdrEnabled

    Declaration
    public bool isHdrEnabled
    Field Value
    Type Description
    Boolean

    isSceneViewCamera

    True if the camera rendering is for the scene window in the editor

    Declaration
    public bool isSceneViewCamera
    Field Value
    Type Description
    Boolean

    isStereoEnabled

    Declaration
    public bool isStereoEnabled
    Field Value
    Type Description
    Boolean

    isStopNaNEnabled

    Declaration
    public bool isStopNaNEnabled
    Field Value
    Type Description
    Boolean

    maxShadowDistance

    Declaration
    public float maxShadowDistance
    Field Value
    Type Description
    Single

    postProcessEnabled

    Declaration
    public bool postProcessEnabled
    Field Value
    Type Description
    Boolean

    renderScale

    Declaration
    public float renderScale
    Field Value
    Type Description
    Single

    renderType

    Declaration
    public CameraRenderType renderType
    Field Value
    Type Description
    CameraRenderType

    requiresDepthTexture

    Declaration
    public bool requiresDepthTexture
    Field Value
    Type Description
    Boolean

    requiresOpaqueTexture

    Declaration
    public bool requiresOpaqueTexture
    Field Value
    Type Description
    Boolean

    resolveFinalTarget

    True if this camera is resolving rendering to the final camera render target. When rendering a stack of cameras only the last camera in the stack will resolve to camera target.

    Declaration
    public bool resolveFinalTarget
    Field Value
    Type Description
    Boolean

    targetTexture

    Declaration
    public RenderTexture targetTexture
    Field Value
    Type Description
    RenderTexture

    volumeLayerMask

    Declaration
    public LayerMask volumeLayerMask
    Field Value
    Type Description
    LayerMask

    volumeTrigger

    Declaration
    public Transform volumeTrigger
    Field Value
    Type Description
    Transform

    Properties

    isPreviewCamera

    True if the camera rendering is for the preview window in the editor

    Declaration
    public bool isPreviewCamera { get; }
    Property Value
    Type Description
    Boolean

    Methods

    GetGPUProjectionMatrix()

    Returns the camera GPU projection matrix. This contains platform specific changes to handle y-flip and reverse z. Similar to GL.GetGPUProjectionMatrix but queries URP internal state to know if the pipeline is rendering to render texture. For more info on platform differences regarding camera projection check: https://docs.unity3d.com/Manual/SL-PlatformDifferences.html

    Declaration
    public Matrix4x4 GetGPUProjectionMatrix()
    Returns
    Type Description
    Matrix4x4
    See Also
    GetGPUProjectionMatrix

    GetProjectionMatrix()

    Returns the camera projection matrix.

    Declaration
    public Matrix4x4 GetProjectionMatrix()
    Returns
    Type Description
    Matrix4x4

    GetViewMatrix()

    Returns the camera view matrix.

    Declaration
    public Matrix4x4 GetViewMatrix()
    Returns
    Type Description
    Matrix4x4

    IsCameraProjectionMatrixFlipped()

    True if the camera device projection matrix is flipped. This happens when the pipeline is rendering to a render texture in non OpenGL platforms. If you are doing a custom Blit pass to copy camera textures (_CameraColorTexture, _CameraDepthAttachment) you need to check this flag to know if you should flip the matrix when rendering with for cmd.Draw* and reading from camera textures.

    Declaration
    public bool IsCameraProjectionMatrixFlipped()
    Returns
    Type Description
    Boolean
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023