remove unnecesary warning, closes #5169

This commit is contained in:
Juan Linietsky 2016-06-29 18:27:12 -03:00
parent 22d5227663
commit e5fc62cc4b

View file

@ -1331,11 +1331,11 @@ Matrix32 Viewport::_get_input_pre_xform() const {
Matrix32 pre_xf; Matrix32 pre_xf;
if (render_target) { if (render_target) {
ERR_FAIL_COND_V(to_screen_rect.size.x==0,pre_xf); if (to_screen_rect!=Rect2()) {
ERR_FAIL_COND_V(to_screen_rect.size.y==0,pre_xf);
pre_xf.elements[2]=-to_screen_rect.pos; pre_xf.elements[2]=-to_screen_rect.pos;
pre_xf.scale(rect.size/to_screen_rect.size); pre_xf.scale(rect.size/to_screen_rect.size);
}
} else { } else {
pre_xf.elements[2]=-rect.pos; pre_xf.elements[2]=-rect.pos;