

The syntax for cropping is as ~]$ mogrify -crop ” etc with the values you got from GIMP. Well then, let’s start with the mogrify command. Note that I strongly recommend having only the images that are to be cropped in the directory, nothing more. Open up your favourite one and cd to the directory where the images are located. Let’s go on and write a line that’ll execute mogrify in such a way that it’ll crop all our images! Close GIMP (or leave it open if you plan to use it again soon).We now have the values we need to tell the mogrify utility what to crop.

Note the X, Y, Width and Height values GIMP gives you (have a look at the picture, you can find them in the GIMP main window).5. Using the Rectangle Select Tool (hotkey “R”), select the area you want to be cropped.4. Let’s start with the selecting: Getting the right cropping values using GIMP We’ll use GIMP to graphically select the area to be cropped and the mogrify tool to automate the cropping, saving us a lot of work. Some actions in this tutorial will overwrite the image files, so if you make a mistake you may lose valuable data.This tutorial assumes basic Linux knowledge, like starting a program, opening a terminal and working with a terminal.The tools we’ll be using are GIMP and mogrify (from the ImageMagick suite), so make sure that you have them installed. This short tutorial describes an efficient way to do this for a theoretically infinite amount of images.Difficulty: Basic – Medium Note: I strongly recommend making a backup of the images you’re using for this tutorial before messing with them. Of course, you could fire up your favourite image editor to select and crop over and over, but, as usual, there is a better way. It took me less than 2 minutes to get a really clean cutout of this lemon.Sometimes you’ll want to crop the same area from multiple images (think of taking the contents of the same window from a load of screenshots). Eventually, you'll be able to do this really quickly. You can play around with how close you need to get to have a nice selection. In the screenshot below, you can see that I left a margin of "unknown" but shaded in the foreground very close to the edges. Use small brush strokes and undo if you make mistakesĬhange the "Stroke width" to cover more or less pixels at a timeĬhoose "Draw unknown" if you accidentally go over the edge and want GIMP to figure out which pixels to selectĬhoose "Draw background" if you want to get closer to the outside edge This controls the gradual transition from opaque to transparent at the edges, which will become visible once we take away the backgroundĬhoose "Draw foreground" to paint in the inside of the object.ĭon't get too close to the edge, GIMP will automatically select your edge based on similar colored pixels
How to crop in gimp free#
(In my case, I chose 8, but again, it doesn't have to be perfect and feel free to experiment) Make sure "Feather edges" is selected and set Radius to the number you chose earlier. Take a look at the Foreground Select Tool Options tab in the lower left panel of the screen. Lighter blue on the inside indicates Unknown.Īs you draw foreground, the clear portions will indicate the Foreground. If you try to do it all in one stroke, it's a lot harder.ĭark blue around the outside indicates the Background.

When you're painting on an image, it's often easier to do lots of short strokes and undo a stroke if you mess up (Ctrl + Z). Some operations require multiple steps and you have to press the Enter key to proceed (or the Esc key to exit). A particularly helpful tool is if you zoom too far in. Get familiar with the Zoom tools under and also the magnifying glass icon in the upper-left toolbox, which will allow you to draw a box and then zoom in on that area. Here are a few tips that will probably be helpful. I would recommend you search YouTube for some beginner tutorials if you get stuck somewhere in these steps. To change this, in the top toolbar of GIMP, go to "Windows" and select "Single-Window Mode" from the dropdown menu. On Linux, for example, GIMP defaults to 3 separate floating panels over top of whatever is behind it. The screenshots in this tutorial are using GIMP in Single-Window Mode, which may look different than what GIMP does by default on your system.

How to crop in gimp download#
You can download it from (Optional) Configure GIMP Window Mode GIMP is a cross-platform, free, open source, image editing tool.
