Why does 'imwrite' not preserve transparency in animated GIFs?
9 views (last 30 days)
Show older comments
MathWorks Support Team
on 18 Jan 2019
Answered: MathWorks Support Team
on 21 Mar 2019
When creating an animated GIF using the 'imwrite' function, previous frames are not cleared. How do I clear them?
Accepted Answer
MathWorks Support Team
on 18 Jan 2019
To make sure that previous frames are cleared, set pass the Option-Value pair ('DisposalMethod','restoreBG') to the 'imwrite' function.
An example with a reproduction of the issue and a solution is shown in the attached script.
0 Comments
More Answers (0)
See Also
Categories
Find more on Animation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!