26

Does Gimp provide a way to export an image at a desirable dimensional size, and still preserve the original size while working in the UI? I need a scaled down version of a file I am currently working on.

Many thanks on any tips or ideas.

1

3 Answers 3

19

GIMP doesn't "provide" such a function, but you can - by paying attention to your workflow.

The easiest way to do that is to not rescale your image until you have saved your work.

When you have finished your work, save it as an XCF file. This file should be considered as your original artwork. Depending on which computer system you use, you could set the file permissions of that XCF file to "Read Only". That way you won't be able to overwrite it accidentally.

Next, with the XCF file open, rescale the document to the required dimensions. Then export as JPEG or PNG (or whatever format you want).

Finally, close the XCF file without saving. The original won't be overwritten, and when you open the XCF, it will be the original size that you saved it at.

1
2

I found a method I really like. I export to a filename like logo400.png, and this script automatically makes that png 400 pixels wide. This makes it easy to export to multiple widths.

while true; do
   sleep 3
   for file in *.png; do
      currentwidth=`identify -format '%w' "$file"`
      newwidth=`echo "$file" | egrep -o "\d*\.png$" | egrep -o "\d*"`
      if [[ -n $newwidth && $currentwidth != $newwidth ]]; then
         echo "Scaling $file"
         cp "$file" "${file%.png}-beforeScaling.png"
         magick "$file" -scale "$newwidth" "$file"
      fi
   done
done

The script requires ImageMagick, which you can download with brew install imagemagick, apt install imagemagick, or the equivalent.

You have to run the script in the folder where the image is.

1

After extensive research, I like using the Buffer feature in Gimp to save each version of our design, into various image sizes (as a buffer). IMHO this is perhaps the best "manual" way to go in regards to prepping and exporting out each size, without depending on any third-party tools or coding.

  • Open your image or photo in Gimp
  • Go to Windows -> Dockable Dialogs -> Buffer, to open the Buffer Panel

Scale Down - Copy Named - Repeat

Repeat this three-step process for every thumb-x image you need.

  • Scale your initial image down. My first size was scaled down to 200x317 pixels.
  • Go to Edit -> Buffer -> Copy Named, to name it something like thumb-200x317.
  • You'll then see your image in the Buffer panel.

Prep for exporting

  • From this point right click over any of your buffer items to see multiple options :) I can Paste Buffer as new layer or as a new image. Then go to Image -> Crop to content and export the image, then repeat.

  • I can Ctrl-Z back in time to my original sized image and still see all my buffer items in my buffer panel. Very nice!

I recommend this because I really like how I can see multiple sizes of my "Buffered" image in a Buffer panel without clogging up my layers panel. Having right click options for each buffer item is a plus!

We just need the ability to export Buffer to make this perfect!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.