95
95
if (_display == EGL_NO_DISPLAY) {
98
log_trace("EGL: getDisplay ok");
98
log_trace(_("EGL: getDisplay ok"));
100
100
result = eglInitialize(_display, &majorVersion, &minorVersion);
101
101
if (result == EGL_FALSE) {
104
log_trace("EGL: initialize ok");
104
log_trace(_("EGL: initialize ok"));
106
106
result = eglChooseConfig(_display, main_attrib_list, &_config, 1,
108
108
if (result == EGL_FALSE || numOfConfigs != 1) {
111
log_trace("EGL: config ok");
111
log_trace(_("EGL: config ok"));
113
113
_surface = eglCreateWindowSurface(_display, _config, (NativeWindowType)0,
115
115
if (eglGetError () != EGL_SUCCESS) {
118
log_trace("EGL: surface ok");
118
log_trace(_("EGL: surface ok"));
120
120
_context = eglCreateContext(_display, _config, NULL, NULL);
121
121
if (eglGetError () != EGL_SUCCESS) {
124
log_trace("EGL: context ok");
124
log_trace(_("EGL: context ok"));
126
126
eglMakeCurrent(_display, _surface, _surface, _context);
127
127
if (eglGetError () != EGL_SUCCESS) {
130
log_trace("EGL: current ok");
130
log_trace(_("EGL: current ok"));
132
132
const EGLint pbuffer_config_list[] = {
133
133
EGL_SURFACE_TYPE, EGL_PBUFFER_BIT,
143
143
if (result == EGL_FALSE || numOfConfigs == 0) {
146
log_trace("EGL: pbuffer config ok");
146
// log_trace("EGL: pbuffer config ok");
148
148
const EGLint pbuffer_attrib_list[] = {
149
149
EGL_WIDTH, EGL_MAX_PBUFFER_WIDTH,