Mail Archives: djgpp/1998/09/07/22:45:19
Ludvig Larsson wrote:
> BTW, I had some problem with those VESA 1.2 modes because they are Not
> always compatible with VESA 2.0 One thing that worked for me was to set
> the bit in the for the lineframe buffer(why it works, I have no idéa,
> but it does, using banks). So mode 0x100 will be 0x4100 etc.
> The best thing offcourse, to make the code work on well almost all cards
> is to scan the card for the desired graphic mode.
As far as I know, this will work on EVERY VESA 1.2+ card.
> Ps. to plot a pixel: (in 640xNNN in 256color mode)
> bank=(x+y*640)>>16
> offset=(x+y*640)-bank<<16
> set bank to 'bank' and
> put the colorvalue at 0xA0000+offset
That is making the assumption that bank's have a 64k granularity (which they
do not always have! Most Cirrus Logic cards do NOT have this, they us 4k/16k
granularity). You will have to check to see the bank-size before knowing how
much to bitshift by.
--
(\/) Endlisnis (\/)
s257m AT unb DOT ca
Endlisnis AT GeoCities DOT com
Endlis AT nbnet DOT nb DOT ca
- Raw text -