forked from enlightenment/efl
evas-gl-drm: Fix issue of rotation not actually rotating
When we call evas_outbuf_reconfigure (when rotation changes), we need to update the Outbuf with new values for width, height, rotation, etc. Failing to do this here causes any rotations applied to the engine to fail. ref T7690 @fix Reviewed-by: Cedric BAIL <cedric.bail@free.fr> Differential Revision: https://phab.enlightenment.org/D8109
This commit is contained in:
parent
1f7d7d0606
commit
f5fed8764d
|
@ -550,14 +550,18 @@ evas_outbuf_reconfigure(Outbuf *ob, int w, int h, int rot, Outbuf_Depth depth)
|
|||
|
||||
while (ecore_drm2_fb_release(ob->priv.output, EINA_TRUE));
|
||||
|
||||
ob->w = w;
|
||||
ob->h = h;
|
||||
ob->rotation = rot;
|
||||
|
||||
_evas_outbuf_gbm_surface_destroy(ob);
|
||||
|
||||
if ((ob->rotation == 0) || (ob->rotation == 180))
|
||||
_evas_outbuf_gbm_surface_create(ob, w, h);
|
||||
else if ((ob->rotation == 90) || (ob->rotation == 270))
|
||||
_evas_outbuf_gbm_surface_create(ob, h, w);
|
||||
_evas_outbuf_egl_setup(ob);
|
||||
|
||||
glsym_evas_gl_common_context_resize(ob->gl_context, w, h, rot);
|
||||
_evas_outbuf_egl_setup(ob);
|
||||
}
|
||||
|
||||
Render_Output_Swap_Mode
|
||||
|
@ -622,7 +626,7 @@ evas_outbuf_update_region_first_rect(Outbuf *ob)
|
|||
|
||||
if (!_re_wincheck(ob)) return EINA_TRUE;
|
||||
|
||||
/* glsym_evas_gl_common_context_resize(ob->gl_context, ob->w, ob->h, ob->rotation); */
|
||||
glsym_evas_gl_common_context_resize(ob->gl_context, ob->w, ob->h, ob->rotation);
|
||||
glsym_evas_gl_common_context_flush(ob->gl_context);
|
||||
glsym_evas_gl_common_context_newframe(ob->gl_context);
|
||||
|
||||
|
|
Loading…
Reference in New Issue