mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[interactive_curve_view_range] Fix assert
Change-Id: I2ff3cfe90f10b33db3e18b321cf931c9f0946479
This commit is contained in:
committed by
Émilie Feral
parent
9e9033537c
commit
fe950386a0
@@ -154,9 +154,10 @@ void InteractiveCurveViewRange::normalize() {
|
||||
m_yRange.setMin(newYMin, k_lowerMaxFloat, k_upperMaxFloat);
|
||||
MemoizedCurveViewRange::protectedSetYMax(newYMax, k_lowerMaxFloat, k_upperMaxFloat);
|
||||
|
||||
/* When the coordinates reach 10^7, the float type is not precise enough to
|
||||
/* When the coordinates reach 10^6, the float type is not precise enough to
|
||||
* properly normalize. */
|
||||
constexpr float limit = 1e7f;
|
||||
// FIXME : Fine a more precise way to filter the edge cases
|
||||
constexpr float limit = 1e6f;
|
||||
assert(isOrthonormal() || xMin() < -limit || xMax() > limit || yMin() < -limit || yMax() > limit);
|
||||
(void) limit; // Silence compilation warning about unused variable.
|
||||
setZoomNormalize(isOrthonormal());
|
||||
|
||||
Reference in New Issue
Block a user