kismetlafiete
Programmer
So, I can get into mode 13h and use BIOS interrupts to handle drawing pixels, but it seems to be pretty slow. After doing a bit of internet research, I have read that it would be faster to do it in memory by using the equation
"Mem [VGA:X+(Y*320)]=Color;
where VGA is the starting point $a000, the base of the VGA's
memory"
so, how do I do this in assembly, assuming the calculation for x+y*320 has already been performed and the result stored in some arbitrary register, say bx.
According to my textbook, something like this should be as simple as storing a000h in ES (a000 is the segment I need, correct?), then doing something like
mov[es:bx], color
I can't get this to work correctly though, so what am I doing wrong?
I am using NASM, if that helps any.
"Mem [VGA:X+(Y*320)]=Color;
where VGA is the starting point $a000, the base of the VGA's
memory"
so, how do I do this in assembly, assuming the calculation for x+y*320 has already been performed and the result stored in some arbitrary register, say bx.
According to my textbook, something like this should be as simple as storing a000h in ES (a000 is the segment I need, correct?), then doing something like
mov[es:bx], color
I can't get this to work correctly though, so what am I doing wrong?
I am using NASM, if that helps any.