summaryrefslogtreecommitdiffstats
path: root/opengl/tools/glgen/static
diff options
context:
space:
mode:
authorThomas Tafertshofer <tafertth@google.com>2012-06-15 16:22:43 -0700
committerThomas Tafertshofer <tafertth@google.com>2012-07-10 15:49:43 -0700
commit66a42db8cbfba902f72f0ace5ac448ef4bfd3951 (patch)
tree5d53f4def4f58232259a22c3629179ffe936f6e2 /opengl/tools/glgen/static
parent3443b333f16cd356d7cc7322810fe6188f58f1d9 (diff)
downloadframeworks_native-66a42db8cbfba902f72f0ace5ac448ef4bfd3951.zip
frameworks_native-66a42db8cbfba902f72f0ace5ac448ef4bfd3951.tar.gz
frameworks_native-66a42db8cbfba902f72f0ace5ac448ef4bfd3951.tar.bz2
improve glgen tool to support EGL1.4
- added EGL1.4 bindings generation - fixed bugs in GLES bindings Bug: 6709865 Change-Id: I04ac63f652e1968a51eb833f47e00336ea449980
Diffstat (limited to 'opengl/tools/glgen/static')
-rw-r--r--opengl/tools/glgen/static/egl/EGLConfig.java41
-rw-r--r--opengl/tools/glgen/static/egl/EGLContext.java41
-rw-r--r--opengl/tools/glgen/static/egl/EGLDisplay.java41
-rw-r--r--opengl/tools/glgen/static/egl/EGLObjectHandle.java33
-rw-r--r--opengl/tools/glgen/static/egl/EGLSurface.java41
5 files changed, 197 insertions, 0 deletions
diff --git a/opengl/tools/glgen/static/egl/EGLConfig.java b/opengl/tools/glgen/static/egl/EGLConfig.java
new file mode 100644
index 0000000..d9aebfc
--- /dev/null
+++ b/opengl/tools/glgen/static/egl/EGLConfig.java
@@ -0,0 +1,41 @@
+/*
+**
+** Copyright 2012, 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
+**
+** 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
+** limitations under the License.
+*/
+
+package android.opengl;
+
+/**
+ * @hide
+ */
+public class EGLConfig extends EGLObjectHandle {
+ public EGLConfig(int handle) {
+ super(handle);
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+
+ EGLConfig that = (EGLConfig) o;
+ return getHandle() == that.getHandle();
+ }
+
+ @Override
+ public int hashCode() {
+ return getHandle();
+ }
+}
diff --git a/opengl/tools/glgen/static/egl/EGLContext.java b/opengl/tools/glgen/static/egl/EGLContext.java
new file mode 100644
index 0000000..7b194f3
--- /dev/null
+++ b/opengl/tools/glgen/static/egl/EGLContext.java
@@ -0,0 +1,41 @@
+/*
+**
+** Copyright 2012, 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
+**
+** 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
+** limitations under the License.
+*/
+
+package android.opengl;
+
+/**
+ * @hide
+ */
+public class EGLContext extends EGLObjectHandle {
+ public EGLContext(int handle) {
+ super(handle);
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+
+ EGLContext that = (EGLContext) o;
+ return getHandle() == that.getHandle();
+ }
+
+ @Override
+ public int hashCode() {
+ return getHandle();
+ }
+}
diff --git a/opengl/tools/glgen/static/egl/EGLDisplay.java b/opengl/tools/glgen/static/egl/EGLDisplay.java
new file mode 100644
index 0000000..a090cf0
--- /dev/null
+++ b/opengl/tools/glgen/static/egl/EGLDisplay.java
@@ -0,0 +1,41 @@
+/*
+**
+** Copyright 2012, 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
+**
+** 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
+** limitations under the License.
+*/
+
+package android.opengl;
+
+/**
+ * @hide
+ */
+public class EGLDisplay extends EGLObjectHandle {
+ public EGLDisplay(int handle) {
+ super(handle);
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+
+ EGLDisplay that = (EGLDisplay) o;
+ return getHandle() == that.getHandle();
+ }
+
+ @Override
+ public int hashCode() {
+ return getHandle();
+ }
+}
diff --git a/opengl/tools/glgen/static/egl/EGLObjectHandle.java b/opengl/tools/glgen/static/egl/EGLObjectHandle.java
new file mode 100644
index 0000000..01f9bd4
--- /dev/null
+++ b/opengl/tools/glgen/static/egl/EGLObjectHandle.java
@@ -0,0 +1,33 @@
+/*
+**
+** Copyright 2012, 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
+**
+** 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
+** limitations under the License.
+*/
+
+package android.opengl;
+
+/**
+ * @hide
+ */
+public abstract class EGLObjectHandle {
+ private final int mHandle;
+
+ public EGLObjectHandle(int handle) {
+ mHandle = handle;
+ }
+
+ public int getHandle() {
+ return mHandle;
+ }
+}
diff --git a/opengl/tools/glgen/static/egl/EGLSurface.java b/opengl/tools/glgen/static/egl/EGLSurface.java
new file mode 100644
index 0000000..4800a64
--- /dev/null
+++ b/opengl/tools/glgen/static/egl/EGLSurface.java
@@ -0,0 +1,41 @@
+/*
+**
+** Copyright 2012, 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
+**
+** 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
+** limitations under the License.
+*/
+
+package android.opengl;
+
+/**
+ * @hide
+ */
+public class EGLSurface extends EGLObjectHandle {
+ public EGLSurface(int handle) {
+ super(handle);
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+
+ EGLSurface that = (EGLSurface) o;
+ return getHandle() == that.getHandle();
+ }
+
+ @Override
+ public int hashCode() {
+ return getHandle();
+ }
+}