camorbit
围绕相机目标旋转相机
语法
camorbit(dtheta,dphi)
camorbit(dtheta,dphi,'coordsys
')
camorbit(dtheta,dphi,'coordsys
','direction')
camorbit(axes_handle,...)
说明
camorbit(dtheta,dphi)
围绕相机目标将相机位置旋转 dtheta
和 dphi
(均以度为单位)中的指定距离。dtheta
是水平旋转,dphi
是垂直旋转。
camorbit(dtheta,dphi,'
围绕相机目标旋转相机位置,并使用 coordsys
')coordsys
参数确定旋转中心。coordsys
可采用两个值:
data
(默认值)- 围绕相机目标和direction
(默认值为正 z 方向)定义的轴旋转相机。camera
- 将相机旋转约相机目标定义的点数。
camorbit(dtheta,dphi,'
通过配合使用 coordsys
','direction')direction
参数和相机目标来为数据坐标系定义旋转轴。将 direction
指定为包含方向的 x、y 和 z 分量的三元素向量或选项 x
、y
或 z
之一,以便分别指示 [1 0 0]
、[0 1 0]
或 [0 0 1]
。
camorbit(axes_handle,...)
在第一个参数 axes_handle
标识的坐标区上操作。不指定坐标区句柄时,camorbit
在当前坐标区上操作。
camorbit
与 rotate3d
函数行为的区别在于,rotate3d
工具修改坐标区的 View
属性,而 camorbit
函数固定纵横比并修改坐标区的 CameraTarget
、CameraPosition
和 CameraUpVector
属性。有关坐标区属性的详细信息,请参阅 Axes 属性。
示例
备选方法
使用图窗的工具菜单或图窗工具栏启用三维旋转。
版本历史记录
在 R2006a 之前推出