mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[apps/shared] computeYRange clips tMin..tMax to xMin..xMax if possible
This commit is contained in:
@@ -92,10 +92,14 @@ InteractiveCurveViewRangeDelegate::Range FunctionGraphController::computeYRange(
|
||||
double tMin = f->tMin();
|
||||
if (std::isnan(tMin)) {
|
||||
tMin = xMin;
|
||||
} else if (f->shouldClipTRangeToXRange()) {
|
||||
tMin = maxFloat(tMin, xMin);
|
||||
}
|
||||
double tMax = f->tMax();
|
||||
if (std::isnan(tMax)) {
|
||||
tMax = xMax;
|
||||
} else if (f->shouldClipTRangeToXRange()) {
|
||||
tMax = minFloat(tMax, xMax);
|
||||
}
|
||||
const int balancedBound = std::floor((tMax-tMin)/2/step);
|
||||
for (int j = -balancedBound; j <= balancedBound ; j++) {
|
||||
|
||||
Reference in New Issue
Block a user