doomgeneric icon indicating copy to clipboard operation
doomgeneric copied to clipboard

Rotate n relocate

Open rautonkar opened this issue 1 year ago • 1 comments

Relocating buffers into bss if desired.

Added simple changes which should prevent malloc if pointer is already assigned during DG_Init. This applies to both I_VideoBuffer and DG_ScreenBuffer.

Added in code to rotate the buffer

Clockwise buffer rotation is disabled by default. Can be turned on by enabling the preprocessor in the i_video.c file or by adding in a compiler preprocessor flag ROTATE_SCREENBUFFER. By manipulating at cmap; you can bypass the need to create a third buffer and a copy operation which will degrade performance. The code is not tested at higher resolutions.

rautonkar avatar Jan 23 '24 08:01 rautonkar

I was goint to merge this but when I tested the code, it gave me this even in 320x200 resolution:

image

I think this would add value to doomgeneric as it could be useful in some embedded environments.

ozkl avatar Apr 27 '24 13:04 ozkl