Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
I have a sequence of .pngs, which comprise a blue background with an actor somewhere in the middle. I want to make this into a compact .gif, showing just the actor. I'm using this command line :
Which is almost perfect, but for one problem. Each frame of the gif that is smaller than the gif itself, is filled with a black background. How can I fill that with a plain background colour of my choice?
I bring pictures.
How do I deal with the black blocks? They vex me so.
fmw42 wrote:perhaps you need to trim twice (with -fuzz XX%), once for the white and once for the black. and do a -layers optimize
Wait, no.
First, the white is an artifact of the screengrab, I'm not worried about that.
I followed your advice, and it works if I use '-background blue' or '-background red'. Any other colour leaves horrible black trails as the animation changes size. Still, it's a lead.
You will need to upload to some free image hosting service such as dropbox and then put links to them here. There is no direct image upload in this forum
I am not an expert on animation disposal, but I am not sure you can change the background for -dispose background. I think you need to add a frame at the beginning with -dispose none -delay 0 and then process your images with -dispose previous. The problem with that approach is that you use -trim and that will trim the whole first image away.