Path: chuka.playstation.co.uk!scea!peter_alau@playstation.sony.com From: "Antony Arciuolo" Newsgroups: scee.yaroze.programming.2d_graphics Subject: Sprite Rotation questions. Date: Sat, 22 Aug 1998 15:38:32 -0400 Organization: SCEA News Server Lines: 57 Message-ID: <6rptai$1qh10@scea> NNTP-Posting-Host: nac-btr2-s14.nac.net X-Newsreader: Microsoft Outlook Express 4.72.3110.1 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 I have a 2d scrolling world with 20 32x32 sprites that are all the same. Sprite[0] is controlled by pad1 and works. When you press left/right, a function called RotateCW(Object *obj, short degrees) or RotateCCW(Object *obj, short degrees) is invoked. These functions either add or decrement obj->spr.rotate by (degrees * ONE), and then make an adjustment if the rotation is out of the 0-360 range. Here are the functions. void RotateCCW(WOBJECT *obj, short degrees) { obj->spr.rotate -= (MAKEFIXED(degrees)); if (obj->spr.rotate < 0) obj->spr.rotate += (MAKEFIXED(360)); } void RotateCW(WOBJECT *obj, short degrees) { obj->spr.rotate += (MAKEFIXED(degrees)); if (obj->spr.rotate >= MAKEFIXED(360)) obj->spr.rotate -= MAKEFIXED(360); } Now I want Sprite[1] to "look at" Sprite[0] when I press a button on pad1. After doing all the complex stuff to get this to work, and receiving the problem I will describe shortly, I simplified the situation to having Sprite[1] rotate in a circle. So: void main(void) { ... handlePad1(); ... RotateCW(&Sprite[1], 5); ... } This runs fine as long as Sprite(0) is not moving, but when there is a non-zero value for the pad1 buffer, the program freezes and I get this message: GPU timeout:que=1,stat=5602220f,chcr-01000401,madr=0000000d,func=(80029e50)(801e 052c, 00000000) What could cause a GPU timeout like this? If I comment out the RotateCW line, everything works normally. - Tony