Doug's MATLAB Video Tutorials

February 2nd, 2011

Animating an objects trajectory in MATLAB with HGtransform

This video shows how you can use MATLAB to do the visualization of a moving object with HGtransform. This data was syntetic, but it would be easy to read the data from a file and show the trajectory of other items or vehicles.

2 Responses to “Animating an objects trajectory in MATLAB with HGtransform”

  1. Steffen replied on :

    Hi Dough,

    Some time back I posted ‘Animated Peaks and Spheres’ on the file exchange. This might be worthwhile having a look at also for people interested in simple animation.

    Steffen

  2. Graham replied on :

    Doug, Thanks this is great! Just the thing I was looking for to make a simple animation of a car pitching, rolling, and heaving. I’ve tried adding the path to the same axes using plot3 for another visual, and it works, but a major memory hog. I thought of using the movie command to try and save the animation for later play back but having trouble with that too. Do you have any suggestions for including the path?
    Thanks!
    -Graham

Leave a Reply

Wrap code fragments inside <pre> tags, like this:

<pre class="code">
a = magic(3);
sum(a)
</pre>

If you have a "<" character in your code, either follow it with a space or replace it with "&lt;" (including the semicolon).


MathWorks

Doug Hull is a proud MathWorker who is on a mission to help you with MATLAB.

Doug's picture

These postings are the author's and don't necessarily represent the opinions of The MathWorks.