You allocate a Region data structure with the NewRegion() call.
struct Region *NewRegion( void );
The NewRegion() function allocates and initializes a Region structure that
has no drawable areas defined in it. If the application draws through a
new region, nothing will be drawn as the region is empty. The application
must add rectangles to the region before any graphics will appear.
Use DisposeRegion() to free the Region structure when you are done with it.
void DisposeRegion( struct Region *region );
DisposeRegion() returns all memory associated with a region to the system
and deallocates all rectangles that have been linked to it.
Don't Forget to Free Your Rectangles.
-------------------------------------
All of the functions that add rectangles to the region make copies
of the rectangles. If the program allocates a rectangle, then adds
it to a region, it still must deallocate the rectangle. The call to
DisposeRegion() will not deallocate rectangles explicitly
allocated by the application.