/** Single uniformName version of: {@link #glGetUniformIndices GetUniformIndices} */
 public static int glGetUniformIndices(int program, CharSequence uniformName) {
   APIBuffer __buffer = apiBuffer();
   ByteBuffer uniformNameBuffers = memEncodeASCII(uniformName, true);
   int uniformNamesAddress = __buffer.pointerParam(memAddress(uniformNameBuffers));
   int uniformIndices = __buffer.intParam();
   nglGetUniformIndices(
       program, 1, __buffer.address(uniformNamesAddress), __buffer.address(uniformIndices));
   return __buffer.intValue(uniformIndices);
 }
 /** Array version of: {@link #glGetUniformIndices GetUniformIndices} */
 public static void glGetUniformIndices(
     int program, CharSequence[] uniformNames, IntBuffer uniformIndices) {
   if (LWJGLUtil.CHECKS) checkBuffer(uniformIndices, uniformNames.length);
   APIBuffer __buffer = apiBuffer();
   int uniformNamesAddress = __buffer.bufferParam(uniformNames.length << POINTER_SHIFT);
   ByteBuffer[] uniformNamesBuffers = new ByteBuffer[uniformNames.length];
   for (int i = 0; i < uniformNames.length; i++)
     __buffer.pointerParam(
         uniformNamesAddress,
         i,
         memAddress(uniformNamesBuffers[i] = memEncodeASCII(uniformNames[i], true)));
   nglGetUniformIndices(
       program,
       uniformNames.length,
       __buffer.address(uniformNamesAddress),
       memAddress(uniformIndices));
 }
Example #3
0
 /** Single return value version of: {@link #glGetBufferPointerv GetBufferPointerv} */
 public static long glGetBufferPointer(int target, int pname) {
   APIBuffer __buffer = apiBuffer();
   int params = __buffer.pointerParam();
   nglGetBufferPointerv(target, pname, __buffer.address(params));
   return __buffer.pointerValue(params);
 }