Camera commands#
NaxToView functions to control the camera in the active view.
- n2vscripting.camera.change_camera_distance(value: float) None #
Change distance parameter of the camera on the active view.
- Parameters:
value (float) – Distance parameter.
Examples
>>> n2v.change_camera_distance(10.0)
- n2vscripting.camera.change_clipping_range(lower: float, upper: float) None #
Change the clipping range of the camera on the active view.
- Parameters:
lower (float) – Lower limit of the clipping range.
upper (float) – Upper limit of the clipping range.
Examples
>>> n2v.change_clipping_range(0.1, 100.0)
- n2vscripting.camera.change_focal_point(x: float, y: float, z: float) None #
Change the focal point of the camera on the active view.
- Parameters:
x (float) – X coordinate of the focal point.
y (float) – Y coordinate of the focal point.
z (float) – Z coordinate of the focal point.
Examples
>>> n2v.change_focal_point(0.0, 0.0, 0.0)
- n2vscripting.camera.change_parallel_scale(value: float) None #
Change the parallel scale value of the camera on the active view.
- Parameters:
value (float) – Parallel scale value.
Examples
>>> n2v.change_parallel_scale(1.0)
- n2vscripting.camera.change_position(x: float, y: float, z: float) None #
Change the position of the camera on the active view.
- Parameters:
x (float) – X coordinate of the position.
y (float) – Y coordinate of the position.
z (float) – Z coordinate of the position.
Examples
>>> n2v.change_position(0.0, 0.0, 0.0)
- n2vscripting.camera.change_view_angle(value: float) None #
Change angle of the camera on the active view.
- Parameters:
value (float) – View angle
Examples
>>> n2v.change_view_angle(30.0)
- n2vscripting.camera.change_view_up(x: float, y: float, z: float) None #
Change the reference upwards direction of the camera on the active view.
- Parameters:
x (float) – X component of the direction vector.
y (float) – Y component of the direction vector.
z (float) – Z component of the direction vector.
Examples
>>> n2v.change_view_up(0.0, 1.0, 0.0)
- n2vscripting.camera.select_viewpoint(view: Literal[0, 1, 2, 3, 4, 5, 6]) None #
Select a view point from the 7 default views available.
- Parameters:
view (int) –
- id of the view. Available options are:
0 -> Isometric view
1 -> X-Y plane. X right, Y up.
2 -> X-Z plane. X left, Z up.
3 -> X-Y plane. X right, Y down.
4 -> Y-Z plane. Y left, Z up.
5 -> X-Z plane. X right, Z up.
6 -> Y-Z plane. Y right, Z up.
Examples
>>> # To change to isometric view >>> n2v.select_viewpoint(0)
>>> # To change to X-Y plane view, with X right and Y up >>> n2v.select_viewpoint(1)