|MATLAB Function Reference|
Rotate the camera position around the camera target
rotates the camera position around the camera target by the amounts specified in
dphi (both in degrees).
dtheta is the horizontal rotation and
dphi is the vertical rotation.
coordsys argument determines the center of rotation. It can take on two values:
data(default) - rotate the camera around an axis defined by the camera target and the
direction(default is the positive z direction).
camera- rotate the camera about the point defined by the camera target.
direction argument, in conjunction with the camera target, defines the axis of rotation for the data coordinate system. Specify
direction as a three-element vector containing the x, y, and z-components of the direction or one of the characters,
z, to indicate
[1 0 0],
[0 1 0], or
[0 0 1] respectively.
operates on the axes identified by the first argument,
axes_handle. When you do not specify an axes handle,
camorbit operates on the current axes.
Compare rotation in the two coordinate systems with these
for loops. The first rotates the camera horizontally about a line defined by the camera target point and a direction that is parallel to the y-axis. Visualize this rotation as a cone formed with the camera target at the apex and the camera position forming the base:
Rotation in the
camera coordinate system orbits the camera around the axes along a circle while keeping the center of a circle at the camera target.
Controlling the Camera Viewpoint for related functions
Defining Scenes with Camera Graphics for more information