SCNewGWorld

The SCNewGWorld function creates a graphics world based on the current compression settings.

FUNCTION SCNewGWorld(ci as ComponentInstance,rp as Rect,flags as Integer) as GWorldPtr

ci
Identifies your application's connection to a standard image-compression dialog component.
gwp
Contains a pointer to a pointer to a graphics world. The standard dialog component places a pointer to the new graphics world into the field referred to by this parameter. If the component cannot create the graphics world, it sets this field to nil .
Your application is responsible for disposing of the graphics world when you are done with it.
rp
Contains a pointer to the boundaries of the graphics world. If you set this parameter to nil , the standard dialog component uses the test image's boundary rectangle. If you don't specify a boundary rectangle and there is no test image, the component does not create the graphics world.
flags
Contains flags that are passed to QuickDraw's NewGWorld function. See the chapter about NewGWorld for more info.

DESCRIPTION

The SCNewGWorld function creates a graphics world that can accommodate the current compression settings, including color table and grayscale settings (if appropriate). If the selected color table is inappropriate for the pixel depth, the standard dialog component uses a standard color for the depth.