1 /* 2 * Copyright (C) 2006 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package javax.microedition.khronos.egl; 18 19 import android.compat.annotation.UnsupportedAppUsage; 20 21 public interface EGL10 extends EGL { 22 int EGL_SUCCESS = 0x3000; 23 int EGL_NOT_INITIALIZED = 0x3001; 24 int EGL_BAD_ACCESS = 0x3002; 25 int EGL_BAD_ALLOC = 0x3003; 26 int EGL_BAD_ATTRIBUTE = 0x3004; 27 int EGL_BAD_CONFIG = 0x3005; 28 int EGL_BAD_CONTEXT = 0x3006; 29 int EGL_BAD_CURRENT_SURFACE = 0x3007; 30 int EGL_BAD_DISPLAY = 0x3008; 31 int EGL_BAD_MATCH = 0x3009; 32 int EGL_BAD_NATIVE_PIXMAP = 0x300A; 33 int EGL_BAD_NATIVE_WINDOW = 0x300B; 34 int EGL_BAD_PARAMETER = 0x300C; 35 int EGL_BAD_SURFACE = 0x300D; 36 int EGL_BUFFER_SIZE = 0x3020; 37 int EGL_ALPHA_SIZE = 0x3021; 38 int EGL_BLUE_SIZE = 0x3022; 39 int EGL_GREEN_SIZE = 0x3023; 40 int EGL_RED_SIZE = 0x3024; 41 int EGL_DEPTH_SIZE = 0x3025; 42 int EGL_STENCIL_SIZE = 0x3026; 43 int EGL_CONFIG_CAVEAT = 0x3027; 44 int EGL_CONFIG_ID = 0x3028; 45 int EGL_LEVEL = 0x3029; 46 int EGL_MAX_PBUFFER_HEIGHT = 0x302A; 47 int EGL_MAX_PBUFFER_PIXELS = 0x302B; 48 int EGL_MAX_PBUFFER_WIDTH = 0x302C; 49 int EGL_NATIVE_RENDERABLE = 0x302D; 50 int EGL_NATIVE_VISUAL_ID = 0x302E; 51 int EGL_NATIVE_VISUAL_TYPE = 0x302F; 52 int EGL_SAMPLES = 0x3031; 53 int EGL_SAMPLE_BUFFERS = 0x3032; 54 int EGL_SURFACE_TYPE = 0x3033; 55 int EGL_TRANSPARENT_TYPE = 0x3034; 56 int EGL_TRANSPARENT_BLUE_VALUE = 0x3035; 57 int EGL_TRANSPARENT_GREEN_VALUE = 0x3036; 58 int EGL_TRANSPARENT_RED_VALUE = 0x3037; 59 int EGL_NONE = 0x3038; 60 int EGL_LUMINANCE_SIZE = 0x303D; 61 int EGL_ALPHA_MASK_SIZE = 0x303E; 62 int EGL_COLOR_BUFFER_TYPE = 0x303F; 63 int EGL_RENDERABLE_TYPE = 0x3040; 64 int EGL_SLOW_CONFIG = 0x3050; 65 int EGL_NON_CONFORMANT_CONFIG = 0x3051; 66 int EGL_TRANSPARENT_RGB = 0x3052; 67 int EGL_RGB_BUFFER = 0x308E; 68 int EGL_LUMINANCE_BUFFER = 0x308F; 69 int EGL_VENDOR = 0x3053; 70 int EGL_VERSION = 0x3054; 71 int EGL_EXTENSIONS = 0x3055; 72 int EGL_HEIGHT = 0x3056; 73 int EGL_WIDTH = 0x3057; 74 int EGL_LARGEST_PBUFFER = 0x3058; 75 int EGL_RENDER_BUFFER = 0x3086; 76 int EGL_COLORSPACE = 0x3087; 77 int EGL_ALPHA_FORMAT = 0x3088; 78 int EGL_HORIZONTAL_RESOLUTION = 0x3090; 79 int EGL_VERTICAL_RESOLUTION = 0x3091; 80 int EGL_PIXEL_ASPECT_RATIO = 0x3092; 81 int EGL_SINGLE_BUFFER = 0x3085; 82 int EGL_CORE_NATIVE_ENGINE = 0x305B; 83 int EGL_DRAW = 0x3059; 84 int EGL_READ = 0x305A; 85 86 int EGL_DONT_CARE = -1; 87 88 int EGL_PBUFFER_BIT = 0x01; 89 int EGL_PIXMAP_BIT = 0x02; 90 int EGL_WINDOW_BIT = 0x04; 91 92 Object EGL_DEFAULT_DISPLAY = null; 93 EGLDisplay EGL_NO_DISPLAY = new com.google.android.gles_jni.EGLDisplayImpl(0); 94 EGLContext EGL_NO_CONTEXT = new com.google.android.gles_jni.EGLContextImpl(0); 95 EGLSurface EGL_NO_SURFACE = new com.google.android.gles_jni.EGLSurfaceImpl(0); 96 eglChooseConfig(EGLDisplay display, int[] attrib_list, EGLConfig[] configs, int config_size, int[] num_config)97 boolean eglChooseConfig(EGLDisplay display, int[] attrib_list, EGLConfig[] configs, int config_size, int[] num_config); eglCopyBuffers(EGLDisplay display, EGLSurface surface, Object native_pixmap)98 boolean eglCopyBuffers(EGLDisplay display, EGLSurface surface, Object native_pixmap); eglCreateContext(EGLDisplay display, EGLConfig config, EGLContext share_context, int[] attrib_list)99 EGLContext eglCreateContext(EGLDisplay display, EGLConfig config, EGLContext share_context, int[] attrib_list); eglCreatePbufferSurface(EGLDisplay display, EGLConfig config, int[] attrib_list)100 EGLSurface eglCreatePbufferSurface(EGLDisplay display, EGLConfig config, int[] attrib_list); 101 @Deprecated eglCreatePixmapSurface(EGLDisplay display, EGLConfig config, Object native_pixmap, int[] attrib_list)102 EGLSurface eglCreatePixmapSurface(EGLDisplay display, EGLConfig config, Object native_pixmap, int[] attrib_list); eglCreateWindowSurface(EGLDisplay display, EGLConfig config, Object native_window, int[] attrib_list)103 EGLSurface eglCreateWindowSurface(EGLDisplay display, EGLConfig config, Object native_window, int[] attrib_list); eglDestroyContext(EGLDisplay display, EGLContext context)104 boolean eglDestroyContext(EGLDisplay display, EGLContext context); eglDestroySurface(EGLDisplay display, EGLSurface surface)105 boolean eglDestroySurface(EGLDisplay display, EGLSurface surface); eglGetConfigAttrib(EGLDisplay display, EGLConfig config, int attribute, int[] value)106 boolean eglGetConfigAttrib(EGLDisplay display, EGLConfig config, int attribute, int[] value); eglGetConfigs(EGLDisplay display, EGLConfig[] configs, int config_size, int[] num_config)107 boolean eglGetConfigs(EGLDisplay display, EGLConfig[] configs, int config_size, int[] num_config); eglGetCurrentContext()108 EGLContext eglGetCurrentContext(); eglGetCurrentDisplay()109 EGLDisplay eglGetCurrentDisplay(); eglGetCurrentSurface(int readdraw)110 EGLSurface eglGetCurrentSurface(int readdraw); eglGetDisplay(Object native_display)111 EGLDisplay eglGetDisplay(Object native_display); eglGetError()112 int eglGetError(); eglInitialize(EGLDisplay display, int[] major_minor)113 boolean eglInitialize(EGLDisplay display, int[] major_minor); eglMakeCurrent(EGLDisplay display, EGLSurface draw, EGLSurface read, EGLContext context)114 boolean eglMakeCurrent(EGLDisplay display, EGLSurface draw, EGLSurface read, EGLContext context); eglQueryContext(EGLDisplay display, EGLContext context, int attribute, int[] value)115 boolean eglQueryContext(EGLDisplay display, EGLContext context, int attribute, int[] value); eglQueryString(EGLDisplay display, int name)116 String eglQueryString(EGLDisplay display, int name); eglQuerySurface(EGLDisplay display, EGLSurface surface, int attribute, int[] value)117 boolean eglQuerySurface(EGLDisplay display, EGLSurface surface, int attribute, int[] value); 118 /** @hide **/ 119 @UnsupportedAppUsage eglReleaseThread()120 boolean eglReleaseThread(); eglSwapBuffers(EGLDisplay display, EGLSurface surface)121 boolean eglSwapBuffers(EGLDisplay display, EGLSurface surface); eglTerminate(EGLDisplay display)122 boolean eglTerminate(EGLDisplay display); eglWaitGL()123 boolean eglWaitGL(); eglWaitNative(int engine, Object bindTarget)124 boolean eglWaitNative(int engine, Object bindTarget); 125 } 126