Message-Id: Comments: Authenticated sender is From: "Salvador Eduardo Tropea (SET)" To: fighteer AT cs DOT com, zhang AT cc DOT hirosaki-u DOT ac DOT jp, djgpp AT delorie DOT com Date: Thu, 26 Dec 1996 14:47:05 +0000 MIME-Version: 1.0 Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Subject: Re: why can't printf text in graphics mode Hi John and Tony: > Tony O'Bryan wrote: > > > > > Now I want to printf text in the graphics mode, but it does not work, why? > > > > Maybe djgpp's printf() writes directly to text screen memory, which is > > at a different address than graphics memory. > > printf() does not write to any kind of memory; it simply writes to the > stdout file descriptor. DOS then determines where that file descriptor > goes. Normally, it goes to the CON: device, which results in the text > being sent to the BIOS for display on the console screen. Since neither > DOS nor the BIOS know or care what video mode you are in, this will not > work in graphics modes. Partially true and then partially wrong, the BIOS routines for the VGA card are INSIDE of the VGA card so the responsible for printing text in graphics mode is the manufacturer of the card. If the card supports VESA you can ask to the BIOS if this mode supports text output, the major part of the TRIDENT cards supports it even in 1024x768, you can use the SVM utility to switch to 640x480x256 (as an example because is 80x25) and then type DIR at the DOS command prompt, is pretty slow but works. SET --------------- 0 -------------------------------- Salvador Eduardo Tropea (SET). Address: Curapaligue 2124, Caseros, 3 de Febrero Buenos Aires, (1678), ARGENTINA TE: +(541) 759 0013