resize animate gif with coalesce

The MagickWand interface is a new high-level C API interface to ImageMagick core methods. We discourage the use of the core methods and encourage the use of this API instead. Post MagickWand questions, bug reports, and suggestions to this forum.
Post Reply
gigimon

resize animate gif with coalesce

Post by gigimon »

Hello

When I'm use convert via shell,
convert -coalesce -resize 100x50 box.gif box2.gif

animated GIF with transparence resize normal, but if I'm use via MagickWand (in Python) this code:

from PythonMagickWand import *
MagickWandGenesis()
wand = NewMagickWand()
MagickReadImage(wand, 'd:/box.gif')
MagickSetLastIterator(wand)
length = MagickGetIteratorIndex(wand)
MagickSetFirstIterator(wand)
for i in range(0, length+1):
MagickSetIteratorIndex(wand,i)
MagickAdaptiveResizeImage(wand, 87, 56)
MagickCoalesceImages(wand)
MagickWriteImages(wand, 'd:/boxtest1.gif', 1)


I'm get bad frames (many black and white dots).
How true use coalesce in wand?
Post Reply