PieKing1215 / ptcMod

Mod for pxtone Collage that adds some shiny features
Apache License 2.0
9 stars 1 forks source link

Improve vanilla ptc note rendering performance #15

Open PieKing1215 opened 2 years ago

PieKing1215 commented 2 years ago

Collage doesn't do any batching or caching for note rendering at all. Maybe it would be possible to add that.

PieKing1215 commented 2 years ago

Batching isn't really possible in 0.9.2.5 because it uses DirectDraw. However, completely replacing the note rendering loop with a custom one, rendering to a separate surface, and blitting it back to the primary surface is 2-3x faster than directly rendering the notes onto the primary surface (how vanilla does it). It should be possible to do batching in newer versions because they use d3d9, each fill_rect does its own DrawPrimitive call in vanilla.