Path: chuka.playstation.co.uk!news From: Jim Newsgroups: scea.yaroze.programming.3d_graphics Subject: Re: Messing with the primatives Date: Wed, 20 Aug 1997 10:06:23 +0100 Organization: PlayStation Net Yaroze (SCEE) Lines: 43 Message-ID: <33FAB38F.1DBE65B4@micronetics.com> References: <33F27552.437C2A01@ix.netcom.com> <33FA317F.3279@chat.carleton.ca> NNTP-Posting-Host: jim.micronetics.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 4.01 [en] (Win95; I) X-Priority: 3 (Normal) Tim O'Neil wrote: > If you display these primitive values (olen, ilen) before they are > linked via GsLinkObject4 (or whatever it is), they correspond to the > values that you set them to, but if you go into the 'tmd' pointer of the > GsDOBJ2 structure and grab them after they have been linked, these two > values are changed. It only seems to modify the very first primitive > packet for a given tmd header. Was just wondering what this represents, > because it is the only thing that is keeping me from bypassing that > routine. Your correct, GsLinkObject4 does a few things. One of them being the modification of the first ilen and olen params. For the first primitive this value represents a count of 'like' primitives to follow this one. It all goes towards speeding it all up. *((ushort *)tmdprims) = primcount; I have something akin to this in my code and completely bypass GsLinkObject4. > I suppose another thing that makes me wonder about it is that even if > you go in later and change the data in the primitive all around (save > the stuff that has been modified) it will still work fine, but if you > hammer these values back to what they were it will bomb. Its possibly crashing when you change the values back because it could still be drawing the tmd. A lot of the drawing functions are non blocking. So you could modifying some data while it is being operated on. A solution to this would be to double buffer your tmds. Wastes space. I just put some menial code (next frames Ai, collision detection. etc.. ) in-between the drawing and modify code to ensure that the data is no longer being used. Just a stab in the dark mind. -JiM