don't click here

Text mode font bitmap, anyone?

Discussion in 'Technical Discussion' started by Sik, Jul 24, 2009.

  1. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    Does anybody have a bitmap of the font normally used in text mode? Not the 8x8 one, but the 8x16 one. Google isn't helping me at all, either giving me info on how to write my own font to the VGA or downloading fonts that are completely unrelated.

    I managed to find this link which helped quite a lot with this:

    [​IMG]

    However, as you see, I'm still missing the control characters. This is because the program is a rasterizer for ANSI art (used a lot back in the BBS days), and I have no fucking idea of how to render the control characters :| So technically I'm just missing those, but either way, does anybody know where I can find them?
     
  2. nineko

    nineko

    I am the Holy Cat Tech Member
    6,351
    510
    93
    italy
    First of all, that is the 437 codepage. If you want I can help you by providing the 850 codepage, in the form of a screenshot like your one. Take or leave.
     
  3. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    I only want the control codes (characters 0 1 to 31). Also I really don't see how this belongs to Technical Discussion other than for this being something used by many BIOSes. I'm not even asking anything about programming or similar at all.

    EDIT: OK, not character 0, that one is blank :P
     
  4. nineko

    nineko

    I am the Holy Cat Tech Member
    6,351
    510
    93
    italy
    Deal.
    [​IMG]

    By the way these are 8x12, not 8x16 :p
     
  5. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    Er, that's an 8x12 font (moreover, that's Terminal >_>), I'm looking for the 8x16 font used by most BIOSes.
     
  6. nineko

    nineko

    I am the Holy Cat Tech Member
    6,351
    510
    93
    italy
    I gave you 8x12 because you posted a pic of 8x12 <_<

    There, have your 8x16:
    [​IMG]

    This is the font used by Dosbox, in case you're wondering. However most bioses used slight variations so there isn't a real "standard" font anyway. And yes, this is the 437 codepage.
     
  7. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    It's a pic of 8x16, look again. It's 224 pixels high because it's missing the two top rows (and in any case, that'd be the height for 8x14 :P).

    Also DOSBox... *facepalm* Should have thought of that before :psyduck: That said, looks like DOSBox's font is made for 9x16 really :| I'll have to do, but if there are any alternatives, tell me :v:
     
  8. TmEE

    TmEE

    Master of OPL3-SA2/3 Tech Member
    1,726
    2
    18
    Estonia, Rapla City
    T-04YBSC-A !
    The font Sik looks for is GFX card dependant.... and you can read back that font from one memory region devoted to CGA/EGA/VGA... I think it was B000:0000 but I'm not sure since I messed with that too many years ago

    And the Font is 9x16 you get from the GFX card.
     
  9. nineko

    nineko

    I am the Holy Cat Tech Member
    6,351
    510
    93
    italy
    Yes, the text mode font, while in the standard 80x25 mode, is designed to be 9x16 pixels. Not sure about the other modes such as 80x43 and 80x50.
     
  10. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    But is largely the same across computers.

    Good luck doing that on WinXP :| Besides I think that B000:0000 appears as a mirror of B800:0000 in text mode, which means that reading from there will just give me the text data and not the graphics.

    Nope, it's 8x16. The 9th column is either blank or a repeat of the last column (the latter are the characters in the C0-DF range). It was added exclusively because some people didn't like the fact that the middle column of the M was one pixel wide :| It wasn't part of the original spec, and not everybody took advantage of it: for instance, the font used in this BIOS seems to be made for 8x16, as letter characters are always 7 pixels wide maximum.
     
  11. TmEE

    TmEE

    Master of OPL3-SA2/3 Tech Member
    1,726
    2
    18
    Estonia, Rapla City
    T-04YBSC-A !
    If you read the font from the GFX card, you get 9 pixel wide data, not 8 pixels... and data is 1bpp too. You won't be seeing programs that emulate GFX on text modes having some empty vertical lines.

    And you can indeed forget it on XP, you either boot your PC in DOS and use some custom program to dump the font, or you boot your PC in DOS and use a custom program to dump the font.
     
  12. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    Tell me how the hell do you fit 9 pixels in 8 bits. Also tell me what characters do those programs use - the range C0-DF has the 9th column being a repeat of the 8th one instead of being blank.

    Custom program? You completely forgot about DEBUG. I used that to dump my old BIOS (and I don't have the files anymore, as usual :P). Also you could try another operating system ;P That said, Windows 98 does let DEBUG access the BIOS data :/
     
  13. TmEE

    TmEE

    Master of OPL3-SA2/3 Tech Member
    1,726
    2
    18
    Estonia, Rapla City
    T-04YBSC-A !
    things are on 9bits there, things do not have to be perectly aligned... 9bit memories exist, and a typical parity RAM has 9bit not 8bit cells.
     
  14. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    Then I want to know what kind of card are you using because the VGA uses 8 bits per character line, at least from the software viewpoint.
     
  15. TmEE

    TmEE

    Master of OPL3-SA2/3 Tech Member
    1,726
    2
    18
    Estonia, Rapla City
    T-04YBSC-A !
    the font is there from the earliest GFX cards dating back to IBM PC..... all modern cards are backwards compatible with the early cards
     
  16. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    http://www.osdever.net/FreeVGA/vga/vgatext.htm
    http://www.osdever.net/FreeVGA/vga/char.txt
    Code (Text):
    1. _____Examples_of_Text_Mode_Bitmap_Characters_____
    2. &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    3. &nbsp;&nbsp;7 8x8&nbsp;&nbsp;0&nbsp;&nbsp;___Legend___&nbsp;&nbsp;&nbsp;&nbsp; 7 8x16 0&nbsp;&nbsp;&nbsp;&nbsp;7 9x16 0
    4.  0—XX----&nbsp;&nbsp;- Background&nbsp;&nbsp;&nbsp;&nbsp;0--------&nbsp;&nbsp; 0--------
    5. &nbsp;&nbsp;-XXXX---&nbsp;&nbsp;X Foreground&nbsp;&nbsp;&nbsp;&nbsp; --------&nbsp;&nbsp;&nbsp;&nbsp;--------
    6. &nbsp;&nbsp;XX—XX--&nbsp;&nbsp;? Undisplayed&nbsp;&nbsp;&nbsp;&nbsp;---X----&nbsp;&nbsp;&nbsp;&nbsp;XX----XX
    7. &nbsp;&nbsp;XX—XX--&nbsp;&nbsp;&nbsp;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-&nbsp;&nbsp;&nbsp;&nbsp;XX----XX
    14. &nbsp;&nbsp;????????&nbsp;&nbsp; Maximum Scan&nbsp;&nbsp;&nbsp;&nbsp;XX---XX-&nbsp;&nbsp;&nbsp;&nbsp;XX----XX
    15. &nbsp;&nbsp;????????&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Line&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;XX---XX-&nbsp;&nbsp;&nbsp;&nbsp;XX----XX
    16. &nbsp;&nbsp;????????&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; --------&nbsp;&nbsp;&nbsp;&nbsp;--------
    17. &nbsp;&nbsp;????????&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;--------&nbsp;&nbsp;&nbsp;&nbsp;--------
    18. &nbsp;&nbsp;????????&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;--------&nbsp;&nbsp;&nbsp;&nbsp;--------
    19. &nbsp;&nbsp;????????&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;+------> 15--------&nbsp;&nbsp;15--------
    20. &nbsp;&nbsp;????????&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 16????????&nbsp;&nbsp;16????????
    21. &nbsp;&nbsp;&nbsp;&nbsp;...&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;...&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ...
    22. 31????????&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 31????????&nbsp;&nbsp;31????????
    EDIT: bonus points to whoever makes the board to stop "fixing" the characters automatically :psyduck:
     
  17. TmEE

    TmEE

    Master of OPL3-SA2/3 Tech Member
    1,726
    2
    18
    Estonia, Rapla City
    T-04YBSC-A !
    this is more messy than I remembered D:
     
  18. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    Not really, but the explanation there does look complicate. Basically:
    • There are 8-bit per line. This means 8 pixels that can be defined.
    • For most characters, the 9th column is set to be blank.
    • For the characters in the C0-DF range, the 9th column is a repeat of the 8th one.
    That's it.

    Now, the deal here is to find a font that was made assuming that the 9th column doesn't exist.
     
  19. LocalH

    LocalH

    roxoring your soxors Tech Member
    3,314
    35
    28
    Nunya
    Rock Band 3 Deluxe
    I can't find an 8x16 VGA font other than that, but I did find this 8x14 EGA font which you could extend to 8x16.

    Edit: Crap, I called that wrong, it is 8x16. There's also this which has some other fonts that you could mix and match characters from (MDA, EGA, and 9x16 VGA).

    Edit2: Ok, that first link is about useless - it looks like someone stretched the EGA font to 8x16, check the slashes and the lowercase "s". Try the EGA font - it's 8x14 but you can extend it to 8x16 by adding a blank line on top and bottom.
     
  20. Sik

    Sik

    Sik is pronounced as "seek", not as "sick". Tech Member
    6,718
    10
    0
    being an asshole =P
    OMG look what I found:

    [​IMG]

    ...WTF at the M and W. I guess I'll have to see if by any chance I still can get my old computer, but I doubt so :| I think that in the end I'll just go with a hybrid font >_>

    The extended characters of that font weren't codepage 437 either :P