28 eglGraphicsPipe(
const std::string &display) :
x11GraphicsPipe(display) {
29 _egl_display = eglGetDisplay((NativeDisplayType) _display);
30 if (!eglInitialize(_egl_display,
nullptr,
nullptr)) {
31 egldisplay_cat.error()
32 <<
"Couldn't initialize the EGL display: "
36 if (!eglBindAPI(EGL_OPENGL_ES_API)) {
37 egldisplay_cat.error()
38 <<
"Couldn't bind EGL to the OpenGL ES API: "
49 if (!eglTerminate(_egl_display)) {
50 egldisplay_cat.error() <<
"Failed to terminate EGL display: "
80 make_output(
const std::string &name,
96 DCAST_INTO_R(eglgsg, gsg,
nullptr);
113 if (((flags&BF_require_parasite)!=0)||
114 ((flags&BF_refuse_window)!=0)||
115 ((flags&BF_resizeable)!=0)||
116 ((flags&BF_size_track_host)!=0)||
117 ((flags&BF_rtt_cumulative)!=0)||
118 ((flags&BF_can_bind_color)!=0)||
119 ((flags&BF_can_bind_every)!=0)) {
130 ((flags&BF_require_parasite)!=0)||
131 ((flags&BF_require_window)!=0)) {
136 if ((flags & BF_fb_props_optional)==0) {
137 if ((fb_prop.get_indexed_color() > 0)||
138 (fb_prop.get_back_buffers() > 0)||
139 (fb_prop.get_accum_bits() > 0)||
140 (fb_prop.get_multisamples() > 0)) {
147 (eglgsg->is_valid()) &&
148 (!eglgsg->needs_reset()) &&
149 (eglgsg->_supports_framebuffer_object) &&
150 (eglgsg->_glDrawBuffers != 0)&&
155 return new GLES2GraphicsBuffer(engine,
this, name, fb_prop, win_prop,
158 return new GLESGraphicsBuffer(engine,
this, name, fb_prop, win_prop,
165 if (((flags&BF_require_parasite)!=0)||
166 ((flags&BF_require_window)!=0)||
167 ((flags&BF_resizeable)!=0)||
168 ((flags&BF_size_track_host)!=0)) {
173 if (((flags&BF_rtt_cumulative)!=0)||
174 ((flags&BF_can_bind_every)!=0)) {
187 if (((flags&BF_require_parasite)!=0)||
188 ((flags&BF_require_window)!=0)||
189 ((flags&BF_resizeable)!=0)||
190 ((flags&BF_size_track_host)!=0)) {
194 if (((flags&BF_rtt_cumulative)!=0)||
195 ((flags&BF_can_bind_every)!=0)) {