softgpu: Combine sliced rectangles.

This mostly affects clears, and reduces overhead.  Only about 2%
improvement, but it's a small change.
This commit is contained in:
Unknown W. Brackets committed 2021-11-14 18:31:46 -08:00
1 parent 0281e2f017
commit 2ab7499d8d
3 files changed
+44

No files matched your search

+7
View File
@@ -425,6 +425,13 @@ void TransformUnit::SubmitPrimitive(void* vertices, void* indices, GEPrimitiveTy
}
}
if (data_index == 4 && gstate.isModeThrough()) {
if (Rasterizer::DetectRectangleSlices(data)) {
data[1] = data[3];
data_index = 2;
}
}
if (data_index == 4) {
Clipper::ProcessRect(data[0], data[1]);
Clipper::ProcessRect(data[2], data[3]);