Vixen
dd8b0a81
csharp
public sealed class DrawList

A frame's worth of drawing, and whether it differs from the last one.

No guide page documents this yet — the page shows what the code says about itself.

Remarks

Doc 09 asks for the list to be diffed at the command level so that a static user interface re-submits a cached command buffer instead of rebuilding one. That is what Version is: it changes when the drawing changes and not when the drawing is merely rebuilt, so a renderer can compare one integer instead of a list.

⚠ The comparison is against the previous content, not against a dirty flag. A flag says what the framework believes changed; this says what actually did — and the two part company exactly when something is invalidated too eagerly, which is the failure a cache is supposed to absorb rather than propagate.

Fields and properties (11)

  • public IReadOnlyList<DrawCommand> Commands

    The commands, in the order they are drawn.

  • public IReadOnlyList<PositionedGlyph> Glyphs

    Every glyph of every text command, back to back.

  • public IReadOnlyList<PathSegment> Segments

    Every step of every path, back to back.

  • public IReadOnlyList<BoxStyle> Boxes

    The styles of the boxes that needed one.

  • public IReadOnlyList<UiMask> Masks

    Every mask of every composited group, back to back.

  • public IReadOnlyList<FontFace> Fonts

    The faces the text commands refer to, in the order they were first used.

  • public IReadOnlyList<DrawBatch> Batches

    The commands grouped into runs a renderer can submit together.

  • public int Batched

    How many times the batches have been rebuilt.

  • public int Version

    Bumped whenever the commands differ from the previous frame's.

  • public bool ChangedLastFrame

    Whether the last EndFrame changed anything.

  • public int Count

    How many commands the frame has so far.

Methods (8)

  • public void BeginFrame()

    Starts collecting a frame.

  • public void Add(DrawCommand command)

    Adds a command.

  • public int AddGlyphs(List<PositionedGlyph> run)

    Puts a run of glyphs in the side buffer.

  • public int AddBox(BoxStyle style)

    Puts a box's style in the side buffer.

  • public int AddMasks(ReadOnlySpan<UiMask> list)

    Puts a group's mask list in the side buffer.

  • public int AddPath(PathBuilder path)

    Puts a path in the side buffer.

  • public int AddFont(FontFace font)

    Finds or adds a font.

  • public bool EndFrame()

    Finishes a frame and works out whether anything moved.

Used by (78, showing 40)

  • EditorShellBenchmarksVixen.Benchmarks.Ui
  • BackdropFilterTestsVixen.Ui.Controls.Tests
  • BatchTestsVixen.Ui.Tests
  • BidiMirroringTestsVixen.Ui.Tests
  • BorderLonghandTestsVixen.Ui.Tests
  • BorderStyleTestsVixen.Ui.Tests
  • ColorPickerFocusRingTestsVixen.Ui.Controls.Advanced.Tests
  • ContainmentTestsVixen.Ui.Tests
  • DrawContextVixen.Ui
  • DrawContextBoxTestsVixen.Ui.Tests
  • DrawListBuilderVixen.Ui
  • DrawListTestsVixen.Ui.Tests
  • DrawnLayerTextTestsVixen.Ui.Tests
  • EditorShellBudgetTestsVixen.Ui.Controls.Advanced.Tests
  • FillRuleTestsVixen.Ui.Testing.Tests
  • FilterBlurTestsVixen.Ui.Controls.Tests
  • FilterColourTestsVixen.Ui.Controls.Tests
  • FilterDropShadowTestsVixen.Ui.Controls.Tests
  • FontFallbackTestsVixen.Ui.Tests
  • ForcedColorsTestsVixen.Ui.Tests
  • GradientTestsVixen.Ui.Tests
  • GroupOpacityTestsVixen.Ui.Controls.Tests
  • HudLuminanceDeviceTestsVixen.Graphics.Golden.Tests
  • HudLuminanceTestsVixen.Ui.Controls.Tests
  • IconAtlasTestsVixen.Ui.Tests
  • IdleFrameWorkTestsVixen.Ui.Tests
  • ImageNineSliceTestsVixen.Ui.Controls.Tests
  • ImageViewBarTestsVixen.Ui.Controls.Advanced.Tests
  • ImageViewTestsVixen.Ui.Controls.Advanced.Tests
  • InlineFragmentPaintingTestsVixen.Ui.Tests
  • InterfaceInAWorldTestsVixen.Engine.Renderer.Tests
  • MaskGradientTestsVixen.Ui.Controls.Tests
  • MixBlendModeLuminanceTestsVixen.Ui.Controls.Tests
  • NineSliceImageTestsVixen.Ui.Tests
  • ObjectFitTestsVixen.Ui.Controls.Tests
  • OrderTestsVixen.Ui.Tests
  • OverflowTestsVixen.Ui.Tests
  • PathTessellationCacheTestsVixen.Ui.Tests
  • PathTestsVixen.Ui.Tests
  • RasterizerTestsVixen.Ui.Testing.Tests