MGL_destroyDC

Destroy a given device context.

Declaration

ibool MGLAPI MGL_destroyDC(
MGLDC *dc)

Prototype In

mgraph.h

Parameters

dc | Device context to be destroyed

Return Value

True if context was destroyed, false on error.

Description

Destroys a specified device context, freeing up all resources allocated by the device context. This can fail for a number of reasons, so check the MGL_result code to determine the cause of the failure.

If the device context that was destroyed was the last active display device context, the video mode is reset back to the original video mode (or back to the normal GDI desktop for Windows). Note that calling MGL_exit automatically destroys all currently allocated device contexts.

See Also

MGL_createDisplayDC, MGL_createOffscreenDC, MGL_createMemoryDC, MGL_createWindowedDC

Copyright © 2002 SciTech Software, Inc. Visit our web site at http://www.scitechsoft.com