GrassLitConstants
public struct GrassLitConstantsThe values of GrassLit's uniform block, in C# types.
Remarks
Field order follows the shader's declaration order, not the block's byte order — the two differ wherever std140 inserted padding, and the writer knows the difference.
Fields and properties (30)
public Vector3 LightDirectionlightDirection at byte 0.
public float ShadowConstantBiasshadowConstantBias at byte 12.
public Vector3 LightColorlightColor at byte 16.
public float ShadowSlopeBiasshadowSlopeBias at byte 28.
public float ShadowFadeRangeshadowFadeRange at byte 32.
public float AmbientIntensityambientIntensity at byte 36.
public Matrix4x4 Viewview at byte 48.
public Vector3 EnvironmentShL00environmentSh.l00 at byte 432.
public Vector3 EnvironmentShL1m1environmentSh.l1m1 at byte 448.
public Vector3 EnvironmentShL10environmentSh.l10 at byte 464.
public Vector3 EnvironmentShL11environmentSh.l11 at byte 480.
public Vector3 EnvironmentShL2m2environmentSh.l2m2 at byte 496.
public Vector3 EnvironmentShL2m1environmentSh.l2m1 at byte 512.
public Vector3 EnvironmentShL20environmentSh.l20 at byte 528.
public Vector3 EnvironmentShL21environmentSh.l21 at byte 544.
public Vector3 EnvironmentShL22environmentSh.l22 at byte 560.
public Vector2 ShadowTexelSizeshadowTexelSize at byte 576.
public Matrix4x4 ViewProjectionviewProjection at byte 592.
public Vector3 ViewPositionviewPosition at byte 656.
public float Timetime at byte 668.
public Vector2 WindDirectionwind.direction at byte 672.
public float WindStrengthwind.strength at byte 680.
public float WindFrequencywind.frequency at byte 684.
public float WindSpeedwind.speed at byte 688.
public float WindFlutterwind.flutter at byte 692.
public float WindHeightwind.height at byte 696.
public float AlphaCutoffalphaCutoff at byte 704.
public Vector2 TintRangetintRange at byte 712.
public Vector2 FadeRangefadeRange at byte 720.
public const int SizeThe block's size in bytes.
Methods (1)
public readonly void Write(Span<byte> buffer)Writes every value into at its baked offset.
Used by (1)
- GrassDrawPassVixen.Rendering.Terrain