Doom8088 icon indicating copy to clipboard operation
Doom8088 copied to clipboard

Flat span performance improvement by completely ignoring visplanes

Open mindbleach opened this issue 2 years ago • 1 comments

By drawing solid color directly instead of searching for / adding to / rendering out an untextured visplane, overall performance with FLAT_SPAN is 10% faster. The memory used by visplanes (and visplane functions) is no longer required. This commit only reduces the number of visplanes allocated, though.

Additionally: unrolling R_DrawColumnFlat is 5% faster.

Additionally: a naive loop writing individual bytes was faster than an unrolled loop calling R_DrawColumnPixel. An unrolled loop writing individual bytes was faster still.

These are 32-bit Open Watcom results, in DOSbox-X, acting as a 25 MHz 386DX. Nonetheless it has gone from 14 FPS to 19 FPS on demo3.

mindbleach avatar Nov 25 '23 02:11 mindbleach

I've removed all visplanes. The sky is rendered as a regular texture.

FrenkelS avatar Dec 19 '23 23:12 FrenkelS