From 70787ce65438667a7edb32faddb781113f0120bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Cassiers?= Date: Tue, 6 May 2025 21:00:07 +0200 Subject: [PATCH] Change threshold from SubPlot.auto_scale --- fastplotlib/layouts/_plot_area.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fastplotlib/layouts/_plot_area.py b/fastplotlib/layouts/_plot_area.py index 2934e058..f28fa1e5 100644 --- a/fastplotlib/layouts/_plot_area.py +++ b/fastplotlib/layouts/_plot_area.py @@ -597,9 +597,9 @@ def auto_scale( width, height, depth = (1, 1, 1) # make sure width and height are non-zero - if width < 0.01: + if width <= np.finfo(np.float32).smallest_normal: width = 1 - if height < 0.01: + if height <= np.finfo(np.float32).smallest_normal: height = 1 # scale all cameras associated with this controller else it looks wonky