If you're looking for a solution to fill the image with a solid color, preserving background transparency, here is one way:<?php$im = new Imagick('image.png');$im->setImageAlphaChannel(Imagick::ALPHACHANNEL_EXTRACT);$im->setImageBackgroundColor('color');$im->setImageAlphaChannel(Imagick::ALPHACHANNEL_SHAPE);$im->writeImage('output.png');$im->destroy();?>