Products & Services Solutions Academia Support User Community Company

Learn more about Simulink 3D Animation   

canvas (vr.canvas) - Create virtual reality canvas object

Syntax

c = canvas(vrworld)
c = canvas(vrworld, parent)
c = canvas(vrworld, parent, position)
c = canvas(world, 'propertyName', propertyValue,...)

Description

c = canvas(vrworld) creates a MATLAB figure containing a virtual reality canvas that shows the specified virtual reality world. It returns a virtual reality canvas object.

c = canvas(vrworld, parent) creates a virtual reality canvas that shows the specified virtual world in the figure specified in parent. It returns a virtual reality canvas object.

c = canvas(vrworld, parent, position) creates a virtual reality canvas object that shows the specified virtual world in the figure specified in parent at position, specified in pixels. It returns a virtual reality canvas object.

c = canvas(world, 'propertyName', propertyValue,...) creates a virtual reality canvas that shows the specified world with specified properties. See vr.canvas for a list of the properties and their values.

Example

Create a vr.canvas object to contain the virtual world, vrlights.

w = vrworld('vrlights'); 
open(w); 
f1 = figure; 
c = vr.canvas(w, f1, [30 30 300 200]); 

z=capture(c); 
figure; 
image(z); 
  


Related Products & Applications

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS