2015-04-23 41 views

risposta

7

Essi sono GIF animate, il primo con sfondo trasparente. È possibile separare l'immagine in singoli fotogrammi con ImageMagick (installato sulla maggior parte delle distribuzioni Linux e disponibile gratuitamente per OSX e Linux) in questo modo:

convert -coalesce type1.gif frame%02d.gif 

che vi darà i seguenti 18 fotogrammi come immagini singole

frame00.gif frame04.gif frame08.gif frame12.gif frame16.gif 
frame01.gif frame05.gif frame09.gif frame13.gif frame17.gif 
frame02.gif frame06.gif frame10.gif frame14.gif 
frame03.gif frame07.gif frame11.gif frame15.gif 

frame00.gif

enter image description here

È c una vederli tutti in una volta, se li fanno in un montaggio come questo:

convert -coalesce type1.gif miff:- | montage -tile x4 -frame 5 - montage.gif 

enter image description here

si possono trovare informazioni su ogni fotogramma, come ad esempio la sua dimensione in questo modo:

identify type1.gif 

type1.gif[0] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[1] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[2] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[3] GIF 100x100 100x100+0+0 8-bit sRGB 64c 29.2KB 0.000u 0:00.000 
type1.gif[4] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[5] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[6] GIF 100x100 100x100+0+0 8-bit sRGB 64c 29.2KB 0.000u 0:00.000 
type1.gif[7] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[8] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[9] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[10] GIF 100x100 100x100+0+0 8-bit sRGB 64c 29.2KB 0.000u 0:00.000 
type1.gif[11] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[12] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[13] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[14] GIF 100x100 100x100+0+0 8-bit sRGB 64c 29.2KB 0.000u 0:00.000 
type1.gif[15] GIF 100x100 100x100+0+0 8-bit sRGB 64c 29.2KB 0.000u 0:00.000 
type1.gif[16] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 
type1.gif[17] GIF 100x100 100x100+0+0 8-bit sRGB 128c 29.2KB 0.000u 0:00.000 

È possibile inserire tutti i fotogrammi di nuovo insieme in questo modo:

convert frame* -loop 0 -delay 20 anim.gif 

enter image description here

È possibile provare e rimuovere lo sfondo nero dal secondo per renderlo più simile al primo, utilizzando un comando come questo.Potrebbe essere necessario armeggiare con il fattore fuzz un po ':

convert type2.gif -fuzz 15% -transparent black new.gif 

enter image description here

Problemi correlati