Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
* @param internalformat the internal format with which the data will be stored in the buffer object
* @param format the format of the data in memory addressed by {@code data}. One of:
{@link GL11#GL_STENCIL_INDEX STENCIL_INDEX}
{@link GL11#GL_DEPTH_COMPONENT DEPTH_COMPONENT}
{@link GL30#GL_DEPTH_STENCIL DEPTH_STENCIL}
{@link GL11#GL_RED RED}
{@link GL11#GL_GREEN GREEN}
{@link GL11#GL_BLUE BLUE}
{@link GL11#GL_ALPHA ALPHA}
{@link GL30#GL_RG RG}
{@link GL11#GL_RGB RGB}
{@link GL11#GL_RGBA RGBA}
{@link GL12#GL_BGR BGR}
{@link GL12#GL_BGRA BGRA}
{@link GL11#GL_LUMINANCE LUMINANCE}
{@link GL11#GL_LUMINANCE_ALPHA LUMINANCE_ALPHA}
{@link GL30#GL_RED_INTEGER RED_INTEGER}
{@link GL30#GL_GREEN_INTEGER GREEN_INTEGER}
{@link GL30#GL_BLUE_INTEGER BLUE_INTEGER}
{@link GL30#GL_ALPHA_INTEGER ALPHA_INTEGER}
{@link GL30#GL_RG_INTEGER RG_INTEGER}
{@link GL30#GL_RGB_INTEGER RGB_INTEGER}
{@link GL30#GL_RGBA_INTEGER RGBA_INTEGER}
{@link GL30#GL_BGR_INTEGER BGR_INTEGER}
{@link GL30#GL_BGRA_INTEGER BGRA_INTEGER}
* @param type the type of the data in memory addressed by {@code data}. One of:
* @param data the buffer containing the data to be used as the source of the constant fill value. The elements of data are converted by the GL into the format
* specified by internalformat, and then used to fill the specified range of the destination buffer. If data is {@code NULL}, then it is ignored and the
* sub-range of the buffer is filled with zeros.
*/
public static void glClearBufferData(int target, int internalformat, int format, int type, ByteBuffer data) {
nglClearBufferData(target, internalformat, format, type, memAddressSafe(data));
}
/**
*
* @param internalformat the internal format with which the data will be stored in the buffer object
* @param format the format of the data in memory addressed by {@code data}. One of:
{@link GL11#GL_STENCIL_INDEX STENCIL_INDEX}
{@link GL11#GL_DEPTH_COMPONENT DEPTH_COMPONENT}
{@link GL30#GL_DEPTH_STENCIL DEPTH_STENCIL}
{@link GL11#GL_RED RED}
{@link GL11#GL_GREEN GREEN}
{@link GL11#GL_BLUE BLUE}
{@link GL11#GL_ALPHA ALPHA}
{@link GL30#GL_RG RG}
{@link GL11#GL_RGB RGB}
{@link GL11#GL_RGBA RGBA}
{@link GL12#GL_BGR BGR}
{@link GL12#GL_BGRA BGRA}
{@link GL11#GL_LUMINANCE LUMINANCE}
{@link GL11#GL_LUMINANCE_ALPHA LUMINANCE_ALPHA}
{@link GL30#GL_RED_INTEGER RED_INTEGER}
{@link GL30#GL_GREEN_INTEGER GREEN_INTEGER}
{@link GL30#GL_BLUE_INTEGER BLUE_INTEGER}
{@link GL30#GL_ALPHA_INTEGER ALPHA_INTEGER}
{@link GL30#GL_RG_INTEGER RG_INTEGER}
{@link GL30#GL_RGB_INTEGER RGB_INTEGER}
{@link GL30#GL_RGBA_INTEGER RGBA_INTEGER}
{@link GL30#GL_BGR_INTEGER BGR_INTEGER}
{@link GL30#GL_BGRA_INTEGER BGRA_INTEGER}
* @param type the type of the data in memory addressed by {@code data}. One of:
* @param data the buffer containing the data to be used as the source of the constant fill value. The elements of data are converted by the GL into the format
* specified by internalformat, and then used to fill the specified range of the destination buffer. If data is {@code NULL}, then it is ignored and the
* sub-range of the buffer is filled with zeros.
*/
public static void glClearBufferData(int target, int internalformat, int format, int type, ShortBuffer data) {
nglClearBufferData(target, internalformat, format, type, memAddressSafe(data));
}
/**
*
* @param internalformat the internal format with which the data will be stored in the buffer object
* @param format the format of the data in memory addressed by {@code data}. One of:
{@link GL11#GL_STENCIL_INDEX STENCIL_INDEX}
{@link GL11#GL_DEPTH_COMPONENT DEPTH_COMPONENT}
{@link GL30#GL_DEPTH_STENCIL DEPTH_STENCIL}
{@link GL11#GL_RED RED}
{@link GL11#GL_GREEN GREEN}
{@link GL11#GL_BLUE BLUE}
{@link GL11#GL_ALPHA ALPHA}
{@link GL30#GL_RG RG}
{@link GL11#GL_RGB RGB}
{@link GL11#GL_RGBA RGBA}
{@link GL12#GL_BGR BGR}
{@link GL12#GL_BGRA BGRA}
{@link GL11#GL_LUMINANCE LUMINANCE}
{@link GL11#GL_LUMINANCE_ALPHA LUMINANCE_ALPHA}
{@link GL30#GL_RED_INTEGER RED_INTEGER}
{@link GL30#GL_GREEN_INTEGER GREEN_INTEGER}
{@link GL30#GL_BLUE_INTEGER BLUE_INTEGER}
{@link GL30#GL_ALPHA_INTEGER ALPHA_INTEGER}
{@link GL30#GL_RG_INTEGER RG_INTEGER}
{@link GL30#GL_RGB_INTEGER RGB_INTEGER}
{@link GL30#GL_RGBA_INTEGER RGBA_INTEGER}
{@link GL30#GL_BGR_INTEGER BGR_INTEGER}
{@link GL30#GL_BGRA_INTEGER BGRA_INTEGER}
* @param type the type of the data in memory addressed by {@code data}. One of:
* @param data the buffer containing the data to be used as the source of the constant fill value. The elements of data are converted by the GL into the format
* specified by internalformat, and then used to fill the specified range of the destination buffer. If data is {@code NULL}, then it is ignored and the
* sub-range of the buffer is filled with zeros.
*/
public static void glClearBufferData(int target, int internalformat, int format, int type, IntBuffer data) {
nglClearBufferData(target, internalformat, format, type, memAddressSafe(data));
}
/**
*
* @param internalformat the internal format with which the data will be stored in the buffer object
* @param format the format of the data in memory addressed by {@code data}. One of:
{@link GL11#GL_STENCIL_INDEX STENCIL_INDEX}
{@link GL11#GL_DEPTH_COMPONENT DEPTH_COMPONENT}
{@link GL30#GL_DEPTH_STENCIL DEPTH_STENCIL}
{@link GL11#GL_RED RED}
{@link GL11#GL_GREEN GREEN}
{@link GL11#GL_BLUE BLUE}
{@link GL11#GL_ALPHA ALPHA}
{@link GL30#GL_RG RG}
{@link GL11#GL_RGB RGB}
{@link GL11#GL_RGBA RGBA}
{@link GL12#GL_BGR BGR}
{@link GL12#GL_BGRA BGRA}
{@link GL11#GL_LUMINANCE LUMINANCE}
{@link GL11#GL_LUMINANCE_ALPHA LUMINANCE_ALPHA}
{@link GL30#GL_RED_INTEGER RED_INTEGER}
{@link GL30#GL_GREEN_INTEGER GREEN_INTEGER}
{@link GL30#GL_BLUE_INTEGER BLUE_INTEGER}
{@link GL30#GL_ALPHA_INTEGER ALPHA_INTEGER}
{@link GL30#GL_RG_INTEGER RG_INTEGER}
{@link GL30#GL_RGB_INTEGER RGB_INTEGER}
{@link GL30#GL_RGBA_INTEGER RGBA_INTEGER}
{@link GL30#GL_BGR_INTEGER BGR_INTEGER}
{@link GL30#GL_BGRA_INTEGER BGRA_INTEGER}
* @param type the type of the data in memory addressed by {@code data}. One of:
* @param data the buffer containing the data to be used as the source of the constant fill value. The elements of data are converted by the GL into the format
* specified by internalformat, and then used to fill the specified range of the destination buffer. If data is {@code NULL}, then it is ignored and the
* sub-range of the buffer is filled with zeros.
*/
public static void glClearBufferData(int target, int internalformat, int format, int type, FloatBuffer data) {
nglClearBufferData(target, internalformat, format, type, memAddressSafe(data));
}
// --- [ glClearBufferSubData ] ---
/** Unsafe version of: {@link #glClearBufferSubData ClearBufferSubData} */
public static native void nglClearBufferSubData(int target, int internalformat, long offset, long size, int format, int type, long data);
/**
*
* @param internalformat the internal format with which the data will be stored in the buffer object
* @param offset the offset, in basic machine units into the buffer object's data store at which to start filling
* @param size the size, in basic machine units of the range of the data store to fill
* @param format the format of the data in memory addressed by {@code data}. One of:
{@link GL11#GL_STENCIL_INDEX STENCIL_INDEX}
{@link GL11#GL_DEPTH_COMPONENT DEPTH_COMPONENT}
{@link GL30#GL_DEPTH_STENCIL DEPTH_STENCIL}
{@link GL11#GL_RED RED}
{@link GL11#GL_GREEN GREEN}
{@link GL11#GL_BLUE BLUE}
{@link GL11#GL_ALPHA ALPHA}
{@link GL30#GL_RG RG}
{@link GL11#GL_RGB RGB}
{@link GL11#GL_RGBA RGBA}
{@link GL12#GL_BGR BGR}
{@link GL12#GL_BGRA BGRA}
{@link GL11#GL_LUMINANCE LUMINANCE}
{@link GL11#GL_LUMINANCE_ALPHA LUMINANCE_ALPHA}
{@link GL30#GL_RED_INTEGER RED_INTEGER}
{@link GL30#GL_GREEN_INTEGER GREEN_INTEGER}
{@link GL30#GL_BLUE_INTEGER BLUE_INTEGER}
{@link GL30#GL_ALPHA_INTEGER ALPHA_INTEGER}
{@link GL30#GL_RG_INTEGER RG_INTEGER}
{@link GL30#GL_RGB_INTEGER RGB_INTEGER}
{@link GL30#GL_RGBA_INTEGER RGBA_INTEGER}
{@link GL30#GL_BGR_INTEGER BGR_INTEGER}
{@link GL30#GL_BGRA_INTEGER BGRA_INTEGER}
* @param type the type of the data in memory addressed by {@code data}. One of:
* @param data the buffer containing the data to be used as the source of the constant fill value. The elements of data are converted by the GL into the format
* specified by internalformat, and then used to fill the specified range of the destination buffer. If data is {@code NULL}, then it is ignored and the
* sub-range of the buffer is filled with zeros.
*/
public static void glClearBufferSubData(int target, int internalformat, long offset, long size, int format, int type, ByteBuffer data) {
nglClearBufferSubData(target, internalformat, offset, size, format, type, memAddressSafe(data));
}
/**
*
* @param internalformat the internal format with which the data will be stored in the buffer object
* @param offset the offset, in basic machine units into the buffer object's data store at which to start filling
* @param size the size, in basic machine units of the range of the data store to fill
* @param format the format of the data in memory addressed by {@code data}. One of:
{@link GL11#GL_STENCIL_INDEX STENCIL_INDEX}
{@link GL11#GL_DEPTH_COMPONENT DEPTH_COMPONENT}
{@link GL30#GL_DEPTH_STENCIL DEPTH_STENCIL}
{@link GL11#GL_RED RED}
{@link GL11#GL_GREEN GREEN}
{@link GL11#GL_BLUE BLUE}
{@link GL11#GL_ALPHA ALPHA}
{@link GL30#GL_RG RG}
{@link GL11#GL_RGB RGB}
{@link GL11#GL_RGBA RGBA}
{@link GL12#GL_BGR BGR}
{@link GL12#GL_BGRA BGRA}
{@link GL11#GL_LUMINANCE LUMINANCE}
{@link GL11#GL_LUMINANCE_ALPHA LUMINANCE_ALPHA}
{@link GL30#GL_RED_INTEGER RED_INTEGER}
{@link GL30#GL_GREEN_INTEGER GREEN_INTEGER}
{@link GL30#GL_BLUE_INTEGER BLUE_INTEGER}
{@link GL30#GL_ALPHA_INTEGER ALPHA_INTEGER}
{@link GL30#GL_RG_INTEGER RG_INTEGER}
{@link GL30#GL_RGB_INTEGER RGB_INTEGER}
{@link GL30#GL_RGBA_INTEGER RGBA_INTEGER}
{@link GL30#GL_BGR_INTEGER BGR_INTEGER}
{@link GL30#GL_BGRA_INTEGER BGRA_INTEGER}
* @param type the type of the data in memory addressed by {@code data}. One of:
* @param data the buffer containing the data to be used as the source of the constant fill value. The elements of data are converted by the GL into the format
* specified by internalformat, and then used to fill the specified range of the destination buffer. If data is {@code NULL}, then it is ignored and the
* sub-range of the buffer is filled with zeros.
*/
public static void glClearBufferSubData(int target, int internalformat, long offset, long size, int format, int type, ShortBuffer data) {
nglClearBufferSubData(target, internalformat, offset, size, format, type, memAddressSafe(data));
}
/**
*
* @param internalformat the internal format with which the data will be stored in the buffer object
* @param offset the offset, in basic machine units into the buffer object's data store at which to start filling
* @param size the size, in basic machine units of the range of the data store to fill
* @param format the format of the data in memory addressed by {@code data}. One of:
{@link GL11#GL_STENCIL_INDEX STENCIL_INDEX}
{@link GL11#GL_DEPTH_COMPONENT DEPTH_COMPONENT}
{@link GL30#GL_DEPTH_STENCIL DEPTH_STENCIL}
{@link GL11#GL_RED RED}
{@link GL11#GL_GREEN GREEN}
{@link GL11#GL_BLUE BLUE}
{@link GL11#GL_ALPHA ALPHA}
{@link GL30#GL_RG RG}
{@link GL11#GL_RGB RGB}
{@link GL11#GL_RGBA RGBA}
{@link GL12#GL_BGR BGR}
{@link GL12#GL_BGRA BGRA}
{@link GL11#GL_LUMINANCE LUMINANCE}
{@link GL11#GL_LUMINANCE_ALPHA LUMINANCE_ALPHA}
{@link GL30#GL_RED_INTEGER RED_INTEGER}
{@link GL30#GL_GREEN_INTEGER GREEN_INTEGER}
{@link GL30#GL_BLUE_INTEGER BLUE_INTEGER}
{@link GL30#GL_ALPHA_INTEGER ALPHA_INTEGER}
{@link GL30#GL_RG_INTEGER RG_INTEGER}
{@link GL30#GL_RGB_INTEGER RGB_INTEGER}
{@link GL30#GL_RGBA_INTEGER RGBA_INTEGER}
{@link GL30#GL_BGR_INTEGER BGR_INTEGER}
{@link GL30#GL_BGRA_INTEGER BGRA_INTEGER}
* @param type the type of the data in memory addressed by {@code data}. One of:
* @param data the buffer containing the data to be used as the source of the constant fill value. The elements of data are converted by the GL into the format
* specified by internalformat, and then used to fill the specified range of the destination buffer. If data is {@code NULL}, then it is ignored and the
* sub-range of the buffer is filled with zeros.
*/
public static void glClearBufferSubData(int target, int internalformat, long offset, long size, int format, int type, IntBuffer data) {
nglClearBufferSubData(target, internalformat, offset, size, format, type, memAddressSafe(data));
}
/**
*
* @param internalformat the internal format with which the data will be stored in the buffer object
* @param offset the offset, in basic machine units into the buffer object's data store at which to start filling
* @param size the size, in basic machine units of the range of the data store to fill
* @param format the format of the data in memory addressed by {@code data}. One of:
{@link GL11#GL_STENCIL_INDEX STENCIL_INDEX}
{@link GL11#GL_DEPTH_COMPONENT DEPTH_COMPONENT}
{@link GL30#GL_DEPTH_STENCIL DEPTH_STENCIL}
{@link GL11#GL_RED RED}
{@link GL11#GL_GREEN GREEN}
{@link GL11#GL_BLUE BLUE}
{@link GL11#GL_ALPHA ALPHA}
{@link GL30#GL_RG RG}
{@link GL11#GL_RGB RGB}
{@link GL11#GL_RGBA RGBA}
{@link GL12#GL_BGR BGR}
{@link GL12#GL_BGRA BGRA}
{@link GL11#GL_LUMINANCE LUMINANCE}
{@link GL11#GL_LUMINANCE_ALPHA LUMINANCE_ALPHA}
{@link GL30#GL_RED_INTEGER RED_INTEGER}
{@link GL30#GL_GREEN_INTEGER GREEN_INTEGER}
{@link GL30#GL_BLUE_INTEGER BLUE_INTEGER}
{@link GL30#GL_ALPHA_INTEGER ALPHA_INTEGER}
{@link GL30#GL_RG_INTEGER RG_INTEGER}
{@link GL30#GL_RGB_INTEGER RGB_INTEGER}
{@link GL30#GL_RGBA_INTEGER RGBA_INTEGER}
{@link GL30#GL_BGR_INTEGER BGR_INTEGER}
{@link GL30#GL_BGRA_INTEGER BGRA_INTEGER}
* @param type the type of the data in memory addressed by {@code data}. One of:
* @param data the buffer containing the data to be used as the source of the constant fill value. The elements of data are converted by the GL into the format
* specified by internalformat, and then used to fill the specified range of the destination buffer. If data is {@code NULL}, then it is ignored and the
* sub-range of the buffer is filled with zeros.
*/
public static void glClearBufferSubData(int target, int internalformat, long offset, long size, int format, int type, FloatBuffer data) {
nglClearBufferSubData(target, internalformat, offset, size, format, type, memAddressSafe(data));
}
// --- [ glDispatchCompute ] ---
/**
*
*
* Launches one or more compute work groups.
*
* @param num_groups_x the number of work groups to be launched in the X dimension
* @param num_groups_y the number of work groups to be launched in the Y dimension
* @param num_groups_z the number of work groups to be launched in the Z dimension
*/
public static native void glDispatchCompute(int num_groups_x, int num_groups_y, int num_groups_z);
// --- [ glDispatchComputeIndirect ] ---
/** Unsafe version of: {@link #glDispatchComputeIndirect DispatchComputeIndirect} */
public static native void nglDispatchComputeIndirect(long indirect);
/**
*
*
* @param indirect the offset into the buffer object currently bound to the {@link #GL_DISPATCH_INDIRECT_BUFFER DISPATCH_INDIRECT_BUFFER} buffer target at which the dispatch parameters are
* stored.
*/
public static void glDispatchComputeIndirect(long indirect) {
nglDispatchComputeIndirect(indirect);
}
// --- [ glCopyImageSubData ] ---
/**
*
*
* Performs a raw data copy between two images.
*
* @param srcName the name of a texture or renderbuffer object from which to copy
* @param srcTarget the target representing the namespace of the source name {@code srcName}
* @param srcLevel the mipmap level to read from the source
* @param srcX the X coordinate of the left edge of the souce region to copy
* @param srcY the Y coordinate of the top edge of the souce region to copy
* @param srcZ the Z coordinate of the near edge of the souce region to copy
* @param dstName the name of a texture or renderbuffer object to which to copy
* @param dstTarget the target representing the namespace of the destination name {@code dstName}
* @param dstLevel the mipmap level to write to the source
* @param dstX the X coordinate of the left edge of the destination region
* @param dstY the Y coordinate of the top edge of the destination region
* @param dstZ the Z coordinate of the near edge of the destination region
* @param srcWidth the width of the region to be copied
* @param srcHeight the height of the region to be copied
* @param srcDepth the depth of the region to be copied
*/
public static native void glCopyImageSubData(int srcName, int srcTarget, int srcLevel, int srcX, int srcY, int srcZ, int dstName, int dstTarget, int dstLevel, int dstX, int dstY, int dstZ, int srcWidth, int srcHeight, int srcDepth);
// --- [ glDebugMessageControl ] ---
/**
* Unsafe version of: {@link #glDebugMessageControl DebugMessageControl}
*
* @param count the length of the array {@code ids}
*/
public static native void nglDebugMessageControl(int source, int type, int severity, int count, long ids, boolean enabled);
/**
*
*
* Controls the volume of debug output in the active debug group, by disabling specific or groups of messages.
*
*
If {@code enabled} is {@link GL11#GL_TRUE TRUE}, the referenced subset of messages will be enabled. If {@link GL11#GL_FALSE FALSE}, then those messages will be disabled.
*
*
This command can reference different subsets of messages by first considering the set of all messages, and filtering out messages based on the following
* ways:
*
*
*
If {@code source}, {@code type}, or {@code severity} is {@link GL11#GL_DONT_CARE DONT_CARE}, the messages from all sources, of all types, or of all severities are
* referenced respectively.
*
When values other than {@link GL11#GL_DONT_CARE DONT_CARE} are specified, all messages whose source, type, or severity match the specified {@code source}, {@code type},
* or {@code severity} respectively will be referenced.
*
If {@code count} is greater than zero, then {@code ids} is an array of {@code count} message IDs for the specified combination of {@code source} and
* {@code type}. In this case, if {@code source} or {@code type} is {@link GL11#GL_DONT_CARE DONT_CARE}, or {@code severity} is not {@link GL11#GL_DONT_CARE DONT_CARE}, the error
* {@link GL11#GL_INVALID_OPERATION INVALID_OPERATION} is generated.
*
*
*
Unrecognized message IDs in {@code ids} are ignored. If {@code count} is zero, the value if {@code ids} is ignored.
*
*
Although messages are grouped into an implicit hierarchy by their sources and types, there is no explicit per-source, per-type or per-severity enabled
* state. Instead, the enabled state is stored individually for each message. There is no difference between disabling all messages from one source in a
* single call, and individually disabling all messages from that source using their types and IDs.
*
*
If the {@link #GL_DEBUG_OUTPUT DEBUG_OUTPUT} state is disabled the GL operates the same as if messages of every {@code source}, {@code type} or {@code severity} are disabled.
*
* @param source the source of debug messages to enable or disable. One of:
* @param ids an array of unsigned integers containing the ids of the messages to enable or disable
* @param enabled whether the selected messages should be enabled or disabled
*/
public static void glDebugMessageControl(int source, int type, int severity, IntBuffer ids, boolean enabled) {
nglDebugMessageControl(source, type, severity, remainingSafe(ids), memAddressSafe(ids), enabled);
}
/**
*
*
* Controls the volume of debug output in the active debug group, by disabling specific or groups of messages.
*
*
If {@code enabled} is {@link GL11#GL_TRUE TRUE}, the referenced subset of messages will be enabled. If {@link GL11#GL_FALSE FALSE}, then those messages will be disabled.
*
*
This command can reference different subsets of messages by first considering the set of all messages, and filtering out messages based on the following
* ways:
*
*
*
If {@code source}, {@code type}, or {@code severity} is {@link GL11#GL_DONT_CARE DONT_CARE}, the messages from all sources, of all types, or of all severities are
* referenced respectively.
*
When values other than {@link GL11#GL_DONT_CARE DONT_CARE} are specified, all messages whose source, type, or severity match the specified {@code source}, {@code type},
* or {@code severity} respectively will be referenced.
*
If {@code count} is greater than zero, then {@code ids} is an array of {@code count} message IDs for the specified combination of {@code source} and
* {@code type}. In this case, if {@code source} or {@code type} is {@link GL11#GL_DONT_CARE DONT_CARE}, or {@code severity} is not {@link GL11#GL_DONT_CARE DONT_CARE}, the error
* {@link GL11#GL_INVALID_OPERATION INVALID_OPERATION} is generated.
*
*
*
Unrecognized message IDs in {@code ids} are ignored. If {@code count} is zero, the value if {@code ids} is ignored.
*
*
Although messages are grouped into an implicit hierarchy by their sources and types, there is no explicit per-source, per-type or per-severity enabled
* state. Instead, the enabled state is stored individually for each message. There is no difference between disabling all messages from one source in a
* single call, and individually disabling all messages from that source using their types and IDs.
*
*
If the {@link #GL_DEBUG_OUTPUT DEBUG_OUTPUT} state is disabled the GL operates the same as if messages of every {@code source}, {@code type} or {@code severity} are disabled.
*
* @param source the source of debug messages to enable or disable. One of:
* @param enabled whether the selected messages should be enabled or disabled
*/
public static void glDebugMessageControl(int source, int type, int severity, int id, boolean enabled) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
IntBuffer ids = stack.ints(id);
nglDebugMessageControl(source, type, severity, 1, memAddress(ids), enabled);
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glDebugMessageInsert ] ---
/**
* Unsafe version of: {@link #glDebugMessageInsert DebugMessageInsert}
*
* @param length the length of the string contained in the character array whose address is given by {@code message}
*/
public static native void nglDebugMessageInsert(int source, int type, int id, int severity, int length, long message);
/**
*
*
* This function can be called by applications and third-party libraries to generate their own messages, such as ones containing timestamp information or
* signals about specific render system events.
*
*
The value of {@code id} specifies the ID for the message and {@code severity} indicates its severity level as defined by the caller. The string
* {@code buf} contains the string representation of the message. The parameter {@code length} contains the number of characters in {@code buf}. If
* {@code length} is negative, it is implied that {@code buf} contains a null terminated string. The error {@link GL11#GL_INVALID_VALUE INVALID_VALUE} will be generated if the
* number of characters in {@code buf}, excluding the null terminator when {@code length} is negative, is not less than the value of
* {@link #GL_MAX_DEBUG_MESSAGE_LENGTH MAX_DEBUG_MESSAGE_LENGTH}.
*
*
If the {@link #GL_DEBUG_OUTPUT DEBUG_OUTPUT} state is disabled calls to DebugMessageInsert are discarded and do not generate an error.
*
* @param source the source of the debug message to insert. One of:
* @param severity the severity of the debug messages to insert
* @param message a character array containing the message to insert
*/
public static void glDebugMessageInsert(int source, int type, int id, int severity, ByteBuffer message) {
nglDebugMessageInsert(source, type, id, severity, message.remaining(), memAddress(message));
}
/**
*
*
* This function can be called by applications and third-party libraries to generate their own messages, such as ones containing timestamp information or
* signals about specific render system events.
*
*
The value of {@code id} specifies the ID for the message and {@code severity} indicates its severity level as defined by the caller. The string
* {@code buf} contains the string representation of the message. The parameter {@code length} contains the number of characters in {@code buf}. If
* {@code length} is negative, it is implied that {@code buf} contains a null terminated string. The error {@link GL11#GL_INVALID_VALUE INVALID_VALUE} will be generated if the
* number of characters in {@code buf}, excluding the null terminator when {@code length} is negative, is not less than the value of
* {@link #GL_MAX_DEBUG_MESSAGE_LENGTH MAX_DEBUG_MESSAGE_LENGTH}.
*
*
If the {@link #GL_DEBUG_OUTPUT DEBUG_OUTPUT} state is disabled calls to DebugMessageInsert are discarded and do not generate an error.
*
* @param source the source of the debug message to insert. One of:
*
* Specifies a callback to receive debugging messages from the GL.
*
*
The function's prototype must follow the type definition of DEBUGPROC including its platform-dependent calling convention. Anything else will result in
* undefined behavior. Only one debug callback can be specified for the current context, and further calls overwrite the previous callback. Specifying
* {@code NULL} as the value of {@code callback} clears the current callback and disables message output through callbacks. Applications can provide
* user-specified data through the pointer {@code userParam}. The context will store this pointer and will include it as one of the parameters in each call
* to the callback function.
*
*
If the application has specified a callback function for receiving debug output, the implementation will call that function whenever any enabled message
* is generated. The source, type, ID, and severity of the message are specified by the DEBUGPROC parameters {@code source}, {@code type}, {@code id}, and
* {@code severity}, respectively. The string representation of the message is stored in {@code message} and its length (excluding the null-terminator) is
* stored in {@code length}. The parameter {@code userParam} is the user-specified parameter that was given when calling DebugMessageCallback.
*
*
Applications can query the current callback function and the current user-specified parameter by obtaining the values of {@link #GL_DEBUG_CALLBACK_FUNCTION DEBUG_CALLBACK_FUNCTION} and
* {@link #GL_DEBUG_CALLBACK_USER_PARAM DEBUG_CALLBACK_USER_PARAM}, respectively.
*
*
Applications that specify a callback function must be aware of certain special conditions when executing code inside a callback when it is called by the
* GL, regardless of the debug source.
*
*
The memory for {@code message} is owned and managed by the GL, and should only be considered valid for the duration of the function call.
*
*
The behavior of calling any GL or window system function from within the callback function is undefined and may lead to program termination.
*
*
Care must also be taken in securing debug callbacks for use with asynchronous debug output by multi-threaded GL implementations.
*
*
If the {@link #GL_DEBUG_OUTPUT DEBUG_OUTPUT} state is disabled then the GL will not call the callback function.
*
* @param callback a callback function that will be called when a debug message is generated
* @param userParam a user supplied pointer that will be passed on each invocation of {@code callback}
*/
public static void glDebugMessageCallback(GLDebugMessageCallbackI callback, long userParam) {
nglDebugMessageCallback(memAddressSafe(callback), userParam);
}
// --- [ glGetDebugMessageLog ] ---
/**
* Unsafe version of: {@link #glGetDebugMessageLog GetDebugMessageLog}
*
* @param bufsize the size of the buffer whose address is given by {@code messageLog}
*/
public static native int nglGetDebugMessageLog(int count, int bufsize, long sources, long types, long ids, long severities, long lengths, long messageLog);
/**
*
*
* Retrieves messages from the debug message log.
*
*
This function fetches a maximum of {@code count} messages from the message log, and will return the number of messages successfully fetched.
*
*
Messages will be fetched from the log in order of oldest to newest. Those messages that were fetched will be removed from the log.
*
*
The sources, types, severities, IDs, and string lengths of fetched messages will be stored in the application-provided arrays {@code sources},
* {@code types}, {@code severities}, {@code ids}, and {@code lengths}, respectively. The application is responsible for allocating enough space for each
* array to hold up to {@code count} elements. The string representations of all fetched messages are stored in the {@code messageLog} array. If multiple
* messages are fetched, their strings are concatenated into the same {@code messageLog} array and will be separated by single null terminators. The last
* string in the array will also be null-terminated. The maximum size of {@code messageLog}, including the space used by all null terminators, is given by
* {@code bufSize}. If {@code bufSize} is less than zero and {@code messageLog} is not {@code NULL}, an {@link GL11#GL_INVALID_VALUE INVALID_VALUE} error will be generated. If a message's
* string, including its null terminator, can not fully fit within the {@code messageLog} array's remaining space, then that message and any subsequent
* messages will not be fetched and will remain in the log. The string lengths stored in the array {@code lengths} include the space for the null
* terminator of each string.
*
*
Any or all of the arrays {@code sources}, {@code types}, {@code ids}, {@code severities}, {@code lengths} and {@code messageLog} can also be null
* pointers, which causes the attributes for such arrays to be discarded when messages are fetched, however those messages will still be removed from the
* log. Thus to simply delete up to {@code count} messages from the message log while ignoring their attributes, the application can call the function
* with null pointers for all attribute arrays.
*
*
If the context was created without the {@link #GL_CONTEXT_FLAG_DEBUG_BIT CONTEXT_FLAG_DEBUG_BIT} in the {@link GL30#GL_CONTEXT_FLAGS CONTEXT_FLAGS} state, then the GL can opt to never add messages to the
* message log so GetDebugMessageLog will always return zero.
*
* @param count the number of debug messages to retrieve from the log
* @param sources an array of variables to receive the sources of the retrieved messages
* @param types an array of variables to receive the types of the retrieved messages
* @param ids an array of unsigned integers to receive the ids of the retrieved messages
* @param severities an array of variables to receive the severites of the retrieved messages
* @param lengths an array of variables to receive the lengths of the received messages
* @param messageLog an array of characters that will receive the messages
*/
public static int glGetDebugMessageLog(int count, IntBuffer sources, IntBuffer types, IntBuffer ids, IntBuffer severities, IntBuffer lengths, ByteBuffer messageLog) {
if (CHECKS) {
checkSafe(sources, count);
checkSafe(types, count);
checkSafe(ids, count);
checkSafe(severities, count);
checkSafe(lengths, count);
}
return nglGetDebugMessageLog(count, remainingSafe(messageLog), memAddressSafe(sources), memAddressSafe(types), memAddressSafe(ids), memAddressSafe(severities), memAddressSafe(lengths), memAddressSafe(messageLog));
}
// --- [ glPushDebugGroup ] ---
/**
* Unsafe version of: {@link #glPushDebugGroup PushDebugGroup}
*
* @param length the length of the message to be sent to the debug output stream
*/
public static native void nglPushDebugGroup(int source, int id, int length, long message);
/**
*
*
* Pushes a debug group described by the string {@code message} into the command stream. The value of {@code id} specifies the ID of messages generated.
* The parameter {@code length} contains the number of characters in {@code message}. If {@code length} is negative, it is implied that {@code message}
* contains a null terminated string. The message has the specified {@code source} and {@code id}, {@code type} {@link #GL_DEBUG_TYPE_PUSH_GROUP DEBUG_TYPE_PUSH_GROUP}, and
* {@code severity} {@link #GL_DEBUG_SEVERITY_NOTIFICATION DEBUG_SEVERITY_NOTIFICATION}. The GL will put a new debug group on top of the debug group stack which inherits the control of the
* volume of debug output of the debug group previously residing on the top of the debug group stack. Because debug groups are strictly hierarchical, any
* additional control of the debug output volume will only apply within the active debug group and the debug groups pushed on top of the active debug group.
*
*
An {@link GL11#GL_INVALID_ENUM INVALID_ENUM} error is generated if the value of {@code source} is neither {@link #GL_DEBUG_SOURCE_APPLICATION DEBUG_SOURCE_APPLICATION} nor {@link #GL_DEBUG_SOURCE_THIRD_PARTY DEBUG_SOURCE_THIRD_PARTY}. An
* {@link GL11#GL_INVALID_VALUE INVALID_VALUE} error is generated if {@code length} is negative and the number of characters in {@code message}, excluding the null-terminator, is
* not less than the value of {@link #GL_MAX_DEBUG_MESSAGE_LENGTH MAX_DEBUG_MESSAGE_LENGTH}.
*
* @param source the source of the debug message. One of:
* @param id the identifier of the message
* @param message a string containing the message to be sent to the debug output stream
*/
public static void glPushDebugGroup(int source, int id, ByteBuffer message) {
nglPushDebugGroup(source, id, message.remaining(), memAddress(message));
}
/**
*
*
* Pushes a debug group described by the string {@code message} into the command stream. The value of {@code id} specifies the ID of messages generated.
* The parameter {@code length} contains the number of characters in {@code message}. If {@code length} is negative, it is implied that {@code message}
* contains a null terminated string. The message has the specified {@code source} and {@code id}, {@code type} {@link #GL_DEBUG_TYPE_PUSH_GROUP DEBUG_TYPE_PUSH_GROUP}, and
* {@code severity} {@link #GL_DEBUG_SEVERITY_NOTIFICATION DEBUG_SEVERITY_NOTIFICATION}. The GL will put a new debug group on top of the debug group stack which inherits the control of the
* volume of debug output of the debug group previously residing on the top of the debug group stack. Because debug groups are strictly hierarchical, any
* additional control of the debug output volume will only apply within the active debug group and the debug groups pushed on top of the active debug group.
*
*
An {@link GL11#GL_INVALID_ENUM INVALID_ENUM} error is generated if the value of {@code source} is neither {@link #GL_DEBUG_SOURCE_APPLICATION DEBUG_SOURCE_APPLICATION} nor {@link #GL_DEBUG_SOURCE_THIRD_PARTY DEBUG_SOURCE_THIRD_PARTY}. An
* {@link GL11#GL_INVALID_VALUE INVALID_VALUE} error is generated if {@code length} is negative and the number of characters in {@code message}, excluding the null-terminator, is
* not less than the value of {@link #GL_MAX_DEBUG_MESSAGE_LENGTH MAX_DEBUG_MESSAGE_LENGTH}.
*
* @param source the source of the debug message. One of:
* @param id the identifier of the message
* @param message a string containing the message to be sent to the debug output stream
*/
public static void glPushDebugGroup(int source, int id, CharSequence message) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
ByteBuffer messageEncoded = stack.UTF8(message, false);
nglPushDebugGroup(source, id, messageEncoded.remaining(), memAddress(messageEncoded));
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glPopDebugGroup ] ---
/**
*
*
* Pops the active debug group. When a debug group is popped, the GL will also generate a debug output message describing its cause based on the
* {@code message} string, the source {@code source}, and an ID {@code id} submitted to the associated {@link #glPushDebugGroup PushDebugGroup} command. {@link #GL_DEBUG_TYPE_PUSH_GROUP DEBUG_TYPE_PUSH_GROUP}
* and {@link #GL_DEBUG_TYPE_POP_GROUP DEBUG_TYPE_POP_GROUP} share a single namespace for message {@code id}. {@code severity} has the value {@link #GL_DEBUG_SEVERITY_NOTIFICATION DEBUG_SEVERITY_NOTIFICATION}. The {@code type}
* has the value {@link #GL_DEBUG_TYPE_POP_GROUP DEBUG_TYPE_POP_GROUP}. Popping a debug group restores the debug output volume control of the parent debug group.
*
*
Attempting to pop the default debug group off the stack generates a {@link GL11#GL_STACK_UNDERFLOW STACK_UNDERFLOW} error; pushing a debug group onto a stack containing
* {@link #GL_MAX_DEBUG_GROUP_STACK_DEPTH MAX_DEBUG_GROUP_STACK_DEPTH} minus one elements will generate a {@link GL11#GL_STACK_OVERFLOW STACK_OVERFLOW} error.
*/
public static native void glPopDebugGroup();
// --- [ glObjectLabel ] ---
/**
* Unsafe version of: {@link #glObjectLabel ObjectLabel}
*
* @param length the length of the label to be used for the object
*/
public static native void nglObjectLabel(int identifier, int name, int length, long label);
/**
*
* @param name the name of the object to label
* @param label a string containing the label to assign to the object
*/
public static void glObjectLabel(int identifier, int name, ByteBuffer label) {
nglObjectLabel(identifier, name, label.remaining(), memAddress(label));
}
/**
*
* @param name the name of the object to label
* @param label a string containing the label to assign to the object
*/
public static void glObjectLabel(int identifier, int name, CharSequence label) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
ByteBuffer labelEncoded = stack.UTF8(label, false);
nglObjectLabel(identifier, name, labelEncoded.remaining(), memAddress(labelEncoded));
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glGetObjectLabel ] ---
/**
* Unsafe version of: {@link #glGetObjectLabel GetObjectLabel}
*
* @param bufSize the length of the buffer whose address is in {@code label}
*/
public static native void nglGetObjectLabel(int identifier, int name, int bufSize, long length, long label);
/**
*
*
* Retrieves the label of a named object identified within a namespace.
*
* @param identifier the namespace from which the name of the object is allocated. One of:
* @param name the name of the object whose label to retrieve
* @param length the address of a variable to receive the length of the object label
* @param label a string that will receive the object label
*/
public static void glGetObjectLabel(int identifier, int name, IntBuffer length, ByteBuffer label) {
if (CHECKS) {
checkSafe(length, 1);
}
nglGetObjectLabel(identifier, name, label.remaining(), memAddressSafe(length), memAddress(label));
}
/**
*
*
* Retrieves the label of a named object identified within a namespace.
*
* @param identifier the namespace from which the name of the object is allocated. One of:
* @param name the name of the object whose label to retrieve
* @param bufSize the length of the buffer whose address is in {@code label}
*/
public static String glGetObjectLabel(int identifier, int name, int bufSize) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
IntBuffer length = stack.ints(0);
ByteBuffer label = stack.malloc(bufSize);
nglGetObjectLabel(identifier, name, bufSize, memAddress(length), memAddress(label));
return memUTF8(label, length.get(0));
} finally {
stack.setPointer(stackPointer);
}
}
/**
*
*
* Retrieves the label of a named object identified within a namespace.
*
* @param identifier the namespace from which the name of the object is allocated. One of:
* @param name the name of the object whose label to retrieve
*/
public static String glGetObjectLabel(int identifier, int name) {
return glGetObjectLabel(identifier, name, GL11.glGetInteger(GL_MAX_LABEL_LENGTH));
}
// --- [ glObjectPtrLabel ] ---
/**
* Unsafe version of: {@link #glObjectPtrLabel ObjectPtrLabel}
*
* @param length the length of the label to be used for the object
*/
public static native void nglObjectPtrLabel(long ptr, int length, long label);
/**
*
*
* Labels a sync object identified by a pointer.
*
* @param ptr a pointer identifying a sync object
* @param label a string containing the label to assign to the object
*/
public static void glObjectPtrLabel(long ptr, ByteBuffer label) {
if (CHECKS) {
check(ptr);
}
nglObjectPtrLabel(ptr, label.remaining(), memAddress(label));
}
/**
*
*
* Labels a sync object identified by a pointer.
*
* @param ptr a pointer identifying a sync object
* @param label a string containing the label to assign to the object
*/
public static void glObjectPtrLabel(long ptr, CharSequence label) {
if (CHECKS) {
check(ptr);
}
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
ByteBuffer labelEncoded = stack.UTF8(label, false);
nglObjectPtrLabel(ptr, labelEncoded.remaining(), memAddress(labelEncoded));
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glGetObjectPtrLabel ] ---
/**
* Unsafe version of: {@link #glGetObjectPtrLabel GetObjectPtrLabel}
*
* @param bufSize the length of the buffer whose address is in {@code label}
*/
public static native void nglGetObjectPtrLabel(long ptr, int bufSize, long length, long label);
/**
*
*
* Retrieves the label of a sync object identified by a pointer.
*
* @param ptr the name of the sync object whose label to retrieve
* @param length a variable to receive the length of the object label
* @param label a string that will receive the object label
*/
public static void glGetObjectPtrLabel(long ptr, IntBuffer length, ByteBuffer label) {
if (CHECKS) {
check(ptr);
checkSafe(length, 1);
}
nglGetObjectPtrLabel(ptr, label.remaining(), memAddressSafe(length), memAddress(label));
}
/**
*
*
* Retrieves the label of a sync object identified by a pointer.
*
* @param ptr the name of the sync object whose label to retrieve
* @param bufSize the length of the buffer whose address is in {@code label}
*/
public static String glGetObjectPtrLabel(long ptr, int bufSize) {
if (CHECKS) {
check(ptr);
}
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
IntBuffer length = stack.ints(0);
ByteBuffer label = stack.malloc(bufSize);
nglGetObjectPtrLabel(ptr, bufSize, memAddress(length), memAddress(label));
return memUTF8(label, length.get(0));
} finally {
stack.setPointer(stackPointer);
}
}
/**
*
*
* Retrieves the label of a sync object identified by a pointer.
*
* @param ptr the name of the sync object whose label to retrieve
*/
public static String glGetObjectPtrLabel(long ptr) {
return glGetObjectPtrLabel(ptr, GL11.glGetInteger(GL_MAX_LABEL_LENGTH));
}
// --- [ glFramebufferParameteri ] ---
/**
*
* @param param the new value for the parameter named {@code pname}
*/
public static native void glFramebufferParameteri(int target, int pname, int param);
// --- [ glGetFramebufferParameteriv ] ---
/** Unsafe version of: {@link #glGetFramebufferParameteriv GetFramebufferParameteriv} */
public static native void nglGetFramebufferParameteriv(int target, int pname, long params);
/**
*
* @param params a variable to receive the value of the parameter named {@code pname}
*/
public static void glGetFramebufferParameteriv(int target, int pname, IntBuffer params) {
if (CHECKS) {
check(params, 1);
}
nglGetFramebufferParameteriv(target, pname, memAddress(params));
}
/**
*
*/
public static int glGetFramebufferParameteri(int target, int pname) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
IntBuffer params = stack.callocInt(1);
nglGetFramebufferParameteriv(target, pname, memAddress(params));
return params.get(0);
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glGetInternalformati64v ] ---
/**
* Unsafe version of: {@link #glGetInternalformati64v GetInternalformati64v}
*
* @param bufSize the maximum number of values that may be written to params by the function
*/
public static native void nglGetInternalformati64v(int target, int internalformat, int pname, int bufSize, long params);
/**
*
* @param internalformat the internal format about which to retrieve information
* @param pname the type of information to query
* @param params a variable into which to write the retrieved information
*/
public static void glGetInternalformati64v(int target, int internalformat, int pname, LongBuffer params) {
nglGetInternalformati64v(target, internalformat, pname, params.remaining(), memAddress(params));
}
/**
*
* @param internalformat the internal format about which to retrieve information
* @param pname the type of information to query
*/
public static long glGetInternalformati64(int target, int internalformat, int pname) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
LongBuffer params = stack.callocLong(1);
nglGetInternalformati64v(target, internalformat, pname, 1, memAddress(params));
return params.get(0);
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glInvalidateTexSubImage ] ---
/**
*
*
* Invalidates a region of a texture image.
*
* @param texture the name of a texture object a subregion of which to invalidate
* @param level the level of detail of the texture object within which the region resides
* @param xoffset the X offset of the region to be invalidated
* @param yoffset the Y offset of the region to be invalidated
* @param zoffset the Z offset of the region to be invalidated
* @param width the width of the region to be invalidated
* @param height the height of the region to be invalidated
* @param depth the depth of the region to be invalidated
*/
public static native void glInvalidateTexSubImage(int texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth);
// --- [ glInvalidateTexImage ] ---
/**
*
*
* Invalidates the entirety of a texture image.
*
* @param texture the name of a texture object to invalidate
* @param level the level of detail of the texture object to invalidate
*/
public static native void glInvalidateTexImage(int texture, int level);
// --- [ glInvalidateBufferSubData ] ---
/**
*
*
* Invalidates a region of a buffer object's data store.
*
* @param buffer the name of a buffer object, a subrange of whose data store to invalidate
* @param offset the offset within the buffer's data store of the start of the range to be invalidated
* @param length the length of the range within the buffer's data store to be invalidated
*/
public static native void glInvalidateBufferSubData(int buffer, long offset, long length);
// --- [ glInvalidateBufferData ] ---
/**
*
*
* Invalidates the content of a buffer object's data store.
*
* @param buffer the name of a buffer object whose data store to invalidate
*/
public static native void glInvalidateBufferData(int buffer);
// --- [ glInvalidateFramebuffer ] ---
/**
* Unsafe version of: {@link #glInvalidateFramebuffer InvalidateFramebuffer}
*
* @param numAttachments the number of entries in the {@code attachments} array
*/
public static native void nglInvalidateFramebuffer(int target, int numAttachments, long attachments);
/**
*
*
* Invalidate the content some or all of a framebuffer object's attachments.
*
* @param target the target to which the framebuffer is attached. One of:
{@link GL30#GL_FRAMEBUFFER FRAMEBUFFER}
{@link GL30#GL_DRAW_FRAMEBUFFER DRAW_FRAMEBUFFER}
{@link GL30#GL_READ_FRAMEBUFFER READ_FRAMEBUFFER}
* @param attachments the address of an array identifying the attachments to be invalidated
*/
public static void glInvalidateFramebuffer(int target, IntBuffer attachments) {
nglInvalidateFramebuffer(target, attachments.remaining(), memAddress(attachments));
}
/**
*
*
* Invalidate the content some or all of a framebuffer object's attachments.
*
* @param target the target to which the framebuffer is attached. One of:
{@link GL30#GL_FRAMEBUFFER FRAMEBUFFER}
{@link GL30#GL_DRAW_FRAMEBUFFER DRAW_FRAMEBUFFER}
{@link GL30#GL_READ_FRAMEBUFFER READ_FRAMEBUFFER}
*/
public static void glInvalidateFramebuffer(int target, int attachment) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
IntBuffer attachments = stack.ints(attachment);
nglInvalidateFramebuffer(target, 1, memAddress(attachments));
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glInvalidateSubFramebuffer ] ---
/**
* Unsafe version of: {@link #glInvalidateSubFramebuffer InvalidateSubFramebuffer}
*
* @param numAttachments the number of entries in the {@code attachments} array
*/
public static native void nglInvalidateSubFramebuffer(int target, int numAttachments, long attachments, int x, int y, int width, int height);
/**
*
*
* Invalidates the content of a region of some or all of a framebuffer object's attachments.
*
* @param target the target to which the framebuffer is attached. One of:
{@link GL30#GL_FRAMEBUFFER FRAMEBUFFER}
{@link GL30#GL_DRAW_FRAMEBUFFER DRAW_FRAMEBUFFER}
{@link GL30#GL_READ_FRAMEBUFFER READ_FRAMEBUFFER}
* @param attachments an array identifying the attachments to be invalidated
* @param x the X offset of the region to be invalidated
* @param y the Y offset of the region to be invalidated
* @param width the width of the region to be invalidated
* @param height the height of the region to be invalidated
*/
public static void glInvalidateSubFramebuffer(int target, IntBuffer attachments, int x, int y, int width, int height) {
nglInvalidateSubFramebuffer(target, attachments.remaining(), memAddress(attachments), x, y, width, height);
}
/**
*
*
* Invalidates the content of a region of some or all of a framebuffer object's attachments.
*
* @param target the target to which the framebuffer is attached. One of:
{@link GL30#GL_FRAMEBUFFER FRAMEBUFFER}
{@link GL30#GL_DRAW_FRAMEBUFFER DRAW_FRAMEBUFFER}
{@link GL30#GL_READ_FRAMEBUFFER READ_FRAMEBUFFER}
* @param x the X offset of the region to be invalidated
* @param y the Y offset of the region to be invalidated
* @param width the width of the region to be invalidated
* @param height the height of the region to be invalidated
*/
public static void glInvalidateSubFramebuffer(int target, int attachment, int x, int y, int width, int height) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
IntBuffer attachments = stack.ints(attachment);
nglInvalidateSubFramebuffer(target, 1, memAddress(attachments), x, y, width, height);
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glMultiDrawArraysIndirect ] ---
/** Unsafe version of: {@link #glMultiDrawArraysIndirect MultiDrawArraysIndirect} */
public static native void nglMultiDrawArraysIndirect(int mode, long indirect, int primcount, int stride);
/**
*
* @param indirect an array of structures containing the draw parameters
* @param primcount the number of elements in the array of draw parameter structures
* @param stride the distance in basic machine units between elements of the draw parameter array
*/
public static void glMultiDrawArraysIndirect(int mode, ByteBuffer indirect, int primcount, int stride) {
if (CHECKS) {
check(indirect, primcount * (stride == 0 ? (4 * 4) : stride));
}
nglMultiDrawArraysIndirect(mode, memAddress(indirect), primcount, stride);
}
/**
*
* @param indirect an array of structures containing the draw parameters
* @param primcount the number of elements in the array of draw parameter structures
* @param stride the distance in basic machine units between elements of the draw parameter array
*/
public static void glMultiDrawArraysIndirect(int mode, long indirect, int primcount, int stride) {
nglMultiDrawArraysIndirect(mode, indirect, primcount, stride);
}
/**
*
* @param indirect an array of structures containing the draw parameters
* @param primcount the number of elements in the array of draw parameter structures
* @param stride the distance in basic machine units between elements of the draw parameter array
*/
public static void glMultiDrawArraysIndirect(int mode, IntBuffer indirect, int primcount, int stride) {
if (CHECKS) {
check(indirect, (primcount * (stride == 0 ? (4 * 4) : stride)) >> 2);
}
nglMultiDrawArraysIndirect(mode, memAddress(indirect), primcount, stride);
}
// --- [ glMultiDrawElementsIndirect ] ---
/** Unsafe version of: {@link #glMultiDrawElementsIndirect MultiDrawElementsIndirect} */
public static native void nglMultiDrawElementsIndirect(int mode, int type, long indirect, int primcount, int stride);
/**
*
* @param type the type of data in the buffer bound to the GL_ELEMENT_ARRAY_BUFFER binding. One of:
{@link GL11#GL_UNSIGNED_BYTE UNSIGNED_BYTE}
{@link GL11#GL_UNSIGNED_SHORT UNSIGNED_SHORT}
{@link GL11#GL_UNSIGNED_INT UNSIGNED_INT}
* @param indirect a structure containing an array of draw parameters
* @param primcount the number of elements in the array addressed by {@code indirect}
* @param stride the distance in basic machine units between elements of the draw parameter array
*/
public static void glMultiDrawElementsIndirect(int mode, int type, ByteBuffer indirect, int primcount, int stride) {
if (CHECKS) {
check(indirect, primcount * (stride == 0 ? (5 * 4) : stride));
}
nglMultiDrawElementsIndirect(mode, type, memAddress(indirect), primcount, stride);
}
/**
*
* @param type the type of data in the buffer bound to the GL_ELEMENT_ARRAY_BUFFER binding. One of:
{@link GL11#GL_UNSIGNED_BYTE UNSIGNED_BYTE}
{@link GL11#GL_UNSIGNED_SHORT UNSIGNED_SHORT}
{@link GL11#GL_UNSIGNED_INT UNSIGNED_INT}
* @param indirect a structure containing an array of draw parameters
* @param primcount the number of elements in the array addressed by {@code indirect}
* @param stride the distance in basic machine units between elements of the draw parameter array
*/
public static void glMultiDrawElementsIndirect(int mode, int type, long indirect, int primcount, int stride) {
nglMultiDrawElementsIndirect(mode, type, indirect, primcount, stride);
}
/**
*
* @param type the type of data in the buffer bound to the GL_ELEMENT_ARRAY_BUFFER binding. One of:
{@link GL11#GL_UNSIGNED_BYTE UNSIGNED_BYTE}
{@link GL11#GL_UNSIGNED_SHORT UNSIGNED_SHORT}
{@link GL11#GL_UNSIGNED_INT UNSIGNED_INT}
* @param indirect a structure containing an array of draw parameters
* @param primcount the number of elements in the array addressed by {@code indirect}
* @param stride the distance in basic machine units between elements of the draw parameter array
*/
public static void glMultiDrawElementsIndirect(int mode, int type, IntBuffer indirect, int primcount, int stride) {
if (CHECKS) {
check(indirect, (primcount * (stride == 0 ? (5 * 4) : stride)) >> 2);
}
nglMultiDrawElementsIndirect(mode, type, memAddress(indirect), primcount, stride);
}
// --- [ glGetProgramInterfaceiv ] ---
/** Unsafe version of: {@link #glGetProgramInterfaceiv GetProgramInterfaceiv} */
public static native void nglGetProgramInterfaceiv(int program, int programInterface, int pname, long params);
/**
*
*
* Queries a property of an interface in a program.
*
* @param program the name of a program object whose interface to query
* @param programInterface a token identifying the interface within {@code program} to query. One of:
* @param params a variable to retrieve the value of {@code pname} for the program interface
*/
public static void glGetProgramInterfaceiv(int program, int programInterface, int pname, IntBuffer params) {
if (CHECKS) {
check(params, 1);
}
nglGetProgramInterfaceiv(program, programInterface, pname, memAddress(params));
}
/**
*
*
* Queries a property of an interface in a program.
*
* @param program the name of a program object whose interface to query
* @param programInterface a token identifying the interface within {@code program} to query. One of:
*
* Queries the index of a named resource within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the resource named {Wcode name}. One of:
* @param name the name of the resource to query the index of
*/
public static int glGetProgramResourceIndex(int program, int programInterface, ByteBuffer name) {
if (CHECKS) {
checkNT1(name);
}
return nglGetProgramResourceIndex(program, programInterface, memAddress(name));
}
/**
*
*
* Queries the index of a named resource within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the resource named {Wcode name}. One of:
* @param name the name of the resource to query the index of
*/
public static int glGetProgramResourceIndex(int program, int programInterface, CharSequence name) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
ByteBuffer nameEncoded = stack.UTF8(name);
return nglGetProgramResourceIndex(program, programInterface, memAddress(nameEncoded));
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glGetProgramResourceName ] ---
/**
* Unsafe version of: {@link #glGetProgramResourceName GetProgramResourceName}
*
* @param bufSize the size of the character array whose address is given by {@code name}
*/
public static native void nglGetProgramResourceName(int program, int programInterface, int index, int bufSize, long length, long name);
/**
*
*
* Queries the name of an indexed resource within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the indexed resource. One of:
* @param index the index of the resource within {@code programInterface} of {@code program}
* @param length a variable which will receive the length of the resource name
* @param name a character array into which will be written the name of the resource
*/
public static void glGetProgramResourceName(int program, int programInterface, int index, IntBuffer length, ByteBuffer name) {
if (CHECKS) {
checkSafe(length, 1);
}
nglGetProgramResourceName(program, programInterface, index, name.remaining(), memAddressSafe(length), memAddress(name));
}
/**
*
*
* Queries the name of an indexed resource within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the indexed resource. One of:
* @param index the index of the resource within {@code programInterface} of {@code program}
* @param bufSize the size of the character array whose address is given by {@code name}
*/
public static String glGetProgramResourceName(int program, int programInterface, int index, int bufSize) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
IntBuffer length = stack.ints(0);
ByteBuffer name = stack.malloc(bufSize);
nglGetProgramResourceName(program, programInterface, index, bufSize, memAddress(length), memAddress(name));
return memASCII(name, length.get(0));
} finally {
stack.setPointer(stackPointer);
}
}
/**
*
*
* Queries the name of an indexed resource within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the indexed resource. One of:
* @param index the index of the resource within {@code programInterface} of {@code program}
*/
public static String glGetProgramResourceName(int program, int programInterface, int index) {
return glGetProgramResourceName(program, programInterface, index, glGetProgramInterfacei(program, programInterface, GL_MAX_NAME_LENGTH));
}
// --- [ glGetProgramResourceiv ] ---
/**
* Unsafe version of: {@link #glGetProgramResourceiv GetProgramResourceiv}
*
* @param propCount the number of properties in {@code props}
* @param bufSize the size of the integer array whose address is given by {@code params}
*/
public static native void nglGetProgramResourceiv(int program, int programInterface, int index, int propCount, long props, int bufSize, long length, long params);
/**
*
*
* Retrieves values for multiple properties of a single active resource within a program object.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the resource named {@code name}. One of:
* @param index the active resource index
* @param props an array that will receive the active resource properties
* @param length a variable which will receive the number of values returned
* @param params an array that will receive the property values
*/
public static void glGetProgramResourceiv(int program, int programInterface, int index, IntBuffer props, IntBuffer length, IntBuffer params) {
if (CHECKS) {
checkSafe(length, 1);
}
nglGetProgramResourceiv(program, programInterface, index, props.remaining(), memAddress(props), params.remaining(), memAddressSafe(length), memAddress(params));
}
// --- [ glGetProgramResourceLocation ] ---
/** Unsafe version of: {@link #glGetProgramResourceLocation GetProgramResourceLocation} */
public static native int nglGetProgramResourceLocation(int program, int programInterface, long name);
/**
*
*
* Queries the location of a named resource within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the resource named {@code name}
* @param name the name of the resource to query the location of
*/
public static int glGetProgramResourceLocation(int program, int programInterface, ByteBuffer name) {
if (CHECKS) {
checkNT1(name);
}
return nglGetProgramResourceLocation(program, programInterface, memAddress(name));
}
/**
*
*
* Queries the location of a named resource within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the resource named {@code name}
* @param name the name of the resource to query the location of
*/
public static int glGetProgramResourceLocation(int program, int programInterface, CharSequence name) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
ByteBuffer nameEncoded = stack.ASCII(name);
return nglGetProgramResourceLocation(program, programInterface, memAddress(nameEncoded));
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glGetProgramResourceLocationIndex ] ---
/** Unsafe version of: {@link #glGetProgramResourceLocationIndex GetProgramResourceLocationIndex} */
public static native int nglGetProgramResourceLocationIndex(int program, int programInterface, long name);
/**
*
*
* Queries the fragment color index of a named variable within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the resource named {@code name}. Must be:
{@link #GL_PROGRAM_OUTPUT PROGRAM_OUTPUT}
* @param name the name of the resource to query the location of
*/
public static int glGetProgramResourceLocationIndex(int program, int programInterface, ByteBuffer name) {
if (CHECKS) {
checkNT1(name);
}
return nglGetProgramResourceLocationIndex(program, programInterface, memAddress(name));
}
/**
*
*
* Queries the fragment color index of a named variable within a program.
*
* @param program the name of a program object whose resources to query
* @param programInterface a token identifying the interface within {@code program} containing the resource named {@code name}. Must be:
{@link #GL_PROGRAM_OUTPUT PROGRAM_OUTPUT}
* @param name the name of the resource to query the location of
*/
public static int glGetProgramResourceLocationIndex(int program, int programInterface, CharSequence name) {
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
try {
ByteBuffer nameEncoded = stack.ASCII(name);
return nglGetProgramResourceLocationIndex(program, programInterface, memAddress(nameEncoded));
} finally {
stack.setPointer(stackPointer);
}
}
// --- [ glShaderStorageBlockBinding ] ---
/**
*
*
* Changes an active shader storage block binding.
*
* @param program the name of the program containing the block whose binding to change
* @param storageBlockIndex the index storage block within the program
* @param storageBlockBinding the index storage block binding to associate with the specified storage block
*/
public static native void glShaderStorageBlockBinding(int program, int storageBlockIndex, int storageBlockBinding);
// --- [ glTexBufferRange ] ---
/**
*
*
* Binds a range of a buffer's data store to a buffer texture.
*
* @param target the target of the operation. Must be:
{@link GL31#GL_TEXTURE_BUFFER TEXTURE_BUFFER}
* @param internalformat the internal format of the data in the store belonging to {@code buffer}
* @param buffer the name of the buffer object whose storage to attach to the active buffer texture
* @param offset the offset of the start of the range of the buffer's data store to attach
* @param size the size of the range of the buffer's data store to attach
*/
public static native void glTexBufferRange(int target, int internalformat, int buffer, long offset, long size);
// --- [ glTexStorage2DMultisample ] ---
/**
*
* @param samples the number of samples in the texture
* @param internalformat the sized internal format to be used to store texture image data
* @param width the width of the texture, in texels
* @param height the height of the texture, in texels
* @param fixedsamplelocations whether the image will use identical sample locations and the same number of samples for all texels in the image, and the sample locations will not
* depend on the internal format or size of the image
*/
public static native void glTexStorage2DMultisample(int target, int samples, int internalformat, int width, int height, boolean fixedsamplelocations);
// --- [ glTexStorage3DMultisample ] ---
/**
*
* @param samples the number of samples in the texture
* @param internalformat the sized internal format to be used to store texture image data
* @param width the width of the texture, in texels
* @param height the height of the texture, in texels
* @param depth the depth of the texture, in texels
* @param fixedsamplelocations whether the image will use identical sample locations and the same number of samples for all texels in the image, and the sample locations will not
* depend on the internal format or size of the image
*/
public static native void glTexStorage3DMultisample(int target, int samples, int internalformat, int width, int height, int depth, boolean fixedsamplelocations);
// --- [ glTextureView ] ---
/**
*
*
* Initializes a texture as a data alias of another texture's data store.
*
* @param texture the texture object to be initialized as a view
* @param target the target to be used for the newly initialized texture
* @param origtexture the name of a texture object of which to make a view
* @param internalformat the internal format for the newly created view
* @param minlevel the lowest level of detail of the view
* @param numlevels the number of levels of detail to include in the view
* @param minlayer the index of the first layer to include in the view
* @param numlayers the number of layers to include in the view
*/
public static native void glTextureView(int texture, int target, int origtexture, int internalformat, int minlevel, int numlevels, int minlayer, int numlayers);
// --- [ glBindVertexBuffer ] ---
/**
*
*
* Binds a buffer to a vertex buffer bind point.
*
* @param bindingindex the index of the vertex buffer binding point to which to bind the buffer
* @param buffer the name of an existing buffer to bind to the vertex buffer binding point
* @param offset the offset of the first element of the buffer
* @param stride the distance between elements within the buffer
*/
public static native void glBindVertexBuffer(int bindingindex, int buffer, long offset, int stride);
// --- [ glVertexAttribFormat ] ---
/**
*
*
* Specifies the organization of data in vertex arrays.
*
* @param attribindex the generic vertex attribute array being described
* @param size the number of values per vertex that are stored in the array. One of:
1
2
3
4
{@link GL12#GL_BGRA BGRA}
* @param type the type of the data stored in the array
* @param normalized if true then integer data is normalized to the range [-1, 1] or [0, 1] if it is signed or unsigned, respectively. If false then integer data is
* directly converted to floating point.
* @param relativeoffset the offset, measured in basic machine units of the first element relative to the start of the vertex buffer binding this attribute fetches from
*/
public static native void glVertexAttribFormat(int attribindex, int size, int type, boolean normalized, int relativeoffset);
// --- [ glVertexAttribIFormat ] ---
/**
*
*
* Specifies the organization of pure integer data in vertex arrays.
*
* @param attribindex the generic vertex attribute array being described
* @param size the number of values per vertex that are stored in the array. One of:
1
2
3
4
{@link GL12#GL_BGRA BGRA}
* @param type the type of the data stored in the array
* @param relativeoffset the offset, measured in basic machine units of the first element relative to the start of the vertex buffer binding this attribute fetches from
*/
public static native void glVertexAttribIFormat(int attribindex, int size, int type, int relativeoffset);
// --- [ glVertexAttribLFormat ] ---
/**
*
*
* Specifies the organization of 64-bit double data in vertex arrays.
*
* @param attribindex the generic vertex attribute array being described
* @param size the number of values per vertex that are stored in the array. One of:
1
2
3
4
{@link GL12#GL_BGRA BGRA}
* @param type the type of the data stored in the array
* @param relativeoffset the offset, measured in basic machine units of the first element relative to the start of the vertex buffer binding this attribute fetches from
*/
public static native void glVertexAttribLFormat(int attribindex, int size, int type, int relativeoffset);
// --- [ glVertexAttribBinding ] ---
/**
*
*
* Associate a vertex attribute and a vertex buffer binding.
*
* @param attribindex the index of the attribute to associate with a vertex buffer binding
* @param bindingindex the index of the vertex buffer binding with which to associate the generic vertex attribute
*/
public static native void glVertexAttribBinding(int attribindex, int bindingindex);
// --- [ glVertexBindingDivisor ] ---
/**
*
*
* Modifies the rate at which generic vertex attributes advance during instanced rendering.
*
* @param bindingindex the index of the generic vertex attribute
* @param divisor the number of instances that will pass between updates of the generic attribute at slot {@code index}
*/
public static native void glVertexBindingDivisor(int bindingindex, int divisor);
/**
*
*
* Array version of: {@link #glInvalidateSubFramebuffer InvalidateSubFramebuffer}
*/
public static void glInvalidateSubFramebuffer(int target, int[] attachments, int x, int y, int width, int height) {
long __functionAddress = GL.getICD().glInvalidateSubFramebuffer;
if (CHECKS) {
check(__functionAddress);
}
callPV(__functionAddress, target, attachments.length, attachments, x, y, width, height);
}
/**
*