Vixen
02b45cc4
csharp
public readonly record struct Blended

One field's contribution: what it wants to be, and how much of the way there.

Read the guide page for this →

Remarks

⚠ The weight has to travel with the value, and this pair is why PostProcessOverlay is a different type from PostProcessSettings. A volume half faded in wants half its offset — but half of the way from what? From the value the node was authored with, which lives in the node and not in the volume. So the fold cannot finish the interpolation, and a plain float? coming out of it would either lose the weight or bake it against a number the fold had to invent.

Different fields carry different weights, which rules out one weight for the whole struct: a volume fully inside can set the bloom while a second, half faded in, sets the contrast, and both are correct at once.

Fields and properties (2)

  • public float Value

    What the winning volume said.

  • public float Weight

    How much of the way from the authored value to that one, 0 to 1.

Methods (2)

  • public Blended(float Value, float Weight)

    One field's contribution: what it wants to be, and how much of the way there.

  • public float Over(float authored)

    This contribution laid over the value a document authored.

Used by (9)

  • BloomRendererVixen.Rendering.PostFx
  • DepthOfFieldRendererVixen.Rendering.PostFx
  • FogRendererVixen.Rendering.PostFx
  • LensFlareRendererVixen.Rendering.PostFx
  • LocalExposureRendererVixen.Rendering.PostFx
  • PostProcessOverlayVixen.Rendering
  • PostProcessVolumeTestsVixen.Rendering.Tests
  • TonemapRendererVixen.Rendering.PostFx
  • VignetteRendererVixen.Rendering.PostFx