mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-12 06:09:01 +08:00
Hotfix for arrange not working for objects with huge translation.
This commit is contained in:
parent
77e25c5022
commit
92cf46773a
@ -501,8 +501,9 @@ inline P _Box<P>::center() const BP2D_NOEXCEPT {
|
|||||||
using Coord = TCoord<P>;
|
using Coord = TCoord<P>;
|
||||||
|
|
||||||
P ret = { // No rounding here, we dont know if these are int coords
|
P ret = { // No rounding here, we dont know if these are int coords
|
||||||
Coord( (getX(minc) + getX(maxc)) / Coord(2) ),
|
// Doing the division like this increases the max range of x and y coord
|
||||||
Coord( (getY(minc) + getY(maxc)) / Coord(2) )
|
getX(minc) / Coord(2) + getX(maxc) / Coord(2),
|
||||||
|
getY(minc) / Coord(2) + getY(maxc) / Coord(2)
|
||||||
};
|
};
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user