docs.unity.cn
    Show / Hide Table of Contents

    Class GenerateHLSL

    Attribute specifying that HLSL code should be generated.

    Inheritance
    Object
    Attribute
    GenerateHLSL
    Inherited Members
    Attribute.GetCustomAttributes(MemberInfo, Type)
    Attribute.GetCustomAttributes(MemberInfo, Type, Boolean)
    Attribute.GetCustomAttributes(MemberInfo)
    Attribute.GetCustomAttributes(MemberInfo, Boolean)
    Attribute.IsDefined(MemberInfo, Type)
    Attribute.IsDefined(MemberInfo, Type, Boolean)
    Attribute.GetCustomAttribute(MemberInfo, Type)
    Attribute.GetCustomAttribute(MemberInfo, Type, Boolean)
    Attribute.GetCustomAttributes(ParameterInfo)
    Attribute.GetCustomAttributes(ParameterInfo, Type)
    Attribute.GetCustomAttributes(ParameterInfo, Type, Boolean)
    Attribute.GetCustomAttributes(ParameterInfo, Boolean)
    Attribute.IsDefined(ParameterInfo, Type)
    Attribute.IsDefined(ParameterInfo, Type, Boolean)
    Attribute.GetCustomAttribute(ParameterInfo, Type)
    Attribute.GetCustomAttribute(ParameterInfo, Type, Boolean)
    Attribute.GetCustomAttributes(Module, Type)
    Attribute.GetCustomAttributes(Module)
    Attribute.GetCustomAttributes(Module, Boolean)
    Attribute.GetCustomAttributes(Module, Type, Boolean)
    Attribute.IsDefined(Module, Type)
    Attribute.IsDefined(Module, Type, Boolean)
    Attribute.GetCustomAttribute(Module, Type)
    Attribute.GetCustomAttribute(Module, Type, Boolean)
    Attribute.GetCustomAttributes(Assembly, Type)
    Attribute.GetCustomAttributes(Assembly, Type, Boolean)
    Attribute.GetCustomAttributes(Assembly)
    Attribute.GetCustomAttributes(Assembly, Boolean)
    Attribute.IsDefined(Assembly, Type)
    Attribute.IsDefined(Assembly, Type, Boolean)
    Attribute.GetCustomAttribute(Assembly, Type)
    Attribute.GetCustomAttribute(Assembly, Type, Boolean)
    Attribute.Equals(Object)
    Attribute.GetHashCode()
    Attribute.Match(Object)
    Attribute.IsDefaultAttribute()
    Attribute._Attribute.GetTypeInfoCount(UInt32)
    Attribute._Attribute.GetTypeInfo(UInt32, UInt32, IntPtr)
    Attribute._Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)
    Attribute._Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)
    Attribute.TypeId
    Object.ToString()
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: UnityEngine.Rendering
    Syntax
    [AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Enum)]
    public class GenerateHLSL : Attribute, _Attribute

    Constructors

    GenerateHLSL(PackingRules, Boolean, Boolean, Boolean, Int32, Boolean, Boolean, Boolean, Int32, String)

    GenerateHLSL attribute constructor.

    Declaration
    public GenerateHLSL(PackingRules rules = PackingRules.Exact, bool needAccessors = true, bool needSetters = false, bool needParamDebug = false, int paramDefinesStart = 1, bool omitStructDeclaration = false, bool containsPackedFields = false, bool generateCBuffer = false, int constantRegister = -1, string sourcePath = null)
    Parameters
    Type Name Description
    PackingRules rules

    Packing rules.

    Boolean needAccessors

    Need accessors.

    Boolean needSetters

    Need setters.

    Boolean needParamDebug

    Need debug defines.

    Int32 paramDefinesStart

    Start value of debug defines.

    Boolean omitStructDeclaration

    Omit structure declaration.

    Boolean containsPackedFields

    Contains packed fields.

    Boolean generateCBuffer

    Generate a constant buffer.

    Int32 constantRegister

    When generating a constant buffer, specify the optional constant register.

    String sourcePath

    Location of the source file defining the C# type. (Automatically filled by compiler)

    Fields

    constantRegister

    If specified, when generating a constant buffer, use this explicit register.

    Declaration
    public int constantRegister
    Field Value
    Type Description
    Int32

    containsPackedFields

    Structure contains packed fields.

    Declaration
    public bool containsPackedFields
    Field Value
    Type Description
    Boolean

    generateCBuffer

    Generate constant buffer declaration or not.

    Declaration
    public bool generateCBuffer
    Field Value
    Type Description
    Boolean

    needAccessors

    Structure needs generated accessors.

    Declaration
    public bool needAccessors
    Field Value
    Type Description
    Boolean

    needParamDebug

    Structure needs generated debug defines and functions.

    Declaration
    public bool needParamDebug
    Field Value
    Type Description
    Boolean

    needSetters

    Structure needs generated setters.

    Declaration
    public bool needSetters
    Field Value
    Type Description
    Boolean

    omitStructDeclaration

    Generate structure declaration or not.

    Declaration
    public bool omitStructDeclaration
    Field Value
    Type Description
    Boolean

    packingRules

    Packing rules for the struct.

    Declaration
    public PackingRules packingRules
    Field Value
    Type Description
    PackingRules

    paramDefinesStart

    Start value of generated defines.

    Declaration
    public int paramDefinesStart
    Field Value
    Type Description
    Int32

    sourcePath

    Path of the generated file

    Declaration
    public string sourcePath
    Field Value
    Type Description
    String

    Extension Methods

    AnalyticsUtils.ToNestedColumnWithDefault<T>(T, T, Boolean)
    ReflectionUtils.Invoke(Object, String, Object[])
    ReflectionUtils.SetField(Object, String, Object)
    ReflectionUtils.GetField(Object, String)
    ReflectionUtils.GetFields(Object)
    Back to top Copyright © 2023 Unity Technologies — Terms of use
    Generated by DocFX
    on 08 September 2023