when i use 600 * 480 * 2 color mode we use one bit for a pixel..
but how is it working in 600*480* 16 color mode.. ??
it exceeds 0xBFFFF
another doubt in vga
- Combuster
- Member
- Posts: 9301
- Joined: Wed Oct 18, 2006 3:45 am
- Libera.chat IRC: [com]buster
- Location: On the balcony, where I can actually keep 1½m distance
- Contact:
Re: another doubt in vga
the vga has 256K ram. Between A0000 and AFFFF goes only 64k. Read VGA Hardware to see how your video card gets away with that.
Re: another doubt in vga
Exactly the same way. The VGA (and older EGA) has four layers of memory called 'planes'. Each plane is max. 64KB (640x480, the standard VGA mode, has 307200 or 300K pixels, with 1 pixel per bit that's 37,5KB of memory per plane). The pixel of one colour is, ultimately, determined by the 4 bits in each plane (2^4 = 16 possible colours per pixel). In 2 colour mode, the VGA is set up in such a way that a write will affect all 4 planes, so the only possible values are 1111b and 0000b. The standard pallet converts this into white and black, respectively.asdfgh wrote:when i use 600 * 480 * 2 color mode we use one bit for a pixel..
but how is it working in 600*480* 16 color mode.. ??
Having said that, the VGA hardware is insanely complex to use efficiently. So unless you really go for obsolete hardware, try VESA instead. It'll give you millions of colours in a contigious frame buffer (in pmode at least). Far easier, far more usuable.
JAL