FUNCTION REFERENCE
view
Viewpoint of the axes.
Viewpoint of the axes.
Syntax
view(az, el)Syntax
view([az el])Syntax
view(2)Syntax
view(3)Syntax
v = viewSyntax
[az, el] = viewSyntax
view(ax, ...)az is the azimuth in degrees, measured from the negative y axis, counter-clockwise seen from above; el is the elevation in degrees up from the x-y plane. view(2) is (0, 90), the 2-D view; view(3) is (-37.5, 30). An axes is 3-D whenever its view is not (0, 90). With two outputs every form returns the angles now in effect: [az, el] = view(3) gives -37.5 and 30.
The projection is orthographic (the matrix of viewmtx); each axis is first scaled to its limits, so the axes box is a cube stretched to fill the axes. In the desktop, dragging a 3-D axes with the left mouse button rotates it (half a degree per point; elevation stays within -90 to 90) and View follows.
Example
plot3([0 1], [0 1], [0 1]); view(45, 20); v = view % [45 20]Differences from MATLAB: The camera properties (CameraPosition, CameraTarget, CameraViewAngle), view([x y z]), perspective projection and rotate3d are not supported yet.
These are the engine’s help pages. Each page keeps its compatibility notes. File operations are unavailable in the browser.