Page 1 of 1

two ? about text mode

Posted: Tue Dec 13, 2005 5:50 pm
by GLneo
1.)is there a real mode way to switch to higher res text mode
2.)is there an easy way to change the font, like to make it in to part of a picture or logo then put them toghether???

P.S. is this how linux does that penguin logo in text mode(slackware, dsl, knoppix)???

Re:two ? about text mode

Posted: Tue Dec 13, 2005 6:43 pm
by carbonBased
I should really know this, as I use Linux on a regular basis, but... does the penguin have more then one colour? If so, it's not a combination of graphic-like fonts.

It's possible that they get at the low level frame buffer while in text mode and plot via pixels. I've seen this done in a demo by FutureCrew, back in the day... although I don't know how they did it. I, unfortunately, haven't done a whole lot of low level VGA register work.

--Jeff

Re:two ? about text mode

Posted: Tue Dec 13, 2005 7:22 pm
by Dex4u
Lol, the linux is in graphic vesa mode, not text mode, so many people think, that its some great dual mode.
It's simple you go to a graphic vesa mode, maybe 640x480 8bpp and you use 8x8 font, and a image, that how its done.

As for making a logo in text mode thats easy by using ASCII Extended codes, that are not used much, you need to mod the fonts to make a logo when they are put in a block of say 3 rows of 8, and reprogram the fonts.
if you do this in 80x50 text mode it looks better.

I have made a demo to do this, see here: http://board.flatassembler.net/topic.php?t=2540
This was done like that :

Re:two ? about text mode

Posted: Tue Dec 13, 2005 10:35 pm
by Brendan
Hi,
GLneo wrote:1.)is there a real mode way to switch to higher res text mode

Yes - there's 4 methods. The first method is to set 80 * 25 text mode and then change the fonts to 8 * 8 to get 80 * 50 text mode. E.g.:

Code: Select all

   mov ax,0x0003         ;Set 80*25 video mode
   int 0x10

   mov ax,0x1112              ;Set character size (changes to 80*50 video mode)
   clr bl
   int 0x10
The next way is to manually tweak the VGA registers. For example, Chris Giese has code available to get 90 * 60 text mode. I've used this code myself, and found it works reliably on standard VGA cards and CRT monitors, but I had problems with at least one computer with an LCD monitor.

The third way is to use VESA BIOS extensions. For e.g. there's a lot of cards that handle 132 * 43 text mode via. VBE.

The last way is to use a high resolution graphical video mode and draw the fonts yourself (i.e. pretend you're in text mode when you aren't) - for e.g. 1024 * 768 16 colour mode with 8 * 8 fonts could be used to pretend your using 128 * 96 text mode. This is harder (and slower), but makes it easier to add a GUI to the OS later on.

This is (sort of) what I did for the last version of my OS - the boot menu let the user select any video mode (via. VBE, etc) and all code after that did whatever it needed to to pretend it was text mode. For the next version of my OS, I'm not going to support text mode at all.



Cheers,

Brendan

Re:two ? about text mode

Posted: Tue Dec 13, 2005 11:37 pm
by Colonel Kernel
Brendan wrote:The next way is to manually tweak the VGA registers. For example, Chris Giese has code available to get 90 * 60 text mode. I've used this code myself, and found it works reliably on standard VGA cards and CRT monitors, but I had problems with at least one computer with an LCD monitor.
I've used this method myself and had trouble with 90 * 60 mode when running under MS Virtual PC. It works fine under VMWare and on my LCD monitor though. My $0.02.