docs.unity3d.com
    目次を表示する/隠す

    Class ShaderUtils

    Various utility functions for shaders in URP.

    Inheritance
    Object
    ShaderUtils
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: UnityEngine.Rendering.Universal
    Syntax
    public static class ShaderUtils

    Methods

    GetEnumFromPath(String)

    Retrieves a URP Shader Path ID from a path given.

    Declaration
    public static ShaderPathID GetEnumFromPath(string path)
    Parameters
    Type Name Description
    String path

    The path to the shader.

    Returns
    Type Description
    ShaderPathID

    The URP Shader Path ID.

    GetShaderPath(ShaderPathID)

    Retrieves a shader path for the given URP Shader Path ID.

    Declaration
    public static string GetShaderPath(ShaderPathID id)
    Parameters
    Type Name Description
    ShaderPathID id

    The URP Shader Path ID.

    Returns
    Type Description
    String

    The path to the URP shader.

    IsLWShader(Shader)

    Checks if a given shader is a URP shader or not.

    Declaration
    public static bool IsLWShader(Shader shader)
    Parameters
    Type Name Description
    Shader shader

    The shader.

    Returns
    Type Description
    Boolean

    True or false if it's a URP shader or not.

    トップに戻る
    Copyright © 2023 Unity Technologies — 商標と利用規約
    • 法律関連
    • プライバシーポリシー
    • クッキー
    • 私の個人情報を販売または共有しない
    • Your Privacy Choices (Cookie Settings)