Home | History | Annotate | Download | only in libOpenglRender
      1 /*
      2 * Copyright (C) 2011 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 #ifndef _EGL_DISPATCH_H
     17 #define _EGL_DISPATCH_H
     18 
     19 #include "egl_proc.h"
     20 
     21 struct EGLDispatch {
     22     eglGetError_t eglGetError;
     23     eglGetDisplay_t eglGetDisplay;
     24     eglInitialize_t eglInitialize;
     25     eglTerminate_t eglTerminate;
     26     eglQueryString_t eglQueryString;
     27     eglGetConfigs_t eglGetConfigs;
     28     eglChooseConfig_t eglChooseConfig;
     29     eglGetConfigAttrib_t eglGetConfigAttrib;
     30     eglCreateWindowSurface_t eglCreateWindowSurface;
     31     eglCreatePbufferSurface_t eglCreatePbufferSurface;
     32     eglCreatePixmapSurface_t eglCreatePixmapSurface;
     33     eglDestroySurface_t eglDestroySurface;
     34     eglQuerySurface_t eglQuerySurface;
     35     eglBindAPI_t eglBindAPI;
     36     eglQueryAPI_t eglQueryAPI;
     37     eglWaitClient_t eglWaitClient;
     38     eglReleaseThread_t eglReleaseThread;
     39     eglCreatePbufferFromClientBuffer_t eglCreatePbufferFromClientBuffer;
     40     eglSurfaceAttrib_t eglSurfaceAttrib;
     41     eglBindTexImage_t eglBindTexImage;
     42     eglReleaseTexImage_t eglReleaseTexImage;
     43     eglSwapInterval_t eglSwapInterval;
     44     eglCreateContext_t eglCreateContext;
     45     eglDestroyContext_t eglDestroyContext;
     46     eglMakeCurrent_t eglMakeCurrent;
     47     eglGetCurrentContext_t eglGetCurrentContext;
     48     eglGetCurrentSurface_t eglGetCurrentSurface;
     49     eglGetCurrentDisplay_t eglGetCurrentDisplay;
     50     eglQueryContext_t eglQueryContext;
     51     eglWaitGL_t eglWaitGL;
     52     eglWaitNative_t eglWaitNative;
     53     eglSwapBuffers_t eglSwapBuffers;
     54     eglCopyBuffers_t eglCopyBuffers;
     55     eglGetProcAddress_t eglGetProcAddress;
     56     eglLockSurfaceKHR_t eglLockSurfaceKHR;
     57     eglUnlockSurfaceKHR_t eglUnlockSurfaceKHR;
     58     eglCreateImageKHR_t eglCreateImageKHR;
     59     eglDestroyImageKHR_t eglDestroyImageKHR;
     60     eglCreateSyncKHR_t eglCreateSyncKHR;
     61     eglDestroySyncKHR_t eglDestroySyncKHR;
     62     eglClientWaitSyncKHR_t eglClientWaitSyncKHR;
     63     eglSignalSyncKHR_t eglSignalSyncKHR;
     64     eglGetSyncAttribKHR_t eglGetSyncAttribKHR;
     65     eglSetSwapRectangleANDROID_t eglSetSwapRectangleANDROID;
     66 };
     67 
     68 bool init_egl_dispatch();
     69 
     70 extern EGLDispatch s_egl;
     71 
     72 #endif
     73