Path: chuka.playstation.co.uk!scea!greg_labrec@interactive.sony.com From: "Linda J. Hodge" Newsgroups: scea.yaroze.programming.2d_graphics Subject: Coding ? Date: Sat, 19 Jul 1997 13:16:40 -0700 Organization: SCEA Net Yaroze News Lines: 146 Message-ID: <33D120A8.63D0@earthlink.net> Reply-To: hodgke@earthlink.net NNTP-Posting-Host: max6-so-ca-08.earthlink.net Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------4A9391927A" X-Mailer: Mozilla 3.0C-NSCP (Win16; U) This is a multi-part message in MIME format. --------------4A9391927A Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit What is wrong with this source code?It is supposed to display a bunch of colored lines. --------------4A9391927A Content-Type: text/plain; charset=us-ascii; name="LINES!.C" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="LINES!.C" /******************************************************** * * * * * LINES!!!! * * * * By Austin Kottke * *******************************************************/ // include libraries #include #include "pad.h" // constants // GPU packet space #define PACKETMAX (10000) #define PACKETMAX2 (PACKETMAX*24) // size of ordering table: 2 << OT_LENGTH // i.e. 16384 levels of z resolution #define OT_LENGTH 1 // globals // Ordering Table handlers GsOT WorldOrderingTable[2]; // actual Ordering Tables themselves GsOT_TAG zSortTable[2][1<attribute = 0; //This is the core of the program //which is pretty basic. sp->x0 = rand()%640; sp->y0 = rand()%480; sp->x1 = rand()%640; sp->y1 = rand()%480; sp->r0 = sp->g0 = sp->b0 = rand()%16; sp->r1 = sp->g1 = sp->b1 = rand()%16; } // wait for end of drawing to the ot DrawSync(0); // wait for V_BLANK interrupt VSync(0); // swap double buffers GsSwapDispBuff(); // register clear-command: clear to some weird combo GsSortClear(16,36,43, &WorldOrderingTable[TheBuff]); // register request to draw ordering table GsDrawOt(&WorldOrderingTable[TheBuff]); } // clean up ResetGraph(3); return 0; } --------------4A9391927A--