Animations in Live Scripts

조회 수: 35 (최근 30일)
Michael
Michael 2023년 5월 4일
댓글: Michael 2023년 5월 4일
Hello,
I have an animation in a live script and it works fine.
For presentations I want to open the animation in a seperate figure window using the Open in figure window button, but the result is only the final plot without the play button, the position slider and so on, so I am unable to start the animation or to move to a certain time.
How can get the animation running in the fikgure window?
Michael

채택된 답변

Cris LaPierre
Cris LaPierre 2023년 5월 4일
The replay option is a feature of live scripts, and is not avaiable in external figure windows. This was introduced in R2021a.
  댓글 수: 2
Cris LaPierre
Cris LaPierre 2023년 5월 4일
편집: Cris LaPierre 2023년 5월 4일
As an alternative, you can use the Export Animation button to export your animation to an MP4 (up to 1000 frames). Then you could step through the video, jump to specific times, etc.
If your animation contains more than 1000 frames, consider creating the movie yourself using getframe and VideoWriter (see here).
Here is another example as well.
Michael
Michael 2023년 5월 4일
Thank you for pointing out that replay is only available in a live script.
I know (and used) the export function, but the resolution of the resulting video is really poor aand I see no way to select the resoltion of the video. So I will use VideoWriter.
Michael

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Animation에 대해 자세히 알아보기

제품


릴리스

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by