You are not logged in.
I haven't looked into VGA fonts yet, sorry, I'm no help. I think Dex may have done some though...
Offline
Vga fonts never look great as the pixels are too big, you can make them look better by using lots of color, but you will never get small mode 13h fonts to look good.
I have code for vga fonts that use bits for each pixel (eg: 1 = a pixel, 0= space) which is smaller than your code, but would look the same.
here is the same fonts one in vga mode:
http://jas2o.forthworks.com/index.php?s … nshots#pic
and this one in vesa mode:
http://jas2o.forthworks.com/index.php?s … nshots#pic
one looks better, but it just the screen size the is differant.
So let me know if you want code.
Offline
If you go here: http://board.flatassembler.net/topic.ph … p;start=50
and get "CdPod" the fasm code may help you with vesa port for BOS, as its only 512bytes.
Any ???, about vesa just ask ;-).
NOTE: I was called "ASHLEY4" when i wrote that code.
Offline
Once you have set vesa up you will find it as easy as vga modes to program for.
First you test for vesa (in realmode) and set it up like this:
mov dword [VESAInfo_Signature],'VBE2' mov ax,4f00h ; Is Vesa installed ? mov di,VESA_Info ; This is the address of our info block. int 10h cmp ax,004Fh ; Is vesa installed ?, jne near NoVesa2 ; If not print a mesage & quit. mov ax,4f01h ; Get Vesa Mode information. mov di,Mode_Info ; This is the address of how info block. mov cx,0x4101 ; 4112h = 32/24bit ; 0x4101 = 8bit ;4111h = 15bit (640*480) and cx,0xfff int 10h cmp dword [VESAInfo_Signature], 'VESA' jne near NoVesa2 cmp byte [VESAInfo_Version+1], 2 jb NoVesa2 ; VESA version below 2.0
The above code will test for vesa2 and set up 640x480 x 256color, or jump to error code to print a error message (error message is not included in the above code).
If the above code is sucessfull it fills out the "VESA_Info" and "Mode_Info".
Once in pmode to plot a pixel we do this
mov edi,[ModeInfo_PhysBasePtr] ; This is = to mov edi,0xA0000 in vga add edi, 640*6 ; This is = to x = 0, y = 6 mov al,0x09 ; Color of pixel stosb ; Put whats in al at es:edi
To fill the screen to white, we do this:
mov edi,[ModeInfo_PhysBasePtr] mov ecx,640*480 ; Size of screen mov al,0xff ; This is for the color of one pixel rep stosb
NOTE: we could make the above code a little faster by doing this
mov edi,[ModeInfo_PhysBasePtr] mov ecx,640*480/4 ; Size of screen mov eax,0xffffffff ; This is for the color of one pixel rep stosd
Here are some things to remember 1. you should start like the above, but latter use off screen buffers, 2. if you use a 24bit mode some graphic cards use 24bit others use 32bit, you need to test for this and use differant code.
Also unless you can go to real mode or call realmode int's you will be stuck in the vesa mode you set up in realmode.
Hope this helps.
Offline
Pages: 1