The buffer region extension is a mechanism that allows an area of an OpenGL window to be saved in off-screen memory for quick restores. The off-screen memory can either be frame buffer memory or system memory, although frame buffer memory might offer optimal performance.
A buffer region can be created for the front color, back color, depth, and/or stencil buffer. Multiple buffer regions for the same buffer type can exist.
| Modifier and Type | Field and Description |
|---|---|
| public static final int | WGL_BACK_COLOR_BUFFER_BIT_ARB
Accepted by the |
| public static final int | WGL_DEPTH_BUFFER_BIT_ARB
Accepted by the |
| public static final int | WGL_FRONT_COLOR_BUFFER_BIT_ARB
Accepted by the |
| public static final int | WGL_STENCIL_BUFFER_BIT_ARB
Accepted by the |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description | ||||
|---|---|---|---|---|---|
| public static long | wglCreateBufferRegionARB(long
the device context for the device on which the buffer region is created hdc, int the layer plane. Positive values identify overlay planes, negative values identify underlay planes. A value of 0 identifies the main plane. layerPlane, int a bitwise OR of any of the following values indicating which buffers can be saved or restored. Multiple bits can be set and may result in better
performance if multiple buffers are saved or restored. One of: type)
Creates a buffer region and returns a handle associated with it. | ||||
| public static void | wglDeleteBufferRegionARB(long
a handle to a buffer region previously created with region)CreateBufferRegionARB.Deletes a buffer region. | ||||
| public static boolean | wglRestoreBufferRegionARB(long
a handle to a buffer region previously created with region, int CreateBufferRegionARB.the window x-coordinate for the destination rectangle x, int the window y-coordinate for the destination rectangle y, int the destination rectangle width width, int the destination rectangle height height, int the buffer region x-coordinate for the source of the data xSrc, int the buffer region y-coordinate for the source of the data ySrc)Restores a previously saved buffer region. | ||||
| public static boolean | wglSaveBufferRegionARB(long
a handle to a buffer region previously created with region, int CreateBufferRegionARB.the window x-coordinate for the source rectangle x, int the window y-coordinate for the source rectangle y, int the source rectangle width width, int the source rectangle height height)Saves image, depth, and stencil data into the buffer region. |
| WGL_BACK_COLOR_BUFFER_BIT_ARB | back to summary |
|---|---|
| public static final int WGL_BACK_COLOR_BUFFER_BIT_ARB Accepted by the | |
| WGL_DEPTH_BUFFER_BIT_ARB | back to summary |
|---|---|
| public static final int WGL_DEPTH_BUFFER_BIT_ARB Accepted by the | |
| WGL_FRONT_COLOR_BUFFER_BIT_ARB | back to summary |
|---|---|
| public static final int WGL_FRONT_COLOR_BUFFER_BIT_ARB Accepted by the | |
| WGL_STENCIL_BUFFER_BIT_ARB | back to summary |
|---|---|
| public static final int WGL_STENCIL_BUFFER_BIT_ARB Accepted by the | |
| WGLARBBufferRegion | back to summary |
|---|---|
| protected WGLARBBufferRegion() | |
| wglCreateBufferRegionARB | back to summary | ||||
|---|---|---|---|---|---|
| public static long wglCreateBufferRegionARB(long hdc, int layerPlane, int type) Creates a buffer region and returns a handle associated with it.
| |||||
| wglDeleteBufferRegionARB | back to summary |
|---|---|
| public static void wglDeleteBufferRegionARB(long region) Deletes a buffer region.
| |
| wglRestoreBufferRegionARB | back to summary |
|---|---|
| public static boolean wglRestoreBufferRegionARB(long region, int x, int y, int width, int height, int xSrc, int ySrc) Restores a previously saved buffer region.
| |
| wglSaveBufferRegionARB | back to summary |
|---|---|
| public static boolean wglSaveBufferRegionARB(long region, int x, int y, int width, int height) Saves image, depth, and stencil data into the buffer region. Data outside the window for the specified rectangle is undefined. The OpenGL coordinate system is used for specifying the rectangle ( If an RC is current to the calling thread, a flush will occur before the save operation. The saved buffer region area can be freed by calling
| |