%% one triangle of a draw with conservative rasterization on an M1 (Tier 1, no native support).
flowchart TD
A["Draw with
ConservativeRaster ON"] --> B["Vertex shader
captures its outputs"]
B --> C["Object function:
one thread per triangle"]
C --> D{"w > 0 and
area > 0?"}
D -- no --> E["Emit the triangle
unchanged"]
D -- yes --> F["Clip the pixel-aligned box
against the edges
moved out by h:
1/2 + 1/256, or
1 + 1/256 with MSAA"]
F --> G["Snap to 1/256,
weights λ and β"]
G --> H["Blend attributes,
emit a strip of
up to 7 vertices"]
E --> I["Metal rasterizes"]
H --> I
I --> J{"MSAA?"}
J -- "1x" --> K["Pixel shader"]
J -- "MSAA" --> L["Discard pixels whose
edge functions are < 0"]
L --> K