Roblox backend: flat triangle pairs a b c + a b d (ImPlot PrimRectFill: heatmap cells, bars; one colour, one uv) are one primitive (kind 5): per row both triangles' spans exactly as DrawTriangle computes them, one fill where they touch (opaque: or overlap), else each in order; pairs DrawTriangle would walk by columns, or degenerate ones, still go to the two calls (tile hash kind field * 8; replay: implot -3.5%; randomized 800k cases vs the two DrawTriangle calls identical; pixels identical)
This commit is contained in:
1 parent
5ae58c6b57
commit
620660ccf9
3 files changed
+242
-14
No files matched your search
@@ -180,10 +180,10 @@ function M.Tile(img, list, count: number, x0: number, y0: number, tox: number, t
|
||||
local vb = PrimVtxBuffer[p]
|
||||
copy(P, pn + REC_A, vb, PrimA[p], VTX)
|
||||
copy(P, pn + REC_C, vb, PrimC[p], VTX)
|
||||
if not d or gk == 3 then
|
||||
if not d or gk == 3 or gk == 4 then
|
||||
copy(P, pn + REC_B, vb, PrimB[p], VTX)
|
||||
end
|
||||
if gk == 3 then copy(P, pn + REC_D, vb, d, VTX) end
|
||||
if gk == 3 or gk == 4 then copy(P, pn + REC_D, vb, d, VTX) end
|
||||
pn += REC
|
||||
end
|
||||
writei32(T, to, poff[p])
|
||||
|
||||
Reference in new issue
Block a user