1 #ifndef __DALI_INTERNAL_EGL_IMAGE_EXTENSIONS_H__
2 #define __DALI_INTERNAL_EGL_IMAGE_EXTENSIONS_H__
5 * Copyright (c) 2014 Samsung Electronics Co., Ltd.
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
24 #include <dali/public-api/images/pixel.h>
32 class EglImplementation;
35 * EglImageExtensions class provides EGL image extension support
37 class EglImageExtensions
43 EglImageExtensions(EglImplementation* impl);
48 ~EglImageExtensions();
51 public: // EGLImageKHR extension support
54 * If the EGL Image extension is available this function returns a
56 * @param clientBuffer Client buffer to use for image creation
57 * @return an object that holds a EGLImageKHR
59 void* CreateImageKHR(EGLClientBuffer clientBuffer);
62 * If the EGL Image extension is available this function
63 * destroys the a EGLImageKHR
64 * @param eglImageKHR Object that holds a EGLImageKHR
66 void DestroyImageKHR(void* eglImageKHR);
69 * defines a 2D texture
70 * @param eglImageKHR Object that holds a EGLImageKHR
72 void TargetTextureKHR(void* eglImageKHR);
75 * Get the functions for using ImageKHR
77 void InitializeEglImageKHR();
80 EglImplementation* mEglImplementation;
82 bool mImageKHRInitialized; ///< Flag for whether extended KHR functions loaded
83 bool mImageKHRInitializeFailed; ///< Flag to avoid trying to reload extended KHR functions, if
84 /// it fails the first time
87 } // namespace Adaptor
89 } // namespace Internal
93 #endif // __DALI_INTERNAL_EGL_IMAGE_EXTENSIONS_H__