summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSaracen <SaracenOne@gmail.com>2015-07-04 00:59:03 +0100
committerSaracen <SaracenOne@gmail.com>2015-11-02 16:48:09 +0000
commit5072134f419f749b8b47021565dad3b0ee15c979 (patch)
treed8707bef4b67dc4d1183283138300511509cd2be
parentb2f9acb8c96aed0505cbac21661e21e4acef710f (diff)
Fixed canvas clipping on offscreen viewports.
-rw-r--r--drivers/gles2/rasterizer_gles2.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gles2/rasterizer_gles2.cpp b/drivers/gles2/rasterizer_gles2.cpp
index d84ee5a758..0bb58708ee 100644
--- a/drivers/gles2/rasterizer_gles2.cpp
+++ b/drivers/gles2/rasterizer_gles2.cpp
@@ -9349,7 +9349,7 @@ void RasterizerGLES2::canvas_render_items(CanvasItem *p_item_list,int p_z,const
int h = current_clip->final_clip_rect.size.y;
*/
int x = current_clip->final_clip_rect.pos.x;
- int y = window_size.height-(current_clip->final_clip_rect.pos.y+current_clip->final_clip_rect.size.y);
+ int y = viewport.height-(current_clip->final_clip_rect.pos.y+current_clip->final_clip_rect.size.y);
int w = current_clip->final_clip_rect.size.x;
int h = current_clip->final_clip_rect.size.y;