public static class ParticleSpriteMaterialThe material a particle is drawn with, with every parameter its shader declares.
Remarks
One place, because a host that builds this by hand and forgets a parameter gets an effect that simulates, expands, uploads, binds a material set and draws — and produces nothing on the screen. Every counter reads healthy. That is what happened when the embers stopped appearing.
⚠ Setting every parameter is belt and braces, not a workaround. It used to be necessary: Raven reported a declared default only for scalars, because a scalar's is a literal and a vector's is a construction — so ParticleSpriteKeys.Tint carried nothing and EffectConstants wrote (0, 0, 0, 0), which is black at zero alpha and invisible under an additive blend. ConstantEvaluator folds a vector construction now and the key carries its float4(1f, 1f, 1f, 1f), so an unset tint would come out right on its own.
It is still written out here, because what this method is for is being the one answer to "what does a particle material start as" — and a method that set only the parameters the reflection cannot supply would be a list of the compiler's gaps rather than a description of a material.
Fields and properties (1)
public static Vector4 NeutralTintThe tint a particle keeps its own colour under.
Methods (1)
public static Material Default()A material that draws particles in their own colour, at their own brightness.
Used by (2)
- ParticleSpriteDeviceTestsVixen.Graphics.Golden.Tests
- WorldRendererVixen.Engine.Renderer