I\'m using ImageMagick to extract layers from a PSD, and it gets them all out fine with:
convert image.psd image-%d.png
But the resulting PNG i
Type this to extract the layer number 2 from a PSD file:
convert \
<filename>.psd[0] \
<filename>.psd[2] \
\( \
-clone 0 \
-alpha transparent \
\) \
-swap 0 \
+delete \
-coalesce \
-compose src-over \
-composite \
<extracted-filename>.png
This creates first a transparent canvas with the same size of the PSD file, then combines it with the layer 2 keeping it's original layout (-coalesce
)
I use this command line to do what are describing:
convert.exe <filename>.psd -set dispose Background -coalesce <outfilename>.png