Why should they be MagickSetImageIndex fuzzy picture
Posted: 2007-08-05T03:50:23-07:00
Source map
![Image](http://aiqiutian.cn/upload_files/20.gif)
The first frame
![Image](http://aiqiutian.cn/upload_files/0.gif)
The second frame
![Image](http://aiqiutian.cn/upload_files/1.gif)
The result is how this should be
The first frame
![Image](http://aiqiutian.cn/upload_files/30.gif)
The second frame
![Image](http://aiqiutian.cn/upload_files/40.gif)
$nmw =NewMagickWand();
MagickReadImage($nmw,'20.gif');
$index=MagickGetImageIndex($nmw);
MagickSetImageIndex($nmw,0);
$cc =MagickGetImage($nmw);
for($i=0;$i<=$index;$i++)
{
$a =MagickGetImage($nmw);
//$a=MagickAppendImages($cc);
MagickSetFormat($a,'gif');
MagickWriteImages($a,$i.".gif",MagickTrue);
}
![Image](http://aiqiutian.cn/upload_files/20.gif)
The first frame
![Image](http://aiqiutian.cn/upload_files/0.gif)
The second frame
![Image](http://aiqiutian.cn/upload_files/1.gif)
The result is how this should be
The first frame
![Image](http://aiqiutian.cn/upload_files/30.gif)
The second frame
![Image](http://aiqiutian.cn/upload_files/40.gif)
$nmw =NewMagickWand();
MagickReadImage($nmw,'20.gif');
$index=MagickGetImageIndex($nmw);
MagickSetImageIndex($nmw,0);
$cc =MagickGetImage($nmw);
for($i=0;$i<=$index;$i++)
{
$a =MagickGetImage($nmw);
//$a=MagickAppendImages($cc);
MagickSetFormat($a,'gif');
MagickWriteImages($a,$i.".gif",MagickTrue);
}