Class VertexAttributeAttribute
Namespace: ValveResourceFormat.Renderer
Assembly: Renderer.dll
Marks a vertex struct field as a shader input. The buffer format follows from the field type, see
.[AttributeUsage(AttributeTargets.Field)]
public sealed class VertexAttributeAttribute : AttributeInheritance
object ← Attribute ← VertexAttributeAttribute
Inherited Members
Attribute.Equals(object?), Attribute.GetCustomAttribute(Assembly, Type), Attribute.GetCustomAttribute(Assembly, Type, bool), Attribute.GetCustomAttribute(MemberInfo, Type), Attribute.GetCustomAttribute(MemberInfo, Type, bool), Attribute.GetCustomAttribute(Module, Type), Attribute.GetCustomAttribute(Module, Type, bool), Attribute.GetCustomAttribute(ParameterInfo, Type), Attribute.GetCustomAttribute(ParameterInfo, Type, bool), Attribute.GetCustomAttributes(Assembly), Attribute.GetCustomAttributes(Assembly, bool), Attribute.GetCustomAttributes(Assembly, Type), Attribute.GetCustomAttributes(Assembly, Type, bool), Attribute.GetCustomAttributes(MemberInfo), Attribute.GetCustomAttributes(MemberInfo, bool), Attribute.GetCustomAttributes(MemberInfo, Type), Attribute.GetCustomAttributes(MemberInfo, Type, bool), Attribute.GetCustomAttributes(Module), Attribute.GetCustomAttributes(Module, bool), Attribute.GetCustomAttributes(Module, Type), Attribute.GetCustomAttributes(Module, Type, bool), Attribute.GetCustomAttributes(ParameterInfo), Attribute.GetCustomAttributes(ParameterInfo, bool), Attribute.GetCustomAttributes(ParameterInfo, Type), Attribute.GetCustomAttributes(ParameterInfo, Type, bool), Attribute.GetHashCode(), Attribute.IsDefaultAttribute(), Attribute.IsDefined(Assembly, Type), Attribute.IsDefined(Assembly, Type, bool), Attribute.IsDefined(MemberInfo, Type), Attribute.IsDefined(MemberInfo, Type, bool), Attribute.IsDefined(Module, Type), Attribute.IsDefined(Module, Type, bool), Attribute.IsDefined(ParameterInfo, Type), Attribute.IsDefined(ParameterInfo, Type, bool), Attribute.Match(object?), Attribute.TypeId
Constructors
VertexAttributeAttribute(string, DXGI_FORMAT, int)
Marks a vertex struct field as a shader input. The buffer format follows from the field type, see
.public VertexAttributeAttribute(string name, DXGI_FORMAT format = DXGI_FORMAT.UNKNOWN, int location = -1)Parameters
name string
format DXGI_FORMAT
location int
VertexAttributeAttribute(VertexSlot, DXGI_FORMAT)
Marks a field supplying a mesh attribute.
[SuppressMessage("Design", "CA1019:Define accessors for attribute arguments", Justification = "The slot is exposed as its name")]
public VertexAttributeAttribute(VertexSlot slot, DXGI_FORMAT format = DXGI_FORMAT.UNKNOWN)Parameters
slot VertexSlot
format DXGI_FORMAT
Properties
Format
Gets the buffer format, or to derive it from the field type.
public DXGI_FORMAT Format { get; }Property Value
Location
Gets the location this field is pinned to, or -1 to let the layout place it. Pin it only to match a shader that declares its own layout (location = ...).
public int Location { get; }Property Value
Name
Gets the shader input name this field supplies.
public string Name { get; }
