Fail-safety in spreadRectangles.
This commit is contained in:
parent
b888714ed5
commit
b5191c8c22
|
@ -88,7 +88,7 @@ std::optional<rectpack2D::rect_wh> spreadRectangles( rect_vector& vecSubRects, i
|
||||||
|
|
||||||
int max_side = std::max( areaSizeX, areaSizeY );
|
int max_side = std::max( areaSizeX, areaSizeY );
|
||||||
|
|
||||||
while( true )
|
for( int i = 0; i < 2000; i++ )
|
||||||
{
|
{
|
||||||
bool anyUnsuccessful = false;
|
bool anyUnsuccessful = false;
|
||||||
const int discard_step = 1;
|
const int discard_step = 1;
|
||||||
|
|
Loading…
Reference in New Issue