Filter löschen
Filter löschen

Animation in matlab

3 Ansichten (letzte 30 Tage)
Abhishek
Abhishek am 27 Feb. 2012
Kommentiert: Image Analyst am 13 Jan. 2015
I have an assignment to do which includes animation a stick man (stick figure) such that it can move its hands and legs and possibly also change the colour of it face. Is there a possibility to do this? Thanks for any help to be provided.

Akzeptierte Antwort

Sean de Wolski
Sean de Wolski am 27 Feb. 2012
Yes. Create a bunch of lines using line(). Then modify their xdata and ydata properties to reflect new positions. You could do this with a for-loop and a pause() or even better with a timer().
  6 Kommentare
Abhishek
Abhishek am 28 Feb. 2012
thank you vey much much appreciate your help and guidance.
Image Analyst
Image Analyst am 13 Jan. 2015
In R2014b there is an animatedLine function:
Create an animated line with two initial points.
x = [1 2];
y = [1 2];
h = animatedline(x,y);
Add points to the line in a loop to create an animation of a growing line. See Using animatedline Objects for more information.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Animation finden Sie in Help Center und File Exchange

Tags

Produkte

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by