user1870101
user1870101

Reputation: 21

Converting PSD file to JPG using graphic magick

I 'm trying to convert psd file to jpg format file by using following commands:

gm -convert [input file name].psd -colorspace rgb -resize 150x150  -strip -quality 92 -   sharpen 2  [output file name].jpg

gm -convert -clip -negate  [input file name].psd -thumbnail 150x150     [output file name].jpg

Both the commands are working fine.But for some psd file having rgb colorspace it does not generate correct rendition.

Any suggestions??

Upvotes: 2

Views: 1464

Answers (3)

shiny
shiny

Reputation: 21

Have you tried ImageMagickImageMagick has the same command-line, but also have a thumbnail of PSD, get by this:

convert a.psd[0] b.jpg 

Upvotes: 2

kartsims
kartsims

Reputation: 1008

I have just created a Node module that deals with PSD files from the CLI.

For all non-Windows users out there that don't want to crack Photoshop just to see a proper rendered file (Gimp is not really a solution and has a poor understanding of modern PSD files).

Instructions from the Github repo :

Install it :

npm install -g psd-cli

Convert myfile.psd to a new myfile.png :

psd myfile.psd

Hope you find this useful ! Any feature requests is most enjoyed, I have a ton in mind and help with improving the code is appreciated :)

Upvotes: 0

Bob Friesenhahn
Bob Friesenhahn

Reputation: 306

The PSD reader in GraphicsMagick is not very robust and PSD is very complex and poorly documented. The best free implementation I have seen is in The GIMP.

Upvotes: 0

Related Questions