You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2026-01-07 19:53:17 +00:00
Fix size error in BitMap.opaque_to_polygons
Previous estimate of upper limit on size was incorrect
This commit is contained in:
@@ -354,7 +354,7 @@ Vector<Vector<Vector2>> BitMap::_march_square(const Rect2i &p_rect, const Point2
|
||||
prevx = stepx;
|
||||
prevy = stepy;
|
||||
|
||||
ERR_FAIL_COND_V((int)count > width * height, Vector<Vector<Vector2>>());
|
||||
ERR_FAIL_COND_V((int)count > 2 * (width * height + 1), Vector<Vector<Vector2>>());
|
||||
} while (curx != startx || cury != starty);
|
||||
|
||||
// Add remaining points to result.
|
||||
|
||||
Reference in New Issue
Block a user