https://bugzilla.wikimedia.org/show_bug.cgi?id=35622
--- Comment #2 from Bawolff <bawolff...@gmail.com> 2012-03-31 01:22:26 UTC --- Created attachment 10353 --> https://bugzilla.wikimedia.org/attachment.cgi?id=10353 short gimp script to open an xcf file, merge visible layers, resize, save as a png I think over the long term we should look at using gimp directly. xcf is gimps internal format, and as such its really complicated, so its not surprising that image magick only has cursory support for it. After all imagemagick is more concerned with manipulating formats link png, jpg, etc that are meant for general use. Gimp can be used to scale images with the following command (not sure how efficient this is. Yes I know the command line is scary) gimp -d -i -b '( (lambda ( filename width height ) (let* ((image (car (gimp-file-load RUN-NONINTERACTIVE filename filename))) (drawable (car (gimp-image-get-active-layer image))) (finalfilename (string-append filename ".png")))(gimp-image-merge-visible-layers image CLIP-TO-IMAGE)(set! drawable (car (gimp-image-get-active-layer image)))(gimp-image-scale-full image width height INTERPOLATION-CUBIC)(gimp-file-save RUN-NONINTERACTIVE image drawable finalfilename finalfilename)(gimp-image-delete image))) "/path/to/image.xcf" 320 240 ) (gimp-quit 0)' > /dev/null Which would scale the /path/to/image.xcf to 320x240 pixels (The filename, width and height come at end). I'm attaching a scheme file version of the above command with better spacing. Its possible to have it in a separate file and avoid the insane command line, but i think that's probably not ideal for mediawiki's use case. Anyhow see the docs at http://www.gimp.org/tutorials/Basic_Batch/ -- Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug. You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list Wikibugs-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikibugs-l