public class EXTRobustness
extends java.lang.Object
Several recent trends in how OpenGL integrates into modern computer systems have created new requirements for robustness and security for OpenGL rendering contexts.
Additionally GPU architectures now support hardware fault detection; for example, video memory supporting ECC (error correcting codes) and error detection. OpenGL contexts should be capable of recovering from hardware faults such as uncorrectable memory errors. Along with recovery from such hardware faults, the recovery mechanism can also allow recovery from video memory access exceptions and system software failures. System software failures can be due to device changes or driver failures.
OpenGL queries that that return (write) some number of bytes to a buffer indicated by a pointer parameter introduce risk of buffer overflows that might be exploitable by malware. To address this, queries with return value sizes that are not expressed directly by the parameters to the query itself are given additional API functions with an additional parameter that specifies the number of bytes in the buffer and never writing bytes beyond that limit. This is particularly useful for multi-threaded usage of OpenGL contexts in a "share group" where one context can change objects in ways that can cause buffer overflows for another context's OpenGL queries.
The original ARB_vertex_buffer_object extension includes an issue that explicitly states program termination is allowed when out-of-bounds vertex buffer object fetches occur. Modern graphics hardware is capable well-defined behavior in the case of out-of- bounds vertex buffer object fetches. Older hardware may require extra checks to enforce well-defined (and termination free) behavior, but this expense is warranted when processing potentially untrusted content.
The intent of this extension is to address some specific robustness goals:
| Modifier and Type | Field and Description |
|---|---|
static int |
GL_CONTEXT_ROBUST_ACCESS_EXT
Accepted by the
value parameter of GetBooleanv, GetIntegerv, and GetFloatv. |
static int |
GL_GUILTY_CONTEXT_RESET_EXT
Returned by GetGraphicsResetStatusEXT.
|
static int |
GL_INNOCENT_CONTEXT_RESET_EXT
Returned by GetGraphicsResetStatusEXT.
|
static int |
GL_LOSE_CONTEXT_ON_RESET_EXT
Returned by GetIntegerv and related simple queries when
value is RESET_NOTIFICATION_STRATEGY_EXT . |
static int |
GL_NO_RESET_NOTIFICATION_EXT
Returned by GetIntegerv and related simple queries when
value is RESET_NOTIFICATION_STRATEGY_EXT . |
static int |
GL_RESET_NOTIFICATION_STRATEGY_EXT
Accepted by the
value parameter of GetBooleanv, GetIntegerv, and GetFloatv. |
static int |
GL_UNKNOWN_CONTEXT_RESET_EXT
Returned by GetGraphicsResetStatusEXT.
|
| Modifier and Type | Method and Description |
|---|---|
static int |
glGetGraphicsResetStatusEXT() |
static float |
glGetnUniformfEXT(int program,
int location) |
static void |
glGetnUniformfvEXT(int program,
int location,
float[] params)
Array version of:
GetnUniformfvEXT |
static void |
glGetnUniformfvEXT(int program,
int location,
java.nio.FloatBuffer params) |
static int |
glGetnUniformiEXT(int program,
int location) |
static void |
glGetnUniformivEXT(int program,
int location,
int[] params)
Array version of:
GetnUniformivEXT |
static void |
glGetnUniformivEXT(int program,
int location,
java.nio.IntBuffer params) |
static void |
glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
java.nio.ByteBuffer data) |
static void |
glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
float[] data)
Array version of:
ReadnPixelsEXT |
static void |
glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
java.nio.FloatBuffer data) |
static void |
glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
int[] data)
Array version of:
ReadnPixelsEXT |
static void |
glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
java.nio.IntBuffer data) |
static void |
glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
int bufSize,
long data) |
static void |
glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
short[] data)
Array version of:
ReadnPixelsEXT |
static void |
glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
java.nio.ShortBuffer data) |
static void |
nglGetnUniformfvEXT(int program,
int location,
int bufSize,
long params) |
static void |
nglGetnUniformivEXT(int program,
int location,
int bufSize,
long params) |
static void |
nglReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
int bufSize,
long data) |
public static final int GL_GUILTY_CONTEXT_RESET_EXT
public static final int GL_INNOCENT_CONTEXT_RESET_EXT
public static final int GL_UNKNOWN_CONTEXT_RESET_EXT
public static final int GL_CONTEXT_ROBUST_ACCESS_EXT
value parameter of GetBooleanv, GetIntegerv, and GetFloatv.public static final int GL_RESET_NOTIFICATION_STRATEGY_EXT
value parameter of GetBooleanv, GetIntegerv, and GetFloatv.public static final int GL_LOSE_CONTEXT_ON_RESET_EXT
value is RESET_NOTIFICATION_STRATEGY_EXT .public static final int GL_NO_RESET_NOTIFICATION_EXT
value is RESET_NOTIFICATION_STRATEGY_EXT .public static int glGetGraphicsResetStatusEXT()
public static void nglReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
int bufSize,
long data)
public static void glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
int bufSize,
long data)
public static void glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
java.nio.ByteBuffer data)
public static void glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
java.nio.ShortBuffer data)
public static void glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
java.nio.IntBuffer data)
public static void glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
java.nio.FloatBuffer data)
public static void nglGetnUniformfvEXT(int program,
int location,
int bufSize,
long params)
public static void glGetnUniformfvEXT(int program,
int location,
java.nio.FloatBuffer params)
public static float glGetnUniformfEXT(int program,
int location)
public static void nglGetnUniformivEXT(int program,
int location,
int bufSize,
long params)
public static void glGetnUniformivEXT(int program,
int location,
java.nio.IntBuffer params)
public static int glGetnUniformiEXT(int program,
int location)
public static void glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
short[] data)
ReadnPixelsEXTpublic static void glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
int[] data)
ReadnPixelsEXTpublic static void glReadnPixelsEXT(int x,
int y,
int width,
int height,
int format,
int type,
float[] data)
ReadnPixelsEXTpublic static void glGetnUniformfvEXT(int program,
int location,
float[] params)
GetnUniformfvEXTpublic static void glGetnUniformivEXT(int program,
int location,
int[] params)
GetnUniformivEXTCopyright LWJGL. All Rights Reserved. License terms.