Path: chuka.playstation.co.uk!news From: Developer Support Newsgroups: scee.yaroze.programming.3d_graphics Subject: Re: GPU Code xxh not supported Date: Fri, 04 Jul 1997 10:13:52 +0100 Organization: PlayStation Net Yaroze (SCEE) Lines: 44 Message-ID: <33BCBED0.429@interactive.sony.com> References: <5pga0c$8c3@chuka.playstation.co.uk> <33BBB432.FF5@interactive.sony.com> <5ph02c$8c4@chuka.playstation.co.uk> <33BCB28A.6366@interactive.sony.com> NNTP-Posting-Host: 194.203.13.10 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 3.01 (Win95; I) Developer Support wrote: > > We haven't tested all the TMD primatives, so it does look like 3D lines > is another one thats not supported. As for drawing 3D lines, you could > try a polygon with points the same (not at all ideal), or you could > perform your own transformation and then draw to the screen (still not > ideal, GsLINE is the structure, GsSortLine to add to ordering table). > I'll look into both methods, even though I'm not convinced about this > wireframe stuff (controvertial). > > Stuart I've had a look at both methods, and drawing a polygon isn't very good, as the polygon has to have a width. The second method is much more straight forward, and looks something like this. GsCOORDINATE2 coord; // coordinate system line is in GsOT OT[2]; // ordering table int buffer; // drawing buffer number int pri; // priority in ordering table SVECTOR v0,v1; // the vertices of the line VECTOR p0,p1; // the points on the screen MATRIX m; // the matrix to go from the vertices to points GsLINE line; // the line to be drawn; GsGetLs(&coord,&m); // calculate local to screen matrix ApplyMatrix(&m,&v0,&p0);// transform vertices ApplyMatrix(&m,&v1,&p1); line.attribute = 0; // set up line line.x0 = p0.vx; line.y0 = p0.vy; line.x1 = p1.vx; line.y1 = p1.vy; line.r = 127; line.g = 127; line.b = 127; GsSortLine(&line,&OT[buffer],pri); Hope this is enough to get you on your way. Stuart