Problems with personal font map
Problems with personal font map
Hi! I'm working in 640x480 24bit graphic mode, and i need to add a character function. This is the font map (8x16) taken from an other source.
(It's the attached file)
Well when i compile the kernel the bin contains only the characters up to 26. Why the other 230 chars aren't "saved"?
(It's the attached file)
Well when i compile the kernel the bin contains only the characters up to 26. Why the other 230 chars aren't "saved"?
- Attachments
-
- font.rar
- (7.71 KiB) Downloaded 166 times
Re: Problems with personal font map
...This makes me happy of using bitmap resources.
Im not to sure why it would only take the first 26 characters though. What happens if you add another label after the 26th character?
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
Re: Problems with personal font map
After some playing around with the source, I found out that the error happens on this line (26th character):
If you remove the arrow from the comment, it compiles to 4 KiB which fixes it.
On the other hand I have no idea of why it happens since the arrow actually is placed in a comment.
Code: Select all
DB 000H ; 00000000 °°°°°°°° | |"→"| |
On the other hand I have no idea of why it happens since the arrow actually is placed in a comment.
Re: Problems with personal font map
Hm, that is weird. Perhaps its an assembler bug?
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
Re: Problems with personal font map
That is my thought too. It is an unicode character, so my wild guess would be that the assembler has problems handling unicode. The strange thing about that the character is placed in a comment
Re: Problems with personal font map
Yes, I think that NASM has problems with those characters. Maybe you should edit the file in real text mode, not using something like Notepad or avoid using those characters. Anyway, if the 1's and 0's of the bitmap are seen with attention and with a monospaced font like Courier, it should be easy to distinguish the character.
YouTube:
http://youtube.com/@AltComp126
My x86 OS/software:
https://sourceforge.net/projects/api-simple-completa/
Donate to get more food/programming resources/computers:
https://www.paypal.com/donate/?hosted_b ... QS2YTW3V64
http://youtube.com/@AltComp126
My x86 OS/software:
https://sourceforge.net/projects/api-simple-completa/
Donate to get more food/programming resources/computers:
https://www.paypal.com/donate/?hosted_b ... QS2YTW3V64
Re: Problems with personal font map
In fact the 26th character wasn't shown all, but only up to the arrow. Now it work
Wow a bug in nasm... well thanks for the help
Wow a bug in nasm... well thanks for the help
- Attachments
-
- vesaCharactersWork.PNG (7.05 KiB) Viewed 6615 times
Re: Problems with personal font map
Err... guys... That is character 26, you know, ^Z? The "end of file" marker?Blue wrote:That is my thought too. It is an unicode character, so my wild guess would be that the assembler has problems handling unicode. The strange thing about that the character is placed in a comment :?
JAL
Re: Problems with personal font map
It also has failed with this character ° that resembles degrees.
YouTube:
http://youtube.com/@AltComp126
My x86 OS/software:
https://sourceforge.net/projects/api-simple-completa/
Donate to get more food/programming resources/computers:
https://www.paypal.com/donate/?hosted_b ... QS2YTW3V64
http://youtube.com/@AltComp126
My x86 OS/software:
https://sourceforge.net/projects/api-simple-completa/
Donate to get more food/programming resources/computers:
https://www.paypal.com/donate/?hosted_b ... QS2YTW3V64
Re: Problems with personal font map
That makes sense today after sleeping Thanks for clarifyingjal wrote:Err... guys... That is character 26, you know, ^Z? The "end of file" marker?
Re: Problems with personal font map
This is my new font
- Attachments
-
- screenshot7.PNG (11.21 KiB) Viewed 6406 times
Re: Problems with personal font map
Why? what characters are difficult to read?
- Combuster
- Member
- Posts: 9301
- Joined: Wed Oct 18, 2006 3:45 am
- Libera.chat IRC: [com]buster
- Location: On the balcony, where I can actually keep 1½m distance
- Contact:
Re: Problems with personal font map
Adding to that, the L character is now identical to the 1 character
- Firestryke31
- Member
- Posts: 550
- Joined: Sat Nov 29, 2008 1:07 pm
- Location: Throw a dart at central Texas
- Contact:
Re: Problems with personal font map
A quick tip: Choose some brighter colors. The first pink part is good, but the purple font demo is too hard for me to see. I'd suggest something closer to #7010F0. Also, the dark pink number suffixes are a bit hard to read.
The X and Y characters are a bit top-heavy, as well as the P and R. Move the intersections down just a bit. You also might try a little more padding between characters (i.e. keep the cells the same width, but make the characters in the cells 1 pixel thinner). Finally, the entire lowercase f might need to be shifted one pixel up. I may also suggest adding one pixel to the height of most of the lowercase letters.
If we're talking about custom fonts, here's my own font I've developed over the past couple of years. This particular version is a 2 bit, 8pt, outlined version of my font, "Fawkes UI." It was manualy anti-aliased. It's supposed to be a proportionally-spaced font where the outline overlaps.
l I originally designed it to caption a little GIF movie I was going to make (hence the useless musical note). It was created pixel-by-pixel in an editor called Usenti (which includes a very useful Export function that includes a C array or a GAS syntax ASM array which can be converted to NASM syntax with a couple of Finds/Replaces, as well as complete control of the palette). I have no idea how many people here know about it.
The X and Y characters are a bit top-heavy, as well as the P and R. Move the intersections down just a bit. You also might try a little more padding between characters (i.e. keep the cells the same width, but make the characters in the cells 1 pixel thinner). Finally, the entire lowercase f might need to be shifted one pixel up. I may also suggest adding one pixel to the height of most of the lowercase letters.
If we're talking about custom fonts, here's my own font I've developed over the past couple of years. This particular version is a 2 bit, 8pt, outlined version of my font, "Fawkes UI." It was manualy anti-aliased. It's supposed to be a proportionally-spaced font where the outline overlaps.
l I originally designed it to caption a little GIF movie I was going to make (hence the useless musical note). It was created pixel-by-pixel in an editor called Usenti (which includes a very useful Export function that includes a C array or a GAS syntax ASM array which can be converted to NASM syntax with a couple of Finds/Replaces, as well as complete control of the palette). I have no idea how many people here know about it.
Owner of Fawkes Software.
Wierd Al wrote: You think your Commodore 64 is really neato,
What kind of chip you got in there, a Dorito?