| Contents | Index |
Move body in animation object
moveBody(h,idx,translation,rotation)
h.moveBody(idx,translation,rotation)
moveBody(h,idx,translation,rotation) and h.moveBody(idx,translation,rotation) set a new position and attitude for the body specified with the index idx in the animation object h. translation is a 1-by-3 matrix in the aerospace body coordinate system. rotation is a 1-by-3 matrix, in radians, that specifies the rotations about the right-hand x-y-z sequence of coordinate axes. The order of application of the rotation is z-y-x (R-Q-P).
| h | Animation object. |
| translation | 1-by-3 matrix in the aerospace body coordinate system. |
| rotation | 1-by-3 matrix, in radians, that specifies the rotations about the right-hand x-y-z sequence of coordinate axes. |
| idx | Body specified with this index. |
Move the body with the index 1 to position offset from the original by + [0 0 -3] and rotation, rot1.
h = Aero.Animation;
idx1 = h.createBody('pa24-250_orange.ac','Ac3d');
pos1 = h.Bodies{1}.Position;
rot1 = h.Bodies{1}.Rotation;
h.moveBody(1,pos1 + [0 0 -3],rot1);

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |