3 ms·
Does anyone know why VGA ”hacks" 320x240x256 and 320x400x256 modes operated planar instead of paged like 320x200x256? It makes sense for less than 8-bit per pi
by miohtama 8y ago
Does anyone know why VGA ”hacks" 320x240x256 and 320x400x256 modes operated planar instead of paged like 320x200x256?
It makes sense for less than 8-bit per pixel colour modes, but now for 256 colours.
Pondering this question after 20 years.
- pavlov 8y agoI think it had something to do with the 64K segment limit in real mode x86...?
- ajuc 8y agoYup, 320*240=76800 > 2^16=65536
- ska 8y agoI'd almost manage to forget about that. Almost.
- rasz 8y agoIf anything it would be ISA VGA being visible thru a 64KB aperture at A0000, and even that wasnt it. Why would you specifically program VGA into planar instead of nice "chunky" pages? It was an artifact of the way VGA CRTC worked.
- rasz 8y agoVGA CRTC could only address 64KB of ram at a time, so while you could program chunky 320x240, it would run out of ram and most likely repeat top of the picture somewhere at 85% of the screen. Planar hacks it into drawing pixels from different pages, something impossible to accomplish in chunky.
- tom_ 8y agoThe planar modes are how the chip operates naturally, and chain 4 is the hack (sort of! - I mean, chain 4 is of course how the system is designed to be used). There's a bit about this on the Wikipedia page: https://en.wikipedia.org/wiki/Mode_13h https://en.wikipedia.org/wiki/Mode_13h
- miohtama 8y agoExcellent! So it was related how the underlying memory chips are wired.