summaryrefslogtreecommitdiffstats
path: root/core/jni/com_google_android_gles_jni_GLImpl.cpp
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2011-04-08 20:01:01 -0700
committerElliott Hughes <enh@google.com>2011-04-11 15:31:20 -0700
commit24ce5fb2cc09d0a14406e7b935f8648c5720d27e (patch)
tree022bd63502ea1a649ecf32bdb3dc2e0205376901 /core/jni/com_google_android_gles_jni_GLImpl.cpp
parent7797e647fc8fcd5091b9449c0044f5cb70db5b47 (diff)
downloadframeworks_base-24ce5fb2cc09d0a14406e7b935f8648c5720d27e.zip
frameworks_base-24ce5fb2cc09d0a14406e7b935f8648c5720d27e.tar.gz
frameworks_base-24ce5fb2cc09d0a14406e7b935f8648c5720d27e.tar.bz2
Kill the global references in the OpenGL wrappers.
Just use jniThrowException instead. Note that it would be trivial to throw seemingly more appropriate exceptions (NullPointerException and OutOfMemoryException in particular), but I'm only attempting to preserve existing behavior here. I also found shadowing bugs in some of the special-case functions, which would previously always have leaked memory. This also moves an accidental change to a generated file (ActivityThread -> AppGlobals) into the generator, so it won't be overwritten in future. Change-Id: Iab570310b568cb406c60dd0e2b8211f8a36ae590
Diffstat (limited to 'core/jni/com_google_android_gles_jni_GLImpl.cpp')
-rw-r--r--core/jni/com_google_android_gles_jni_GLImpl.cpp558
1 files changed, 265 insertions, 293 deletions
diff --git a/core/jni/com_google_android_gles_jni_GLImpl.cpp b/core/jni/com_google_android_gles_jni_GLImpl.cpp
index bf613e1..8777131 100644
--- a/core/jni/com_google_android_gles_jni_GLImpl.cpp
+++ b/core/jni/com_google_android_gles_jni_GLImpl.cpp
@@ -2,21 +2,23 @@
**
** Copyright 2006, The Android Open Source Project
**
-** Licensed under the Apache License, Version 2.0 (the "License");
-** you may not use this file except in compliance with the License.
-** You may obtain a copy of the License at
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
**
-** http://www.apache.org/licenses/LICENSE-2.0
+** http://www.apache.org/licenses/LICENSE-2.0
**
-** Unless required by applicable law or agreed to in writing, software
-** distributed under the License is distributed on an "AS IS" BASIS,
-** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-** See the License for the specific language governing permissions and
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
** limitations under the License.
*/
// This source file is automatically generated
+#include "jni.h"
+#include "JNIHelp.h"
#include <android_runtime/AndroidRuntime.h>
#include <utils/misc.h>
@@ -64,10 +66,6 @@ static int initialized = 0;
static jclass nioAccessClass;
static jclass bufferClass;
-static jclass OOMEClass;
-static jclass UOEClass;
-static jclass IAEClass;
-static jclass AIOOBEClass;
static jclass G11ImplClass;
static jmethodID getBasePointerID;
static jmethodID getBaseArrayID;
@@ -85,7 +83,7 @@ static jfieldID have_OES_texture_cube_mapID;
/* Cache method IDs each time the class is loaded. */
static void
-nativeClassInitBuffer(JNIEnv *_env)
+nativeClassInit(JNIEnv *_env, jclass glImplClass)
{
jclass nioAccessClassLocal = _env->FindClass("java/nio/NIOAccess");
nioAccessClass = (jclass) _env->NewGlobalRef(nioAccessClassLocal);
@@ -115,26 +113,6 @@ nativeClassInitBuffer(JNIEnv *_env)
_env->GetFieldID(bufferClass, "_elementSizeShift", "I");
}
-static void
-nativeClassInit(JNIEnv *_env, jclass glImplClass)
-{
- nativeClassInitBuffer(_env);
-
- jclass IAEClassLocal =
- _env->FindClass("java/lang/IllegalArgumentException");
- jclass OOMEClassLocal =
- _env->FindClass("java/lang/OutOfMemoryError");
- jclass UOEClassLocal =
- _env->FindClass("java/lang/UnsupportedOperationException");
- jclass AIOOBEClassLocal =
- _env->FindClass("java/lang/ArrayIndexOutOfBoundsException");
-
- IAEClass = (jclass) _env->NewGlobalRef(IAEClassLocal);
- OOMEClass = (jclass) _env->NewGlobalRef(OOMEClassLocal);
- UOEClass = (jclass) _env->NewGlobalRef(UOEClassLocal);
- AIOOBEClass = (jclass) _env->NewGlobalRef(AIOOBEClassLocal);
-}
-
static void *
getPointer(JNIEnv *_env, jobject buffer, jarray *array, jint *remaining)
{
@@ -155,7 +133,7 @@ getPointer(JNIEnv *_env, jobject buffer, jarray *array, jint *remaining)
*array = NULL;
return (void *) (jint) pointer;
}
-
+
*array = (jarray) _env->CallStaticObjectMethod(nioAccessClass,
getBaseArrayID, buffer);
if (*array == NULL) {
@@ -164,7 +142,7 @@ getPointer(JNIEnv *_env, jobject buffer, jarray *array, jint *remaining)
offset = _env->CallStaticIntMethod(nioAccessClass,
getBaseArrayOffsetID, buffer);
data = _env->GetPrimitiveArrayCritical(*array, (jboolean *) 0);
-
+
return (void *) ((char *) data + offset);
}
@@ -208,7 +186,8 @@ getDirectBufferPointer(JNIEnv *_env, jobject buffer) {
releasePointer(_env, array, buf, 0);
}
} else {
- _env->ThrowNew(IAEClass, "Must use a native order direct Buffer");
+ jniThrowException(_env, "java/lang/IllegalArgumentException",
+ "Must use a native order direct Buffer");
}
}
return buf;
@@ -251,7 +230,7 @@ nextExtension(const GLubyte* pExtensions) {
}
}
}
-
+
static bool
checkForExtension(const GLubyte* pExtensions, const GLubyte* pExtension) {
for (;*pExtensions != '\0'; pExtensions = nextExtension(pExtensions)) {
@@ -280,7 +259,6 @@ supportsExtension(JNIEnv *_env, jobject impl, jfieldID fieldId) {
}
// --------------------------------------------------------------------------
-
/* void glActiveTexture ( GLenum texture ) */
static void
android_glActiveTexture__I
@@ -557,16 +535,16 @@ android_glDeleteTextures__I_3II
GLuint *textures = (GLuint *) 0;
if (!textures_ref) {
- _env->ThrowNew(IAEClass, "textures == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "textures == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(textures_ref) - offset;
if (_remaining < n) {
- _env->ThrowNew(IAEClass, "length - offset < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < n");
goto exit;
}
textures_base = (GLuint *)
@@ -595,7 +573,7 @@ android_glDeleteTextures__ILjava_nio_IntBuffer_2
textures = (GLuint *)getPointer(_env, textures_buf, &_array, &_remaining);
if (_remaining < n) {
- _env->ThrowNew(IAEClass, "remaining() < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < n");
goto exit;
}
glDeleteTextures(
@@ -686,7 +664,7 @@ android_glDrawElements__IIILjava_nio_Buffer_2
indices = (GLvoid *)getPointer(_env, indices_buf, &_array, &_remaining);
if (_remaining < count) {
- _env->ThrowNew(AIOOBEClass, "remaining() < count");
+ jniThrowException(_env, "java/lang/ArrayIndexOutOfBoundsException", "remaining() < count");
goto exit;
}
glDrawElements(
@@ -753,11 +731,11 @@ android_glFogfv__I_3FI
GLfloat *params = (GLfloat *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -787,7 +765,7 @@ android_glFogfv__I_3FI
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfloat *)
@@ -841,7 +819,7 @@ android_glFogfv__ILjava_nio_FloatBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glFogfv(
@@ -874,11 +852,11 @@ android_glFogxv__I_3II
GLfixed *params = (GLfixed *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -908,7 +886,7 @@ android_glFogxv__I_3II
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfixed *)
@@ -962,7 +940,7 @@ android_glFogxv__ILjava_nio_IntBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glFogxv(
@@ -1024,18 +1002,18 @@ android_glGenTextures__I_3II
if (!textures_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "textures == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "textures == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(textures_ref) - offset;
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < n");
goto exit;
}
textures_base = (GLuint *)
@@ -1066,7 +1044,7 @@ android_glGenTextures__ILjava_nio_IntBuffer_2
textures = (GLuint *)getPointer(_env, textures_buf, &_array, &_remaining);
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < n");
goto exit;
}
glGenTextures(
@@ -1100,12 +1078,12 @@ android_glGetIntegerv__I_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -1442,7 +1420,7 @@ android_glGetIntegerv__I_3II
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLint *)
@@ -1804,7 +1782,7 @@ android_glGetIntegerv__ILjava_nio_IntBuffer_2
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glGetIntegerv(
@@ -1818,16 +1796,10 @@ exit:
}
}
-#include <string.h>
-
/* const GLubyte * glGetString ( GLenum name ) */
-static
-jstring
-android_glGetString
- (JNIEnv *_env, jobject _this, jint name) {
- const char * chars = (const char *)glGetString((GLenum)name);
- jstring output = _env->NewStringUTF(chars);
- return output;
+static jstring android_glGetString(JNIEnv *_env, jobject, jint name) {
+ const char* chars = (const char*) glGetString((GLenum) name);
+ return _env->NewStringUTF(chars);
}
/* void glHint ( GLenum target, GLenum mode ) */
static void
@@ -1858,11 +1830,11 @@ android_glLightModelfv__I_3FI
GLfloat *params = (GLfloat *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -1883,7 +1855,7 @@ android_glLightModelfv__I_3FI
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfloat *)
@@ -1928,7 +1900,7 @@ android_glLightModelfv__ILjava_nio_FloatBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glLightModelfv(
@@ -1961,11 +1933,11 @@ android_glLightModelxv__I_3II
GLfixed *params = (GLfixed *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -1986,7 +1958,7 @@ android_glLightModelxv__I_3II
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfixed *)
@@ -2031,7 +2003,7 @@ android_glLightModelxv__ILjava_nio_IntBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glLightModelxv(
@@ -2065,11 +2037,11 @@ android_glLightfv__II_3FI
GLfloat *params = (GLfloat *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -2116,7 +2088,7 @@ android_glLightfv__II_3FI
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfloat *)
@@ -2188,7 +2160,7 @@ android_glLightfv__IILjava_nio_FloatBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glLightfv(
@@ -2223,11 +2195,11 @@ android_glLightxv__II_3II
GLfixed *params = (GLfixed *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -2274,7 +2246,7 @@ android_glLightxv__II_3II
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfixed *)
@@ -2346,7 +2318,7 @@ android_glLightxv__IILjava_nio_IntBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glLightxv(
@@ -2395,11 +2367,11 @@ android_glLoadMatrixf___3FI
GLfloat *m = (GLfloat *) 0;
if (!m_ref) {
- _env->ThrowNew(IAEClass, "m == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "m == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(m_ref) - offset;
@@ -2444,11 +2416,11 @@ android_glLoadMatrixx___3II
GLfixed *m = (GLfixed *) 0;
if (!m_ref) {
- _env->ThrowNew(IAEClass, "m == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "m == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(m_ref) - offset;
@@ -2513,11 +2485,11 @@ android_glMaterialfv__II_3FI
GLfloat *params = (GLfloat *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -2550,7 +2522,7 @@ android_glMaterialfv__II_3FI
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfloat *)
@@ -2608,7 +2580,7 @@ android_glMaterialfv__IILjava_nio_FloatBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glMaterialfv(
@@ -2643,11 +2615,11 @@ android_glMaterialxv__II_3II
GLfixed *params = (GLfixed *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -2680,7 +2652,7 @@ android_glMaterialxv__II_3II
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfixed *)
@@ -2738,7 +2710,7 @@ android_glMaterialxv__IILjava_nio_IntBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glMaterialxv(
@@ -2771,11 +2743,11 @@ android_glMultMatrixf___3FI
GLfloat *m = (GLfloat *) 0;
if (!m_ref) {
- _env->ThrowNew(IAEClass, "m == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "m == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(m_ref) - offset;
@@ -2820,11 +2792,11 @@ android_glMultMatrixx___3II
GLfixed *m = (GLfixed *) 0;
if (!m_ref) {
- _env->ThrowNew(IAEClass, "m == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "m == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(m_ref) - offset;
@@ -3205,11 +3177,11 @@ android_glTexEnvfv__II_3FI
GLfloat *params = (GLfloat *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -3236,7 +3208,7 @@ android_glTexEnvfv__II_3FI
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfloat *)
@@ -3288,7 +3260,7 @@ android_glTexEnvfv__IILjava_nio_FloatBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glTexEnvfv(
@@ -3323,11 +3295,11 @@ android_glTexEnvxv__II_3II
GLfixed *params = (GLfixed *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -3354,7 +3326,7 @@ android_glTexEnvxv__II_3II
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfixed *)
@@ -3406,7 +3378,7 @@ android_glTexEnvxv__IILjava_nio_IntBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glTexEnvxv(
@@ -3569,18 +3541,18 @@ android_glQueryMatrixxOES___3II_3II
if (!mantissa_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "mantissa == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "mantissa == null");
goto exit;
}
if (mantissaOffset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "mantissaOffset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "mantissaOffset < 0");
goto exit;
}
_mantissaRemaining = _env->GetArrayLength(mantissa_ref) - mantissaOffset;
if (_mantissaRemaining < 16) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - mantissaOffset < 16");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - mantissaOffset < 16");
goto exit;
}
mantissa_base = (GLfixed *)
@@ -3589,18 +3561,18 @@ android_glQueryMatrixxOES___3II_3II
if (!exponent_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "exponent == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "exponent == null");
goto exit;
}
if (exponentOffset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "exponentOffset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "exponentOffset < 0");
goto exit;
}
_exponentRemaining = _env->GetArrayLength(exponent_ref) - exponentOffset;
if (_exponentRemaining < 16) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - exponentOffset < 16");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - exponentOffset < 16");
goto exit;
}
exponent_base = (GLint *)
@@ -3640,13 +3612,13 @@ android_glQueryMatrixxOES__Ljava_nio_IntBuffer_2Ljava_nio_IntBuffer_2
mantissa = (GLfixed *)getPointer(_env, mantissa_buf, &_mantissaArray, &_mantissaRemaining);
if (_mantissaRemaining < 16) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < 16");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 16");
goto exit;
}
exponent = (GLint *)getPointer(_env, exponent_buf, &_exponentArray, &_exponentRemaining);
if (_exponentRemaining < 16) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < 16");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 16");
goto exit;
}
_returnValue = glQueryMatrixxOES(
@@ -3685,7 +3657,7 @@ android_glBufferData__IILjava_nio_Buffer_2I
if (data_buf) {
data = (GLvoid *)getPointer(_env, data_buf, &_array, &_remaining);
if (_remaining < size) {
- _env->ThrowNew(IAEClass, "remaining() < size");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < size");
goto exit;
}
}
@@ -3712,7 +3684,7 @@ android_glBufferSubData__IIILjava_nio_Buffer_2
data = (GLvoid *)getPointer(_env, data_buf, &_array, &_remaining);
if (_remaining < size) {
- _env->ThrowNew(IAEClass, "remaining() < size");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < size");
goto exit;
}
glBufferSubData(
@@ -3737,16 +3709,16 @@ android_glClipPlanef__I_3FI
GLfloat *equation = (GLfloat *) 0;
if (!equation_ref) {
- _env->ThrowNew(IAEClass, "equation == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "equation == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(equation_ref) - offset;
if (_remaining < 4) {
- _env->ThrowNew(IAEClass, "length - offset < 4");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 4");
goto exit;
}
equation_base = (GLfloat *)
@@ -3775,7 +3747,7 @@ android_glClipPlanef__ILjava_nio_FloatBuffer_2
equation = (GLfloat *)getPointer(_env, equation_buf, &_array, &_remaining);
if (_remaining < 4) {
- _env->ThrowNew(IAEClass, "remaining() < 4");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 4");
goto exit;
}
glClipPlanef(
@@ -3798,16 +3770,16 @@ android_glClipPlanex__I_3II
GLfixed *equation = (GLfixed *) 0;
if (!equation_ref) {
- _env->ThrowNew(IAEClass, "equation == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "equation == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(equation_ref) - offset;
if (_remaining < 4) {
- _env->ThrowNew(IAEClass, "length - offset < 4");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 4");
goto exit;
}
equation_base = (GLfixed *)
@@ -3836,7 +3808,7 @@ android_glClipPlanex__ILjava_nio_IntBuffer_2
equation = (GLfixed *)getPointer(_env, equation_buf, &_array, &_remaining);
if (_remaining < 4) {
- _env->ThrowNew(IAEClass, "remaining() < 4");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 4");
goto exit;
}
glClipPlanex(
@@ -3883,16 +3855,16 @@ android_glDeleteBuffers__I_3II
GLuint *buffers = (GLuint *) 0;
if (!buffers_ref) {
- _env->ThrowNew(IAEClass, "buffers == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "buffers == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(buffers_ref) - offset;
if (_remaining < n) {
- _env->ThrowNew(IAEClass, "length - offset < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < n");
goto exit;
}
buffers_base = (GLuint *)
@@ -3921,7 +3893,7 @@ android_glDeleteBuffers__ILjava_nio_IntBuffer_2
buffers = (GLuint *)getPointer(_env, buffers_buf, &_array, &_remaining);
if (_remaining < n) {
- _env->ThrowNew(IAEClass, "remaining() < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < n");
goto exit;
}
glDeleteBuffers(
@@ -3958,18 +3930,18 @@ android_glGenBuffers__I_3II
if (!buffers_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "buffers == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "buffers == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(buffers_ref) - offset;
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < n");
goto exit;
}
buffers_base = (GLuint *)
@@ -4000,7 +3972,7 @@ android_glGenBuffers__ILjava_nio_IntBuffer_2
buffers = (GLuint *)getPointer(_env, buffers_buf, &_array, &_remaining);
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < n");
goto exit;
}
glGenBuffers(
@@ -4025,12 +3997,12 @@ android_glGetBooleanv__I_3ZI
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -4073,7 +4045,7 @@ android_glGetBooleanv__ILjava_nio_IntBuffer_2
static void
android_glGetBufferParameteriv__II_3II
(JNIEnv *_env, jobject _this, jint target, jint pname, jintArray params_ref, jint offset) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetBufferParameteriv");
}
@@ -4081,7 +4053,7 @@ android_glGetBufferParameteriv__II_3II
static void
android_glGetBufferParameteriv__IILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint target, jint pname, jobject params_buf) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetBufferParameteriv");
}
@@ -4096,12 +4068,12 @@ android_glGetClipPlanef__I_3FI
if (!eqn_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "eqn == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "eqn == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(eqn_ref) - offset;
@@ -4151,12 +4123,12 @@ android_glGetClipPlanex__I_3II
if (!eqn_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "eqn == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "eqn == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(eqn_ref) - offset;
@@ -4206,12 +4178,12 @@ android_glGetFixedv__I_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -4261,12 +4233,12 @@ android_glGetFloatv__I_3FI
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -4316,12 +4288,12 @@ android_glGetLightfv__II_3FI
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -4369,7 +4341,7 @@ android_glGetLightfv__II_3FI
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfloat *)
@@ -4443,7 +4415,7 @@ android_glGetLightfv__IILjava_nio_FloatBuffer_2
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glGetLightfv(
@@ -4469,12 +4441,12 @@ android_glGetLightxv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -4522,7 +4494,7 @@ android_glGetLightxv__II_3II
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfixed *)
@@ -4596,7 +4568,7 @@ android_glGetLightxv__IILjava_nio_IntBuffer_2
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glGetLightxv(
@@ -4622,12 +4594,12 @@ android_glGetMaterialfv__II_3FI
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -4661,7 +4633,7 @@ android_glGetMaterialfv__II_3FI
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfloat *)
@@ -4721,7 +4693,7 @@ android_glGetMaterialfv__IILjava_nio_FloatBuffer_2
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glGetMaterialfv(
@@ -4747,12 +4719,12 @@ android_glGetMaterialxv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -4786,7 +4758,7 @@ android_glGetMaterialxv__II_3II
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfixed *)
@@ -4846,7 +4818,7 @@ android_glGetMaterialxv__IILjava_nio_IntBuffer_2
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glGetMaterialxv(
@@ -4872,12 +4844,12 @@ android_glGetTexEnviv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -4905,7 +4877,7 @@ android_glGetTexEnviv__II_3II
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLint *)
@@ -4959,7 +4931,7 @@ android_glGetTexEnviv__IILjava_nio_IntBuffer_2
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glGetTexEnviv(
@@ -4985,12 +4957,12 @@ android_glGetTexEnvxv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -5018,7 +4990,7 @@ android_glGetTexEnvxv__II_3II
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLfixed *)
@@ -5072,7 +5044,7 @@ android_glGetTexEnvxv__IILjava_nio_IntBuffer_2
}
if (_remaining < _needed) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glGetTexEnvxv(
@@ -5098,18 +5070,18 @@ android_glGetTexParameterfv__II_3FI
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
if (_remaining < 1) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 1");
goto exit;
}
params_base = (GLfloat *)
@@ -5141,7 +5113,7 @@ android_glGetTexParameterfv__IILjava_nio_FloatBuffer_2
params = (GLfloat *)getPointer(_env, params_buf, &_array, &_remaining);
if (_remaining < 1) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 1");
goto exit;
}
glGetTexParameterfv(
@@ -5167,18 +5139,18 @@ android_glGetTexParameteriv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
if (_remaining < 1) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 1");
goto exit;
}
params_base = (GLint *)
@@ -5210,7 +5182,7 @@ android_glGetTexParameteriv__IILjava_nio_IntBuffer_2
params = (GLint *)getPointer(_env, params_buf, &_array, &_remaining);
if (_remaining < 1) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 1");
goto exit;
}
glGetTexParameteriv(
@@ -5236,18 +5208,18 @@ android_glGetTexParameterxv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
if (_remaining < 1) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 1");
goto exit;
}
params_base = (GLfixed *)
@@ -5279,7 +5251,7 @@ android_glGetTexParameterxv__IILjava_nio_IntBuffer_2
params = (GLfixed *)getPointer(_env, params_buf, &_array, &_remaining);
if (_remaining < 1) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 1");
goto exit;
}
glGetTexParameterxv(
@@ -5357,16 +5329,16 @@ android_glPointParameterfv__I_3FI
GLfloat *params = (GLfloat *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "length - offset < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 1");
goto exit;
}
params_base = (GLfloat *)
@@ -5395,7 +5367,7 @@ android_glPointParameterfv__ILjava_nio_FloatBuffer_2
params = (GLfloat *)getPointer(_env, params_buf, &_array, &_remaining);
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "remaining() < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 1");
goto exit;
}
glPointParameterfv(
@@ -5428,16 +5400,16 @@ android_glPointParameterxv__I_3II
GLfixed *params = (GLfixed *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "length - offset < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 1");
goto exit;
}
params_base = (GLfixed *)
@@ -5466,7 +5438,7 @@ android_glPointParameterxv__ILjava_nio_IntBuffer_2
params = (GLfixed *)getPointer(_env, params_buf, &_array, &_remaining);
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "remaining() < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 1");
goto exit;
}
glPointParameterxv(
@@ -5534,11 +5506,11 @@ android_glTexEnviv__II_3II
GLint *params = (GLint *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -5565,7 +5537,7 @@ android_glTexEnviv__II_3II
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "length - offset < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < needed");
goto exit;
}
params_base = (GLint *)
@@ -5617,7 +5589,7 @@ android_glTexEnviv__IILjava_nio_IntBuffer_2
break;
}
if (_remaining < _needed) {
- _env->ThrowNew(IAEClass, "remaining() < needed");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < needed");
goto exit;
}
glTexEnviv(
@@ -5641,16 +5613,16 @@ android_glTexParameterfv__II_3FI
GLfloat *params = (GLfloat *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "length - offset < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 1");
goto exit;
}
params_base = (GLfloat *)
@@ -5680,7 +5652,7 @@ android_glTexParameterfv__IILjava_nio_FloatBuffer_2
params = (GLfloat *)getPointer(_env, params_buf, &_array, &_remaining);
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "remaining() < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 1");
goto exit;
}
glTexParameterfv(
@@ -5715,16 +5687,16 @@ android_glTexParameteriv__II_3II
GLint *params = (GLint *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "length - offset < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 1");
goto exit;
}
params_base = (GLint *)
@@ -5754,7 +5726,7 @@ android_glTexParameteriv__IILjava_nio_IntBuffer_2
params = (GLint *)getPointer(_env, params_buf, &_array, &_remaining);
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "remaining() < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 1");
goto exit;
}
glTexParameteriv(
@@ -5778,16 +5750,16 @@ android_glTexParameterxv__II_3II
GLfixed *params = (GLfixed *) 0;
if (!params_ref) {
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "length - offset < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 1");
goto exit;
}
params_base = (GLfixed *)
@@ -5817,7 +5789,7 @@ android_glTexParameterxv__IILjava_nio_IntBuffer_2
params = (GLfixed *)getPointer(_env, params_buf, &_array, &_remaining);
if (_remaining < 1) {
- _env->ThrowNew(IAEClass, "remaining() < 1");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 1");
goto exit;
}
glTexParameterxv(
@@ -5875,16 +5847,16 @@ android_glDrawTexfvOES___3FI
GLfloat *coords = (GLfloat *) 0;
if (!coords_ref) {
- _env->ThrowNew(IAEClass, "coords == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "coords == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(coords_ref) - offset;
if (_remaining < 5) {
- _env->ThrowNew(IAEClass, "length - offset < 5");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 5");
goto exit;
}
coords_base = (GLfloat *)
@@ -5912,7 +5884,7 @@ android_glDrawTexfvOES__Ljava_nio_FloatBuffer_2
coords = (GLfloat *)getPointer(_env, coords_buf, &_array, &_remaining);
if (_remaining < 5) {
- _env->ThrowNew(IAEClass, "remaining() < 5");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 5");
goto exit;
}
glDrawTexfvOES(
@@ -5947,16 +5919,16 @@ android_glDrawTexivOES___3II
GLint *coords = (GLint *) 0;
if (!coords_ref) {
- _env->ThrowNew(IAEClass, "coords == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "coords == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(coords_ref) - offset;
if (_remaining < 5) {
- _env->ThrowNew(IAEClass, "length - offset < 5");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 5");
goto exit;
}
coords_base = (GLint *)
@@ -5984,7 +5956,7 @@ android_glDrawTexivOES__Ljava_nio_IntBuffer_2
coords = (GLint *)getPointer(_env, coords_buf, &_array, &_remaining);
if (_remaining < 5) {
- _env->ThrowNew(IAEClass, "remaining() < 5");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 5");
goto exit;
}
glDrawTexivOES(
@@ -6019,16 +5991,16 @@ android_glDrawTexsvOES___3SI
GLshort *coords = (GLshort *) 0;
if (!coords_ref) {
- _env->ThrowNew(IAEClass, "coords == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "coords == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(coords_ref) - offset;
if (_remaining < 5) {
- _env->ThrowNew(IAEClass, "length - offset < 5");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 5");
goto exit;
}
coords_base = (GLshort *)
@@ -6056,7 +6028,7 @@ android_glDrawTexsvOES__Ljava_nio_ShortBuffer_2
coords = (GLshort *)getPointer(_env, coords_buf, &_array, &_remaining);
if (_remaining < 5) {
- _env->ThrowNew(IAEClass, "remaining() < 5");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 5");
goto exit;
}
glDrawTexsvOES(
@@ -6091,16 +6063,16 @@ android_glDrawTexxvOES___3II
GLfixed *coords = (GLfixed *) 0;
if (!coords_ref) {
- _env->ThrowNew(IAEClass, "coords == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "coords == null");
goto exit;
}
if (offset < 0) {
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(coords_ref) - offset;
if (_remaining < 5) {
- _env->ThrowNew(IAEClass, "length - offset < 5");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < 5");
goto exit;
}
coords_base = (GLfixed *)
@@ -6128,7 +6100,7 @@ android_glDrawTexxvOES__Ljava_nio_IntBuffer_2
coords = (GLfixed *)getPointer(_env, coords_buf, &_array, &_remaining);
if (_remaining < 5) {
- _env->ThrowNew(IAEClass, "remaining() < 5");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < 5");
goto exit;
}
glDrawTexxvOES(
@@ -6223,7 +6195,7 @@ static void
android_glBindFramebufferOES__II
(JNIEnv *_env, jobject _this, jint target, jint framebuffer) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glBindFramebufferOES");
return;
}
@@ -6238,7 +6210,7 @@ static void
android_glBindRenderbufferOES__II
(JNIEnv *_env, jobject _this, jint target, jint renderbuffer) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glBindRenderbufferOES");
return;
}
@@ -6253,7 +6225,7 @@ static void
android_glBlendEquation__I
(JNIEnv *_env, jobject _this, jint mode) {
if (! supportsExtension(_env, _this, have_OES_blend_subtractID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glBlendEquation");
return;
}
@@ -6267,7 +6239,7 @@ static void
android_glBlendEquationSeparate__II
(JNIEnv *_env, jobject _this, jint modeRGB, jint modeAlpha) {
if (! supportsExtension(_env, _this, have_OES_blend_equation_separateID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glBlendEquationSeparate");
return;
}
@@ -6282,7 +6254,7 @@ static void
android_glBlendFuncSeparate__IIII
(JNIEnv *_env, jobject _this, jint srcRGB, jint dstRGB, jint srcAlpha, jint dstAlpha) {
if (! supportsExtension(_env, _this, have_OES_blend_equation_separateID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glBlendFuncSeparate");
return;
}
@@ -6299,7 +6271,7 @@ static jint
android_glCheckFramebufferStatusOES__I
(JNIEnv *_env, jobject _this, jint target) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glCheckFramebufferStatusOES");
return 0;
}
@@ -6315,7 +6287,7 @@ static void
android_glDeleteFramebuffersOES__I_3II
(JNIEnv *_env, jobject _this, jint n, jintArray framebuffers_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glDeleteFramebuffersOES");
return;
}
@@ -6326,18 +6298,18 @@ android_glDeleteFramebuffersOES__I_3II
if (!framebuffers_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "framebuffers == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "framebuffers == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(framebuffers_ref) - offset;
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < n");
goto exit;
}
framebuffers_base = (GLuint *)
@@ -6361,7 +6333,7 @@ static void
android_glDeleteFramebuffersOES__ILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint n, jobject framebuffers_buf) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glDeleteFramebuffersOES");
return;
}
@@ -6373,7 +6345,7 @@ android_glDeleteFramebuffersOES__ILjava_nio_IntBuffer_2
framebuffers = (GLuint *)getPointer(_env, framebuffers_buf, &_array, &_remaining);
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < n");
goto exit;
}
glDeleteFramebuffersOES(
@@ -6392,7 +6364,7 @@ static void
android_glDeleteRenderbuffersOES__I_3II
(JNIEnv *_env, jobject _this, jint n, jintArray renderbuffers_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glDeleteRenderbuffersOES");
return;
}
@@ -6403,18 +6375,18 @@ android_glDeleteRenderbuffersOES__I_3II
if (!renderbuffers_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "renderbuffers == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "renderbuffers == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(renderbuffers_ref) - offset;
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < n");
goto exit;
}
renderbuffers_base = (GLuint *)
@@ -6438,7 +6410,7 @@ static void
android_glDeleteRenderbuffersOES__ILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint n, jobject renderbuffers_buf) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glDeleteRenderbuffersOES");
return;
}
@@ -6450,7 +6422,7 @@ android_glDeleteRenderbuffersOES__ILjava_nio_IntBuffer_2
renderbuffers = (GLuint *)getPointer(_env, renderbuffers_buf, &_array, &_remaining);
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < n");
goto exit;
}
glDeleteRenderbuffersOES(
@@ -6469,7 +6441,7 @@ static void
android_glFramebufferRenderbufferOES__IIII
(JNIEnv *_env, jobject _this, jint target, jint attachment, jint renderbuffertarget, jint renderbuffer) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glFramebufferRenderbufferOES");
return;
}
@@ -6486,7 +6458,7 @@ static void
android_glFramebufferTexture2DOES__IIIII
(JNIEnv *_env, jobject _this, jint target, jint attachment, jint textarget, jint texture, jint level) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glFramebufferTexture2DOES");
return;
}
@@ -6504,7 +6476,7 @@ static void
android_glGenerateMipmapOES__I
(JNIEnv *_env, jobject _this, jint target) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGenerateMipmapOES");
return;
}
@@ -6518,7 +6490,7 @@ static void
android_glGenFramebuffersOES__I_3II
(JNIEnv *_env, jobject _this, jint n, jintArray framebuffers_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGenFramebuffersOES");
return;
}
@@ -6529,18 +6501,18 @@ android_glGenFramebuffersOES__I_3II
if (!framebuffers_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "framebuffers == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "framebuffers == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(framebuffers_ref) - offset;
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < n");
goto exit;
}
framebuffers_base = (GLuint *)
@@ -6564,7 +6536,7 @@ static void
android_glGenFramebuffersOES__ILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint n, jobject framebuffers_buf) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGenFramebuffersOES");
return;
}
@@ -6576,7 +6548,7 @@ android_glGenFramebuffersOES__ILjava_nio_IntBuffer_2
framebuffers = (GLuint *)getPointer(_env, framebuffers_buf, &_array, &_remaining);
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < n");
goto exit;
}
glGenFramebuffersOES(
@@ -6595,7 +6567,7 @@ static void
android_glGenRenderbuffersOES__I_3II
(JNIEnv *_env, jobject _this, jint n, jintArray renderbuffers_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGenRenderbuffersOES");
return;
}
@@ -6606,18 +6578,18 @@ android_glGenRenderbuffersOES__I_3II
if (!renderbuffers_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "renderbuffers == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "renderbuffers == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(renderbuffers_ref) - offset;
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "length - offset < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "length - offset < n");
goto exit;
}
renderbuffers_base = (GLuint *)
@@ -6641,7 +6613,7 @@ static void
android_glGenRenderbuffersOES__ILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint n, jobject renderbuffers_buf) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGenRenderbuffersOES");
return;
}
@@ -6653,7 +6625,7 @@ android_glGenRenderbuffersOES__ILjava_nio_IntBuffer_2
renderbuffers = (GLuint *)getPointer(_env, renderbuffers_buf, &_array, &_remaining);
if (_remaining < n) {
_exception = 1;
- _env->ThrowNew(IAEClass, "remaining() < n");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "remaining() < n");
goto exit;
}
glGenRenderbuffersOES(
@@ -6672,7 +6644,7 @@ static void
android_glGetFramebufferAttachmentParameterivOES__III_3II
(JNIEnv *_env, jobject _this, jint target, jint attachment, jint pname, jintArray params_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetFramebufferAttachmentParameterivOES");
return;
}
@@ -6683,12 +6655,12 @@ android_glGetFramebufferAttachmentParameterivOES__III_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -6715,7 +6687,7 @@ static void
android_glGetFramebufferAttachmentParameterivOES__IIILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint target, jint attachment, jint pname, jobject params_buf) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetFramebufferAttachmentParameterivOES");
return;
}
@@ -6741,7 +6713,7 @@ static void
android_glGetRenderbufferParameterivOES__II_3II
(JNIEnv *_env, jobject _this, jint target, jint pname, jintArray params_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetRenderbufferParameterivOES");
return;
}
@@ -6752,12 +6724,12 @@ android_glGetRenderbufferParameterivOES__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -6783,7 +6755,7 @@ static void
android_glGetRenderbufferParameterivOES__IILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint target, jint pname, jobject params_buf) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetRenderbufferParameterivOES");
return;
}
@@ -6808,7 +6780,7 @@ static void
android_glGetTexGenfv__II_3FI
(JNIEnv *_env, jobject _this, jint coord, jint pname, jfloatArray params_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetTexGenfv");
return;
}
@@ -6819,12 +6791,12 @@ android_glGetTexGenfv__II_3FI
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -6850,7 +6822,7 @@ static void
android_glGetTexGenfv__IILjava_nio_FloatBuffer_2
(JNIEnv *_env, jobject _this, jint coord, jint pname, jobject params_buf) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetTexGenfv");
return;
}
@@ -6875,7 +6847,7 @@ static void
android_glGetTexGeniv__II_3II
(JNIEnv *_env, jobject _this, jint coord, jint pname, jintArray params_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetTexGeniv");
return;
}
@@ -6886,12 +6858,12 @@ android_glGetTexGeniv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -6917,7 +6889,7 @@ static void
android_glGetTexGeniv__IILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint coord, jint pname, jobject params_buf) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetTexGeniv");
return;
}
@@ -6942,7 +6914,7 @@ static void
android_glGetTexGenxv__II_3II
(JNIEnv *_env, jobject _this, jint coord, jint pname, jintArray params_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetTexGenxv");
return;
}
@@ -6953,12 +6925,12 @@ android_glGetTexGenxv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -6984,7 +6956,7 @@ static void
android_glGetTexGenxv__IILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint coord, jint pname, jobject params_buf) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glGetTexGenxv");
return;
}
@@ -7009,7 +6981,7 @@ static jboolean
android_glIsFramebufferOES__I
(JNIEnv *_env, jobject _this, jint framebuffer) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glIsFramebufferOES");
return JNI_FALSE;
}
@@ -7025,7 +6997,7 @@ static jboolean
android_glIsRenderbufferOES__I
(JNIEnv *_env, jobject _this, jint renderbuffer) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glIsRenderbufferOES");
return JNI_FALSE;
}
@@ -7041,7 +7013,7 @@ static void
android_glRenderbufferStorageOES__IIII
(JNIEnv *_env, jobject _this, jint target, jint internalformat, jint width, jint height) {
if (! supportsExtension(_env, _this, have_OES_framebuffer_objectID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glRenderbufferStorageOES");
return;
}
@@ -7058,7 +7030,7 @@ static void
android_glTexGenf__IIF
(JNIEnv *_env, jobject _this, jint coord, jint pname, jfloat param) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGenf");
return;
}
@@ -7074,7 +7046,7 @@ static void
android_glTexGenfv__II_3FI
(JNIEnv *_env, jobject _this, jint coord, jint pname, jfloatArray params_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGenfv");
return;
}
@@ -7085,12 +7057,12 @@ android_glTexGenfv__II_3FI
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -7116,7 +7088,7 @@ static void
android_glTexGenfv__IILjava_nio_FloatBuffer_2
(JNIEnv *_env, jobject _this, jint coord, jint pname, jobject params_buf) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGenfv");
return;
}
@@ -7141,7 +7113,7 @@ static void
android_glTexGeni__III
(JNIEnv *_env, jobject _this, jint coord, jint pname, jint param) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGeni");
return;
}
@@ -7157,7 +7129,7 @@ static void
android_glTexGeniv__II_3II
(JNIEnv *_env, jobject _this, jint coord, jint pname, jintArray params_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGeniv");
return;
}
@@ -7168,12 +7140,12 @@ android_glTexGeniv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -7199,7 +7171,7 @@ static void
android_glTexGeniv__IILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint coord, jint pname, jobject params_buf) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGeniv");
return;
}
@@ -7224,7 +7196,7 @@ static void
android_glTexGenx__III
(JNIEnv *_env, jobject _this, jint coord, jint pname, jint param) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGenx");
return;
}
@@ -7240,7 +7212,7 @@ static void
android_glTexGenxv__II_3II
(JNIEnv *_env, jobject _this, jint coord, jint pname, jintArray params_ref, jint offset) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGenxv");
return;
}
@@ -7251,12 +7223,12 @@ android_glTexGenxv__II_3II
if (!params_ref) {
_exception = 1;
- _env->ThrowNew(IAEClass, "params == null");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "params == null");
goto exit;
}
if (offset < 0) {
_exception = 1;
- _env->ThrowNew(IAEClass, "offset < 0");
+ jniThrowException(_env, "java/lang/IllegalArgumentException", "offset < 0");
goto exit;
}
_remaining = _env->GetArrayLength(params_ref) - offset;
@@ -7282,7 +7254,7 @@ static void
android_glTexGenxv__IILjava_nio_IntBuffer_2
(JNIEnv *_env, jobject _this, jint coord, jint pname, jobject params_buf) {
if (! supportsExtension(_env, _this, have_OES_texture_cube_mapID)) {
- _env->ThrowNew(UOEClass,
+ jniThrowException(_env, "java/lang/UnsupportedOperationException",
"glTexGenxv");
return;
}