docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class XRBuiltinShaderConstants

    Helper static class used by render pipelines to setup stereo constants accessed by builtin shaders.

    Inheritance
    object
    XRBuiltinShaderConstants
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEngine.Experimental.Rendering
    Assembly: Unity.RenderPipelines.Core.Runtime.dll
    Syntax
    public static class XRBuiltinShaderConstants

    Fields

    Name Description
    unity_StereoCameraInvProjection

    Cached unique id for unity_StereoCameraInvProjection

    unity_StereoCameraProjection

    Cached unique id for unity_StereoCameraProjection

    unity_StereoMatrixInvP

    Cached unique id for unity_StereoMatrixInvP

    unity_StereoMatrixInvV

    Cached unique id for unity_StereoMatrixInvV

    unity_StereoMatrixInvVP

    Cached unique id for unity_StereoMatrixInvVP

    unity_StereoMatrixP

    Cached unique id for unity_StereoMatrixP

    unity_StereoMatrixV

    Cached unique id for unity_StereoMatrixV

    unity_StereoMatrixVP

    Cached unique id for unity_StereoMatrixVP

    unity_StereoWorldSpaceCameraPos

    Cached unique id for unity_StereoWorldSpaceCameraPos

    Methods

    Name Description
    SetBuiltinShaderConstants(RasterCommandBuffer)

    Bind the shader constants used by the C++ builtin renderer via a raster command buffer. UpdateBuiltinShaderConstants should be called before to update the constants. This is required to maintain compatibility with legacy code and shaders.

    SetBuiltinShaderConstants(CommandBuffer)

    Bind the shader constants used by the C++ builtin renderer via a command buffer. UpdateBuiltinShaderConstants should be called before to update the constants. This is required to maintain compatibility with legacy code and shaders.

    Update(XRPass, CommandBuffer, bool)

    Update and bind shader constants used by the C++ builtin renderer given the XRPass. For better control of setting up builtin shader constants, see UpdateBuiltinShaderConstants and SetBuiltinShaderConstants which do the same logic but could take in custom projection and view matricies instead. This is required to maintain compatibility with legacy code and shaders.

    UpdateBuiltinShaderConstants(Matrix4x4, Matrix4x4, bool, int)

    Update the shader constant data used by the C++ builtin renderer.

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)