[futurebasic] Disposing of region handle

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : January 2002 : Group Archive : Group : All Groups

From: Bernie Wylde <bernie@...>
Date: Thu, 31 Jan 2002 15:43:26 +0000
Hi Everyone,

During animation, I check for collision by creating a region for one of my
moving objects and rects for others with FN RECTINRGN.

Is it safe to repeatedly call the following to create a new region each time
the object moves or should I be disposing of the region handle before
creating a new one?

humRgn = FN NEWRGN
OPENRGN
SETRECT(rgnRect,gHumRect.left,gHumRect.top,gHumRect.right,gHumRect.bottom)
FRAMERECT(rgnRect)
CLOSERGN(humRgn)

Any advice appreciated.

Cheers
Bernie