@@ -72,8 +72,8 @@ def get_arguments(argv=None):
7272 action = "store_true" ,
7373 help = "Use PyVista BackgroundPlotter (non-blocking GUI, needs pyqt6 pyvistaqt)" ,
7474 )
75- parser .add_argument ("-pvw" , "--width" , type = int , default = 2400 , help = "Set plotter width" )
76- parser .add_argument ("-pvh" , "--height" , type = int , default = 1600 , help = "Set plotter height" )
75+ parser .add_argument ("-pvw" , "--width" , type = int , default = 1200 , help = "Set plotter width" )
76+ parser .add_argument ("-pvh" , "--height" , type = int , default = 800 , help = "Set plotter height" )
7777 parser .add_argument ("-pvx" , "--x" , type = int , default = 0 , help = "Set plotter x position" )
7878 parser .add_argument ("-pvy" , "--y" , type = int , default = 0 , help = "Set plotter y position" )
7979 parser .add_argument ("-axes" , "--add_axes_at_zero" , action = "store_true" ,
@@ -169,7 +169,6 @@ def plotter(self):
169169
170170 self ._plotter .add_axes ()
171171 self ._plotter .set_background ("#303048" , top = "#000020" )
172- self ._plotter .camera_position = "iso"
173172
174173 return self ._plotter
175174
@@ -320,7 +319,6 @@ def show(self, block: bool = True):
320319 if _in_jupyter :
321320
322321 cpos = self ._configure_camera_from_bounds (
323- margin = - 12.8 ,
324322 distance_scale = 3.0 ,
325323 )
326324 return p .show (
@@ -367,8 +365,9 @@ def _configure_camera_from_bounds(self, margin: float = 0.8, distance_scale: flo
367365 if scene_len <= 0 :
368366 scene_len = max (dx , dy , dz , 1.0 )
369367
370- direction = np .array ([1.0 , 1.0 , 1.0 ])
371- direction /= np .linalg .norm (direction )
368+ # View from +X toward the geometry center.
369+ # With this view_up, +Z goes left-to-right on screen.
370+ direction = np .array ([1.0 , 0.0 , 0.0 ])
372371
373372 # Larger distance_scale = more zoomed out
374373 distance = distance_scale * scene_len
@@ -377,7 +376,7 @@ def _configure_camera_from_bounds(self, margin: float = 0.8, distance_scale: flo
377376 cpos = [
378377 tuple (position ),
379378 tuple (center ),
380- (0 , 0 , 1 ),
379+ (0 , - 1 , 0 ),
381380 ]
382381
383382 p .camera_position = cpos
0 commit comments