Hi , I’m testing scroll text examples and I have some problems with the size of letters. https://github.com/AaronLiddiment/RGBLEDS
const uint8_t RobotronFontData[] = {
7, // Font Width
7, // Font Height
32, // Font First Character
96, // Font Last Character
It seems each char is made 7x7 and my matrix is 24w & 5h , I changed all letters to 5 height but it doesn’t work. I don’t know if I buy 2 more rows and get 7 height or it is possible adapt the code.
Thank you
@Aaron_Liddiment is a semi-reular poster on this group.
However, the font is indeed defined by 7x7 arrays (essentially a bitmap of each character). I haven’t looked through his code to see if there are dependants on font size or not.
Needless to say, truncating part of the character definition will result in some strange behavior.
When I was building a simple font, I think the fewest number I could get was 5*7, you could probably get away with scaling that to 5x6 but it might look strange.
Thank you for your answer , I found a 5x5 font in https://github.com/vitormhenrique but only works in Adafruit library , glcdfont_5x5.c , I’m trying to adapt to Fastled…
Yes, the font files are bitmap not vector so you would need to make a new one that is only 5 pixels high. I have written a windows exe that can render any installed font in a selected point size and then generate the font source data. Its not really ready for general consumption.
The GLCD font format is defined vertically left to right whereas my format is horizontal top to bottom. In theory you could add “0x07,0x05,0x00,0xfe,” to the start of the data and then use SetTextDirection(CHAR_RIGHT); to rotate the font upright.