diff options
Diffstat (limited to 'silx/gui/plot3d/scene/camera.py')
-rw-r--r-- | silx/gui/plot3d/scene/camera.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/silx/gui/plot3d/scene/camera.py b/silx/gui/plot3d/scene/camera.py index acc5899..90de7ed 100644 --- a/silx/gui/plot3d/scene/camera.py +++ b/silx/gui/plot3d/scene/camera.py @@ -292,6 +292,8 @@ class Camera(transform.Transform): center = 0.5 * (bounds[0] + bounds[1]) radius = numpy.linalg.norm(0.5 * (bounds[1] - bounds[0])) + if radius == 0.: # bounds are all collapsed + radius = 1. if isinstance(self.intrinsic, transform.Perspective): # Get the viewpoint distance from the bounds center |