|On this page…|
You can view VRML animation files using one of these approaches:
Open the 3D Animation Player from the MATLAB® Toolstrip.
To open the 3D Animation Player from the MATLAB Toolstrip, in the Apps tab, in the Simulation Graphics and Reporting section, click 3D Animation Player. Select or specify an a VRML animation file.
From the operating system, locate and double-click the VRML animation file
Double-click the VRML file. A VRML-enabled Web browser opens with the animation running. To view the resulting animation file, you must have a VRML-enabled Web browser installed on your system. Also, ensure that the .wrl extension is associated with the Blaxxun Contact® Web browser.
For example, play the animation file based on the vr_octavia example by running vrplay('octavia_scene_anim.wrl').
vrplay works only with VRML animation files created using the Simulink® 3D Animation™ VRML recording functionality.
In the Current Folder pane of MATLAB, double-click the VRML animation file and from the context menu, select Run.
At the MATLAB command line, use vrview.
A fourth option is to use the MATLAB command vrview. For example, enter:
The vrview command displays the default Simulink 3D Animation Viewer for the animation file. Setting the TimeSource property of the set method to 'freerun' directs the viewer to advance its time independent of the MATLAB software.
To close the viewer and delete the world, get the handle of the vrfigure object and close it, as follows:
f=get(w,'Figures') close(f); delete(w);
Or, to close all vrfigure objects and delete the world, type
To view an AVI animation file, use one of these approaches:
Double-click the AVI animation file. The program associated with .avi files in your system (for example, Windows Media® Player Media Player) opens for the .avi file. If your .avi file is not yet running, start it now from the application. The animation file runs.
Use the MATLAB VideoReader function.