Article View: net.micro.pc
Article #5958pc graphics packages
From: Steve Levine
Date: Sat, 15 Mar 1986 18:44
Date: Sat, 15 Mar 1986 18:44
83 lines
2871 bytes
2871 bytes
I get the impression that graphics function libs on the pc has not
really progressed much since the beginning. I am using (attempting to) halo
and lattice-c on the pc. I have found that the documentation is so poor, and
the interface to lattice, just as bad, that it is almost impossible to use.
The main problems is that linking to the libraries , ie; \lc\lc.lib+halo.lib
takes forever, even with a ram-disk and fast hard-disk. That makes experi-
mentation (to decipher the manual explainations) pretty painfull. I had hoped
that the functions as specified, would be straightforward and work as described,
but alas, to no avail, they don't. So rather than spend a lot of time ditzing
around with this, I plea for advice.
Has anyone tried to use world and viewport on halo 2.x ?
If so, how do you get it to work? I am using an 8087 and the large model of
lattice. The program looks like this :
/*
just a test for drawing
3/12/86 s.l.
*/
struct view_port {
double Vx0,Vy0,Vx1,Vy1;
} vp[] = {
{ .1,.1,.4,.4 },
{ .1,.5,.4,.9 },
{ .5,.1,.9,.4 },
{ .5,.5,.9,.9 }
};
main()
{
double wx0,wy0,wx1,wy1;
float vx0,vy0,vx1,vy1;
int format = 1, mode = 1;
int color = 1, radius = 400;
int x1 ,y1 , i,j;
int border = 1, clear = 0;
wx0 = wy0 = 0; wx1 = wy1 = 1000;
vx0 = vy0 = 0.04; vx1 = vy1 = .97;
setieee(&format);
initgraphics(&mode);
setworld(&wx0,&wy0,&wx1,&wy1);
setviewport(&vx0,&vy0,&vx1,&vy1,&border,&clear);
for(i = 0;i <4;i++)
{
vx0 = vp[i].Vx0; vy0 = vp[i].Vy0;
vx1 = vp[i].Vx1; vy1 = vp[i].Vy1;
setviewport(&vx0,&vy0,&vx1,&vy1,&border,&clear);
movabs(&x1,&y1);
cir(&radius);
}
inqworld(&wx0,&wy0,&wx1,&wy1);
inqviewport(&vx0,&vy0,&vx1,&vy1);
inqgcur(&x1,&y1,&color);
for(i=0;i<32000;i++){
for(j = 0; j< 4 ; j++);
}
closegraphics();
printf("world_coords : %f %f %f %f\n",wx0,wy0,wx1,wy1);
printf("view_coords : %f %f %f %f\n",vx0,vy0,vx1,vy1);
printf("gcur_coords : %f %f %d\n",x1,y1,color);
}
All of the inquire functions return the correct values. the program
gives me a blank screen. ????
Does anyone know of a package which works well? How about the Digital Research
"GSS" advertised in Byte, march 86, page 205 ?
Thanks in advance,
Steve Levine (ihnp4!sunybcs!muswiz)
Technical Details
Message-ID:
<2939@sunybcs.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!watmath!sunybcs!muswizShow Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/5/84; site sunybcs.UUCP Path: arc1-ca.pugleaf.net!utzoo!watmath!sunybcs!muswiz From: muswiz@sunybcs.UUCP (Steve Levine) Newsgroups: net.micro.pc Subject: pc graphics packages Message-ID: <2939@sunybcs.UUCP> Date: Sat, 15-Mar-86 13:44:29 EST Article-I.D.: sunybcs.2939 Posted: Sat Mar 15 13:44:29 1986 Date-Received: Sun, 16-Mar-86 08:33:27 EST Organization: SUNY/Buffalo Computer Science Lines: 83 Keywords: halo gss lattice-c