]> git.0x19.co - doomgeneric-snom360/commit
linuxvt: various framebuffer improvements
authortechflashYT <officialTechflashYT@gmail.com>
Sun, 10 Aug 2025 09:37:43 +0000 (02:37 -0700)
committertechflashYT <officialTechflashYT@gmail.com>
Sun, 10 Aug 2025 09:43:02 +0000 (02:43 -0700)
commitc1b8396c324f3a1ec507407069002f049b4dd328
tree7359f8760bdbf5f23b33acd6a483b62ecd1bf7cd
parent5041246e859052e2e258ca6edb4e1e9bbd98fcf5
linuxvt: various framebuffer improvements

2 main improvements coming in here:
- Handling for nonstandard stride values, since some devices have
  non-linear framebuffers, and the previous assumption, that
  stride = width * bytesPerPixel, no longer necessarily holds true.
  This distinction doesn't matter for many devices (and thus, it can
  fall back to the former assumption if checking the real stride fails),
  but for those where it does matter (e.g. the NVIDIA Jetson Orin Nano I
  just tried it on), it does indeed make the game display correctly,
  whereas it didn't before.
- Clean up the pointer math needed to center the image on screen a bit.
  It was previously a bit of a mess, this version should be marginally
  faster, and much easier to read/understand.
doomgeneric/doomgeneric_linuxvt.c