TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: TIM ESSELENS
from: JANI SAKSA
date: 1997-04-06 16:32:00
subject: Re: Video

 -=> Propably Tim Esselens wrote to All <=-
 Hello Tim!
 TE> Is there enyone who could help me with the following prob.
 TE> ok, I'm new in c++ but.. Beter late then never :))
 TE>
 TE> i'd like to make a demo for my bbs,
 TE> but i can't put out one pixel in vga mode...
 TE> (i even don't know how to put the program in vga mode)
 TE> is there someone who could send me like a source code or a manual
 TE> that could help me in my quest ta make a demo ?
You didn't say which compiler you use, but here's something for Borland C 2.0 
(320x200 256 colors):
#include 
char far *vga_scr = (char far*)0xa0000000;
void init_vga_mode() {
REGPACK rp;
  rp.r_ax = 0x13;
  intr(0x10, &rp);
}
void putpixel(int x, int y, int color) {
  if ((x319) || (y199)) return;
  vga_scr[(y*320)+x]=color;
  /* For faster version use: vga_scr[(y<<8)+(y<<6)+x]=color; */
}
Write me if you have any problems with graphics... I know about VGA, ModeX, 
SVGA...
 TE> Blaze-X
 TE> (blaze-x@genesis.be)
/*
** Hello, I'm Sir Robin (jsaksa@tiira.cedunet.com)
** Visit my home: http://www.cedunet.com/~jsaksa/
** Best DooM place in Finland can be found there too ;)
*/
... Teekkari ei kuulu nyrkill{tapettaviin.
--- BBBS/2 v3.33 How-C
---------------
* Origin: Cat-Box - 02-4841086 (2:222/120)

SOURCE: echomail via exec-pc

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.