views:

1205

answers:

2

If I have an XCF file (or any other supported by Gimp) how can I convert it to, for example, PNG for display or further processing?

+1  A: 

I guess ImageMagick should do what you want (and even more)

convert image.xcf image.png
jassuncao
From my experience, current versions of ImageMagick have very buggy support for XCF. Various layer sizes cause the resulting image to be completely black. I also experience alpha channel bugs (solid pixels appearing from nowhere).
Sam Hocevar
+1  A: 

Very few, if any, programs other than GIMP read XCF files. This is by design from the GIMP developers, the format is not really documented or supported as a general-purpose file format.

That being said, look into using GIMP itself, using command line arguments (especially the --batch option).

EDIT: It looks as if ImageMagick does support XCF, so that is probably an easier route if the support seem so be good enough. I haven't tested it, and the documentation doesn't say much. I would be a bit wary.

unwind
Looks like imagemagick's convert works. I would prefer using GIMP since it surely supports its own format better, and also supports other formats. I have tried looking into GIMP from shell but it's a bit unintuitive. Can you perhaps drop an example or two on converting with GIMP,or a link with docs?
Ivan Vučica