主要内容

Interact with Virtual Reality Worlds

与MATLAB创建和互动®虚拟世界对象,输入虚拟世界数据金宝app®模型s

您可以使用MATLABfunctions and classes to interact with virtual reality worlds. Create a virtual world object (vrobject)和节点对象(VRNODE)代表您创建的虚拟世界金宝appSimulink 3D动画™. Change and control the degrees of freedom for the virtual world from within the MATLAB environment by setting values for the available virtual world nodes and their fields usingVRNODEobject methods.

虚拟现实场景可以包含传感器,这些传感器是根据时间,导航以及动作以及场景中的距离变化生成事件和输出值的节点。这些节点为虚拟世界增添了交互性。您可以使用金宝appSimulink 3D动画functions to read sensor field values into simulation models and control simulation based on the user interaction with the virtual scene. You can write an S-function or aMATLAB功能读取传感器输出的块。

Functions

展开全部

vrworld Create newvrworldobject associated with virtual world
vrdrawnow Update virtual world
VRNODE 创建节点或句柄对现有节点
VR.CANVAS 创建虚拟现实画布
vrclear 从内存中删除所有封闭的虚拟世界
vrwho 在记忆中列出虚拟世界
vrwhos List details about virtual worlds in memory
vrfigure 创建虚拟现实图
捕获 Capture virtual reality figure image
close 亲密的虚拟现实人物
得到 Return property value ofvrfigureobject
isvalid Check validity ofvrfigureobject handles
set Set property values ofvrfigureobject
vrgcf Handle for active virtual reality figure
VRGCBF 当前回调vrfigureobject
vrclose 亲密的虚拟现实人物windows
vr.utils.stereo3d Stereoscopic vision settings forVR.CANVASVR.图objects
vrdir2ori Convert viewpoint direction to orientation
vrori2dir 将视点方向转换为方向
vrrotvec 计算两个向量之间的旋转
vrrotmat2vec 将旋转从矩阵转换为轴角表示
vrrotvec2mat 将旋转从轴角转换为矩阵表示
vrifs2patch Convert virtual worldindexedFaceset节点toMATLABpatches
vrpatch2ifs ConvertMATLAB补丁indexedFaceset节点
vrjoystick 创建操纵杆对象
VRSpaceMouse 创建太空鼠标对象

VR源 阅读来自虚拟世界的数据金宝app模型

MATLAB相互作用

Virtual Reality World and Dynamic System Examples

Use virtual worlds that interface to Simulink block diagrams and to MATLAB objects and functions.

为虚拟世界创建vrworld对象

将MATLAB连接到虚拟世界,并通过创建VRWORLD和VRNODE对象通过MATLAB命令行界面与该虚拟世界交互。

用Matlab打开虚拟世界

Open a virtual world to view the virtual world in a virtual world viewer, scan its structure, and change virtual world properties from the MATLAB Command Window.

与MATLAB与虚拟世界互动

Interact with virtual world by using vrnode object methods to set vrworld object property values for all the available virtual world nodes and their fields.

关闭和删除一个vrworld对象

关闭虚拟世界并将其从内存中删除。

虚拟世界数据类型

探索节点用于定义对象的数据类型以及可以出现在节点字段和事件中的数据类型。

VRML传感器输入到模型

使用传感器

基于虚拟世界或虚拟世界中事件的用户输入,在仿真过程中移动或修改虚拟世界对象。

Modify Remote Virtual World Via Sensor Events

Interactive mode allows clients to modify a remote virtual world via events from sensor nodes defined in the virtual world.

检测对象碰撞

使用碰撞检测来避免让两个对象碰撞,或触发虚拟世界对象行为或显示的更改。