Top Description Fields Constructors Methods
org.lwjgl.opengl

public Class ARBShaderAtomicCounters

extends Object
Class Inheritance
Imports
java.nio.*, org.lwjgl.system.*

Native bindings to the ARB_shader_atomic_counters extension.

This extension provides a set of atomic counters.

This extension provides GLSL built-in functions to query and increment/decrement these atomic counters.

This enables a shader to write to unique offsets (append to a buffer object) or read from unique offsets (consume from a buffer object).

Opaque handles to atomic counters are declared at global scope and are qualified with the uniform qualifier.

Unlike other user-defined uniforms declared at global scope, they take NO storage from the default partition, they have NO location, and they may NOT be set with the Uniform* commands. Atomic counters may also NOT be grouped into uniform blocks.

Active atomic counters can be discovered by the commands GetUniformIndices, GetActiveUniformName, GetActiveUniform and GetActiveUniformsiv.

Like samplers, the opaque handles of the atomic counters and are ONLY used in some GLSL built-in functions.

The atomic counters pointed to by the opaque handles are bound to buffer binding points and buffer offsets through the layout qualifiers in the shading language, or they are implicitly assigned by the compiler.

Through the OpenGL API, buffer objects may be bound to these binding points with BindBufferBase or BindBufferRange.

The contents of the atomic counters are stored in the buffer objects. The contents of atomic counters may be set and queried with buffer object manipulation functions (e.g. BufferData, BufferSubData, MapBuffer or MapBufferRange).

Requires OpenGL 3.0. Promoted to core in OpenGL 4.2.

Field Summary

Modifier and TypeField and Description
public static final int
GL_ACTIVE_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetProgramiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER

Accepted by the target parameter of BindBufferBase and BindBufferRange.

public static final int
GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_BINDING

Accepted by the pname parameter of GetBooleani_v, GetIntegeri_v, GetFloati_v, GetDoublei_v, GetInteger64i_v, GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, GetDoublev, and GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_DATA_SIZE

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

public static final int
GL_ATOMIC_COUNTER_BUFFER_SIZE

Accepted by the pname parameter of GetIntegeri_64v.

public static final int
GL_ATOMIC_COUNTER_BUFFER_START

Accepted by the pname parameter of GetIntegeri_64v.

public static final int
GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_COMBINED_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_FRAGMENT_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_GEOMETRY_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_MAX_VERTEX_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

public static final int
GL_UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX

Accepted by the pname parameter of GetActiveUniformsiv.

public static final int
GL_UNSIGNED_INT_ATOMIC_COUNTER

Returned in params by GetActiveUniform and GetActiveUniformsiv.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public static int
public static void
glGetActiveAtomicCounterBufferiv(int
the name of a program object for which the command LinkProgram has been issued in the past
program
,
int
the index of an active atomic counter buffer
bufferIndex
,
int pname, IntBuffer
a buffer in which to place the returned value
params
)

Obtains information about the set of active atomic counter buffers for a program.

public static void
glGetActiveAtomicCounterBufferiv(int program, int bufferIndex, int pname, int[] params)

Array version of: GetActiveAtomicCounterBufferiv

public static void
nglGetActiveAtomicCounterBufferiv(int program, int bufferIndex, int pname, long params)

Unsafe version of: GetActiveAtomicCounterBufferiv

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

GL_ACTIVE_ATOMIC_COUNTER_BUFFERSback to summary
public static final int GL_ACTIVE_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetProgramiv.

GL_ATOMIC_COUNTER_BUFFERback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER

Accepted by the target parameter of BindBufferBase and BindBufferRange.

GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICESback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERSback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_BINDINGback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_BINDING

Accepted by the pname parameter of GetBooleani_v, GetIntegeri_v, GetFloati_v, GetDoublei_v, GetInteger64i_v, GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, GetDoublev, and GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_DATA_SIZEback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_DATA_SIZE

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADERback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADERback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADERback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADERback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADERback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER

Accepted by the pname parameter of GetActiveAtomicCounterBufferiv.

GL_ATOMIC_COUNTER_BUFFER_SIZEback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_SIZE

Accepted by the pname parameter of GetIntegeri_64v.

GL_ATOMIC_COUNTER_BUFFER_STARTback to summary
public static final int GL_ATOMIC_COUNTER_BUFFER_START

Accepted by the pname parameter of GetIntegeri_64v.

GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGSback to summary
public static final int GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_ATOMIC_COUNTER_BUFFER_SIZEback to summary
public static final int GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERSback to summary
public static final int GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_COMBINED_ATOMIC_COUNTERSback to summary
public static final int GL_MAX_COMBINED_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERSback to summary
public static final int GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_FRAGMENT_ATOMIC_COUNTERSback to summary
public static final int GL_MAX_FRAGMENT_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERSback to summary
public static final int GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_GEOMETRY_ATOMIC_COUNTERSback to summary
public static final int GL_MAX_GEOMETRY_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERSback to summary
public static final int GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_TESS_CONTROL_ATOMIC_COUNTERSback to summary
public static final int GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERSback to summary
public static final int GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERSback to summary
public static final int GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERSback to summary
public static final int GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_MAX_VERTEX_ATOMIC_COUNTERSback to summary
public static final int GL_MAX_VERTEX_ATOMIC_COUNTERS

Accepted by the pname parameter of GetBooleanv, GetIntegerv, GetInteger64v, GetFloatv, and GetDoublev.

GL_UNIFORM_ATOMIC_COUNTER_BUFFER_INDEXback to summary
public static final int GL_UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX

Accepted by the pname parameter of GetActiveUniformsiv.

GL_UNSIGNED_INT_ATOMIC_COUNTERback to summary
public static final int GL_UNSIGNED_INT_ATOMIC_COUNTER

Returned in params by GetActiveUniform and GetActiveUniformsiv.

Constructor Detail

ARBShaderAtomicCountersback to summary
protected ARBShaderAtomicCounters()

Method Detail

glGetActiveAtomicCounterBufferiback to summary
public static int glGetActiveAtomicCounterBufferi(int program, int bufferIndex, int pname)

Obtains information about the set of active atomic counter buffers for a program.

Parameters
program:int

the name of a program object for which the command LinkProgram has been issued in the past

bufferIndex:int

the index of an active atomic counter buffer

pname:int

the parameter to query. One of:

ATOMIC_COUNTER_BUFFER_DATA_SIZE
ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS
ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER
Annotations
@NativeType:void
glGetActiveAtomicCounterBufferivback to summary
public static void glGetActiveAtomicCounterBufferiv(int program, int bufferIndex, int pname, IntBuffer params)

Obtains information about the set of active atomic counter buffers for a program.

Parameters
program:int

the name of a program object for which the command LinkProgram has been issued in the past

bufferIndex:int

the index of an active atomic counter buffer

pname:int

the parameter to query. One of:

ATOMIC_COUNTER_BUFFER_DATA_SIZE
ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS
ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER
ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER
params:IntBuffer

a buffer in which to place the returned value

glGetActiveAtomicCounterBufferivback to summary
public static void glGetActiveAtomicCounterBufferiv(int program, int bufferIndex, int pname, int[] params)

Array version of: GetActiveAtomicCounterBufferiv

nglGetActiveAtomicCounterBufferivback to summary
public static void nglGetActiveAtomicCounterBufferiv(int program, int bufferIndex, int pname, long params)

Unsafe version of: GetActiveAtomicCounterBufferiv