EGL_ANDROID_recordable#
Supported Hardware#
Series6, Series6XE, Series6XT
Valid APIs#
EGL 1.4
Description#
Android supports a number of different ANativeWindow implementations that can be used to create an EGLSurface. One implementation, which records the rendered image as a video each time eglSwapBuffers gets called, may have some device-specific restrictions. Because of this, some EGLConfigs may be incompatible with these ANativeWindows.
This extension introduces a new boolean EGLConfig attribute that indicates whether the EGLConfig supports rendering to an ANativeWindow that records images to a video.
Note#
Requires EGL 1.0
This extension is written against the wording of the EGL 1.4 Specification
Registry Link#
https://www.khronos.org/registry/egl/extensions/ANDROID/EGL_ANDROID_recordable.txt
Example#
// Set up the config attributes, specifying that we want a config which
// support recording the rendered image as a video.
EGLint configAttribs[] =
{
EGL_SURFACE_TYPE, EGL_WINDOW_BIT,
EGL_RENDERABLE_TYPE , EGL_OPENGL_ES2_BIT,
EGL_RECORDABLE_ANDROID, EGL_TRUE,
EGL_NONE
};
// Choose an appropriate configuration - just get the first available one that matches in this case
EGLint iConfigs;
EGLConfig eglConfig;
eglChooseConfig(eglDisplay, configAttribs, &eglConfig, 1, &iConfigs);