Fonts.
Has anyone archived fonts constructed for the various propeller VGA drivers available?
Specifically, are there alternative versions of 8x8 fonts available?
Is there convenient code available for building a custom font?
Also, if a specific driver has a font definition in a DAT section of the program, what is required to point to the Propeller ROM font for display (to free up program space)?
Regards,
sm
Specifically, are there alternative versions of 8x8 fonts available?
Is there convenient code available for building a custom font?
Also, if a specific driver has a font definition in a DAT section of the program, what is required to point to the Propeller ROM font for display (to free up program space)?
Regards,
sm
Comments
What driver are you using with 8x8 font?
I am using a driver that Kuroneko recently posted (single cog 320x356) that he packaged with an 8x8 font listed herein.
The driver works fine but the font is a little "blocky" and I was wondering if I could get any others.
Regareds,
sm
I got the font editor from your website. It is a cool program. I will play with it and see what I can come up with.
Thanks.
sm
Here's "ABC".
reeDesign065 byte %00110000 byte %00110000 byte %00111000 byte %01011000 byte %01011000 byte %11111100 byte %10001100 byte %10001100 freeDesign066 byte %11111000 byte %11001100 byte %11001100 byte %11111000 byte %11001100 byte %11001100 byte %11001100 byte %11111000 freeDesign067 byte %01111000 byte %11001000 byte %11000000 byte %11000000 byte %11000000 byte %11000000 byte %11001000 byte %01110000
I'm using it in LED arrays. I don't know what you'd need to do to convert it to use with a VGA driver but maybe having it typed out like this would save your some time (if you like the font).
I personally think this font is easier to read on a scrolling LED array than many of the other 8x8 fonts I've seen.
You can see an example of it by skipping to 2:56 of this video. Or se it spelling out "Merry Christmas" here.
Let me know if you're interested and I'll post the font here.
Regards,
sm
I did it the hard way. I made an all zero character and copied it a bunch of times.
byte %00000000 byte %00000000 byte %00000000 byte %00000000 byte %00000000 byte %00000000 byte %00000000 byte %00000000
I then filled in the ones to create the font.
I found the font on the internet somewhere.
When I'm able, I use a ten pixel wide "W". I don't really like my version of the eight pixel "W".
Here's the wide versions in case anyone is interested.
DAT wideFontsfreeDesignWide087 word %1100110001000000 word %1100110001000000 word %0110011010000000 word %0110011010000000 word %0110111010000000 word %0011001100000000 word %0011001100000000 word %0011001100000000 freeDesignWide119 word %0000000000000000 word %0000000000000000 word %1100110011000000 word %1100110011000000 word %0110011010000000 word %0110111010000000 word %0011001100000000 word %0011001100000000
So this might work with Duanes format...
PRI out(c) : b b := curx + cury * 320 c &= 255 colour.byte[curx + cury * 40] := curcol repeat 8 screen.byte[b] := byte[base][c] b += 40 c++ 'c += 256 if ++curx == 40 curx := 0 cury++
I took the liberty of adding a character placeholder in the print function.
Regards,
sm
PRI out(c) : b b := curx + cury * 320 [COLOR="#FF0000"]c := c.byte{0} << 3[/COLOR] colour.byte[curx + cury * 40] := curcol repeat 8 screen.byte[b] := byte[base][c] [COLOR="#FF0000"]>< 8[/COLOR] b += 40 c++ if ++curx == 40 curx := 0 cury++
I get the byte reverse. I do not get the shift left 3.
When I load the font I get a few legible characters with a whole lot of garbage anyway.
Duane, is there a one to one ASCII correspondence here?
sm
My problem was Duane's font omitted characters $01 thru $20.
It prints but to be honest your original font looks a scosh better. :blank:
Thank you both for your help. I am not sure how far I will get with 8x8 grids for appearance.
Is there any way to get 8x16 implemented (with the same color depth) without clogging the whole thing up?
Another option would be the 50xH full colour driver which works with any 8xN font (but doesn't include pixel plotting).
But I like the color by character feature of your driver and 8x8 is legible... so it is going to get used in one of our projects (a 3 axis stage to sense magnetic field).
Thank you very much. I recognize your talent as one of the great ones!
As far as 8x16 with existing driver I assume this would work:
PRI out(c) : b b := curx + cury * 320 ' c &= 255 c := (c.byte{0}-32) << 3 colour.byte[curx + cury * 40] := curcol colour.byte[curx + cury * 80] := curcol repeat 16 ' screen.byte[b] := byte[base][c] screen.byte[b] := byte[base][c] >< 8 b += 40 ' c += 256 c++
Regards,
sm
8x16 modification:
PRI out(c) : b b := curx + cury * [COLOR="#FF0000"]constant(40 * 16)[/COLOR] c := (c.byte{0}-32) [COLOR="#FF0000"]<< 4[/COLOR] colour.byte[curx + cury * [COLOR="#FF0000"]80[/COLOR]] := curcol colour.byte[curx + cury * 80 [COLOR="#FF0000"]+ 40[/COLOR]] := curcol repeat 16 screen.byte[b] := byte[base][c] >< 8 b += 40 c++
However, I am still trying to understand the driver... the color map is by character but the screen map is by pixel.
Are you suggesting that we can get color by pixel?
That said, I don't know your requirements. Maybe full colour text is enough (that's why I keep checking, we have any number of those) which would eliminate the current 10K pixel buffer (to be replaced by a 40x32 byte character buffer). Colour per pixel is possible but not at this resolution with just the Prop (e.g. C3 with Synapse OTOH manages 400x300 in full colour).
Yes, the font only had the printable ASCII characters.
You will have to modify the code for writing the character map too as Kuroneko pointed out earlier in this thread.
There are numerous other video drivers that accommodate different character resolutions... I am sure you will see in the file exchange OBEX.
Sorry I am not of more help right now...
sm
AN004 Getting Started with VGA pdf (16 pages)
AN005: GUI & Graphics Series - Simple VGA Menus