图像失去了想象力的透明度?

This is my first time fiddling with imagick/dynamic images. All of my images used for the layers to build an image are transparent PNG files. However, when compressing the images into one image via imagick for some reason the transparency is lost, resulting in a white background and white wherever it should be transparent. Is this a normal problem, and is there a way to fix it? Here is my section right after I list the images to use;

$composed_image = new \Imagick($images);
$image = $composed_image->mergeImageLayers(\Imagick::LAYERMETHOD_FLATTEN);
$image->setImageFormat('png');
header('Content-type: image/png');
echo $image->getImageBlob();