MCPcopy Create free account
hub / github.com/brenocq/implot3d / ExtendFit

Method ExtendFit

implot3d.cpp:3943–3950  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3941bool ImPlot3DAxis::IsAutoFitting() const { return ImPlot3D::ImHasFlag(Flags, ImPlot3DAxisFlags_AutoFit); }
3942
3943void ImPlot3DAxis::ExtendFit(double value) {
3944 // Only extend fit with values that are within the constraint range
3945 // This is critical for log scale where negative/zero values should be ignored
3946 if (!ImPlot3D::ImNanOrInf(value) && value >= ConstraintRange.Min && value <= ConstraintRange.Max) {
3947 FitExtents.Min = ImMin(FitExtents.Min, value);
3948 FitExtents.Max = ImMax(FitExtents.Max, value);
3949 }
3950}
3951
3952void ImPlot3DAxis::ApplyFit() {
3953 if (!IsLockedMin() && !ImPlot3D::ImNanOrInf(FitExtents.Min))

Callers 1

BeginItemExFunction · 0.80

Calls 1

ImNanOrInfFunction · 0.85

Tested by

no test coverage detected