Virtual Reality Toolbox | ![]() ![]() |
Create a new virtual reality figure
Syntax
Description
f = vrfigure(world)
creates a new virtual reality figure showing the specified world and returns an appropriate vrfigure object. The input argument world
must be a vrworld object.
f = vrfigure(world,position)
creates a new virtual reality figure at the specified position.
f = vrfigure
returns an empty vrfigure object that does not have a visual representation.
f = vrfigure([])
returns an empty vector of type vrfigure.
Example
Create a vrworld object. At the MATLAB command prompt, type
myworld = vrworld('vrmount.wrl')
The vrworld object myworld
is associated with the virtual world vrmount.wrl
.
Next, open the virtual world using the vrworld object. You must open the virtual world before you can view it. At the MATLAB command prompt, type
You can now view the virtual world in the Virtual Reality Toolbox viewer by typing
Your viewer opens and displays the virtual scene.
See also
![]() | vrfigure Object Methods | vrfigure/capture | ![]() |