forked from enlightenment/efl
evas gl: clip rect with proper size.
gc width/height indicates the main output size, if the target surface(fbo) is larger than this, rect won't be drawn. We should clip this with current context size. @fix
This commit is contained in:
parent
7a79e15ea3
commit
b2bd0c548f
|
@ -12,7 +12,7 @@ evas_gl_common_rect_draw(Evas_Engine_GL_Context *gc, int x, int y, int w, int h)
|
|||
Evas_GL_Texture *mtex = NULL;
|
||||
|
||||
if ((w <= 0) || (h <= 0)) return;
|
||||
if (!(RECTS_INTERSECT(x, y, w, h, 0, 0, gc->w, gc->h))) return;
|
||||
if (!(RECTS_INTERSECT(x, y, w, h, 0, 0, gc->shared->w, gc->shared->h))) return;
|
||||
/* save out clip info */
|
||||
c = gc->dc->clip.use; cx = gc->dc->clip.x; cy = gc->dc->clip.y; cw = gc->dc->clip.w; ch = gc->dc->clip.h;
|
||||
|
||||
|
|
Loading…
Reference in New Issue