L_DoubleBufferCreateHandle

#include "l_bitmap.h"

L_LTDIS_API L_INT L_DoubleBufferCreateHandle(phDoubleBufferHandle)

L_HANDLE* phDoubleBufferHandle;

/* address of the double buffer handle */

Creates the handle that is used throughout the double buffering.

Parameter

Description

phDoubleBufferHandle

Address of the handle that identifies the double buffering process. If successful, phDoubleBufferHandle points to the handle of the double buffering process.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

This function is the first step of a double buffering process. Declare a variable of type L_HANDLE, and pass the address of this variable to L_DoubleBufferCreateHandle. If successful, your variable will contain a double buffering handle that will be used throughout the double buffering process. When you are finished with the handle, you must call L_DoubleBufferDestroyHandle.

You may decide to call this function only one time for you application. If your application is MDI, and you want to double buffer several windows simultaneously, you may want to call this function once for each child window. The latter is the technique used in the C DLL annotation demo (annot32.exe).

For more information, see the topic Minimizing Flicker With Double Buffering.

Required DLLs and Libraries

LTDIS

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application.

Platforms

Windows 2000 / XP/Vista.

See Also

Functions:

L_DoubleBufferEnable, L_DoubleBufferDestroyHandle, L_DoubleBufferBegin, L_DoubleBufferEnd

Topics:

Raster Image Functions: Displaying Images

 

Minimizing Flicker With Double Buffering

Example

To see how double buffering can be used in an application, see the source code for the API annotation demo.