matroosje wrote: ↑2017-02-22T07:42:32-07:00I tried using -delete, but it only works with numbers I think, not with a layer that has a name 'paspartout'. (It's the last layer that has been added, so sometimes it's the 6th, sometimes the 13th.)
You shouldn't have to know any layer names. As long as you're certain the layer you want to eliminate is the last in every case, "convert" or "mogrify" should be able to handle it easily. I've tried using "+delete", as
snibgo mentioned above, and "-delete -1" to delete the last layer after the PSD is read in. Both seem to work. Something like this should do it...
Code: Select all
mogrify -delete -1 -format png *.psd
I've also tried reading in the PSD file all except the last layer. That's done by including the index or range of indexes of the layers you want in square brackets appended to the input file name. The command would look like this...
Those commands work for me from a Windows x64 command prompt using either IM 6.9.7 or IM 7.0.5 to test some PhotoShop Elements and PhotoShop CS2 files.