Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How do I crop by values?
#1
Hi!
I would like to crop an image by entering the values in the crop dialog box.
The values I'm looking for is Position X/Position Y and Size X and Size Y.
These values describing the cropping area and should be enough but:

- when I try to enter values in the corresponding fields, my image is zooming. Regardless if I use the NumPad or the normal numbers. I'm not able to input the numbers.
  What is the way to enter the value fields and be able to put numbers in it? 

- when I was able to somehow enter those numbers I can't see a way to execute the crop. When I click in the image, it will reset these values.
  How do I actually initiate the crop after I entered the values?

All the tutorials in the net show the interactive way to crop but I could not find any that shows how to do it just by numbers.

Thanks for any suggestion.
Reply
#2
(Yesterday, 11:32 AM)Steve_k2400 Wrote: Hi!
I would like to crop an image by entering the values in the crop dialog box.
The values I'm looking for is Position X/Position Y and Size X and Size Y.
These values describing the cropping area and should be enough but:

- when I try to enter values in the corresponding fields, my image is zooming. Regardless if I use the NumPad or the normal numbers. I'm not able to input the numbers.
  What is the way to enter the value fields and be able to put numbers in it? 

- when I was able to somehow enter those numbers I can't see a way to execute the crop. When I click in the image, it will reset these values.
  How do I actually initiate the crop after I entered the values?

All the tutorials in the net show the interactive way to crop but I could not find any that shows how to do it just by numbers.

Thanks for any suggestion.

quote- when I was able to somehow enter those numbers I can't see a way to execute the crop. When I click in the image, it will reset these values.
How do I actually initiate the crop after I entered the values?

I think that is your problem, you have not actually initiated a crop. You can set a fixed size in the dialogue, and you get that when you click in the canvas, but you still have to set the origin, thus.....

I can only describe how I procede.
Using the crop tool, draw the crop area (any old area) in the canvas.

Now using the dialogue, 
Set Delete cropped pixels
Next to position set px (pixels) This could be your problem if set to say percentage
Enter the position, which is the top left corner and the size. 
Enter the size, again make sure px is set  against size and enter the size for each side. Hit enter to fix.

Then to apply the crop, click on the canvas inside the crop area.

This a 50 second example: https://i.imgur.com/vOKjTT1.mp4 Hope it helps.
Reply
#3
I rarely use crop but I notice it has a 'landscape' or 'portrait' setting that is a function of aspect ratio. The numbers are the height and width of the active image. If fixed size is selected you can edit the aspect ratio numbers.
Reply
#4
(Yesterday, 12:30 PM)rich2005 Wrote:
(Yesterday, 11:32 AM)Steve_k2400 Wrote: Hi!
I would like to crop an image by entering the values in the crop dialog box.
The values I'm looking for is Position X/Position Y and Size X and Size Y.
These values describing the cropping area and should be enough but:

- when I try to enter values in the corresponding fields, my image is zooming. Regardless if I use the NumPad or the normal numbers. I'm not able to input the numbers.
  What is the way to enter the value fields and be able to put numbers in it? 

- when I was able to somehow enter those numbers I can't see a way to execute the crop. When I click in the image, it will reset these values.
  How do I actually initiate the crop after I entered the values?

All the tutorials in the net show the interactive way to crop but I could not find any that shows how to do it just by numbers.

Thanks for any suggestion.

quote- when I was able to somehow enter those numbers I can't see a way to execute the crop. When I click in the image, it will reset these values.
 How do I actually initiate the crop after I entered the values?
 
I think that is your problem, you have not actually initiated a crop.  You can set a fixed size in the dialogue, and you get that when you click in the canvas, but you still have to set the origin, thus.....

I can only describe how I procede.
Using the crop tool, draw the crop area (any old area) in the canvas.

Now using the dialogue, 
Set Delete cropped pixels
Next to position set px (pixels) This could be your problem if set to say percentage
Enter the position, which is the top left corner and the size. 
Enter the size, again make sure px is set  against size and enter the size for each side. Hit enter to fix.

Then to apply the crop, click on the canvas inside the crop area.

This a 50 second example: https://i.imgur.com/vOKjTT1.mp4   Hope it helps.


Thank you for your detailed answer and the video!
In deed it was my mistake that I did not initiated the crop function.

I assumed that I can simply edit the parameters and that is enough to initiate the function.
This is what makes Gimp so unintuitive to use. 99% of the UI is there but that one percent is missing.
A simple "Go/Apply/Nuke/Whatever" button in the function would be enough to replace the the mouse initialisation. 
Especially as with the required mouse initialisation, all the previously entered numbers are cleared, so there is no repeatability in the function.
Gimp has a great underlying code but the interface is still (after how many decades) trailing far behind.

Anyway, many thanks for your help!

 
Reply
#5
Steve_k2400, can you recommend a completely free graphics program that has the same capabilities as Gimp and is easier to use? I would love to hear what you are currently using. Thanks in advance.
Reply
#6
(11 hours ago)denzjos Wrote: Steve_k2400, can you recommend a completely free graphics program that has the same capabilities as Gimp and is easier to use? I would love to hear what you are currently using. Thanks in advance.

First of all just to make sure, I'm not disrespectful towards the developers. 

Over the years many people have complained that the Gimp Interface is not intuitive enough. A simple search reveals many of those conversations.
The response of the developers were most of the time rather dismissing which is their right to do. The general consensus is: if you don't like it, don't use it.
So, even constructive critic regarding the UI is not really welcomed.

But the UI is a major part of a software and what sense does it make to develop a software that requires the user to think "differently" when using it?
As I stated before, under the hood is Gimp one of the best image editors. But the hood is dented and rusty and that makes no sense to me. 
The developers surely would like to see more people using it, why is there then no effort to make the interface correspond to generally accepted UI guidelines?

And just to answer you question: another free image editor is Krita and in Krita the crop function works just as logically as I would await. 
Set Crop Origin/Width/Height and press "Crop". Done. No mouse interaction is needed.
This is how a logical thinking person would await it and what is missing from Gimp is that "Crop" button.
Is it a crime to mention this?

I guess your next reply would be: then use Krita.
Sure, but I do prefer that Gimp V8 under the Hood... 

I'm also a Blender user (a free animation software) where the Blender Foundation is making a huge effort to make the UI as logical and user friendly as possible. 
Even my crazy expensive work software (Alias AutoStudio) is completely overhauled it's 20 years old Interface because the critique was loud enough.
I develop a complex Blender Add-On for the users in our Studio in my free time. I'm not a programmer but even I take care of the critique from the users of my program. 
So, complaining about the UI is not lowering the developer's merits. It's just a friendly hint that maybe it's worth a second look.

Anyway, I'm very thankful for the help I got here and I apologize if my text above eventually offended someone.
Reply
#7
(8 hours ago)Steve_k2400 Wrote: ...snip...
First of all just to make sure, I'm not disrespectful towards the developers. 

Over the years many people have complained that the Gimp Interface is not intuitive enough. A simple search reveals many of those conversations.
The response of the developers were most of the time rather dismissing which is their right to do. The general consensus is: if you don't like it, don't use it.
So, even constructive critic regarding the UI is not really welcomed.  

I do not think that is quite true, "many people complaining", tends to be a vocal few who come to Gimp from some other editor and want Gimp to change to resemble "other editor". Tends to be in forums like Reddit where people like an argument. The majority of users are not bothered one-way-or-another.

You can always post a feature request to the developers: https://gitlab.gnome.org/GNOME/gimp/-/issues There used to be a developer for the UI (back in Gimp 2.6 days) not sure about now.

If Gimp had a macro function you could record a few key strokes for your crop. Unfortunately we are stuck with script-fu.  A little script attached, If you want to try it, unzip and put crop-it.scm in your user scripts folder.

   


Attached Files
.zip   crop-it.zip (Size: 547 bytes / Downloads: 2)
Reply
#8
The problem with not using the on-canvas crop is determining what the result looks like Wink
Just to show I am not a complete dinosaur, you can use GEGL - Filters -> Generic -> GEGL graph and make a preset such as
Code:
crop
x=1
y=1
width=100
height=100

Works like this: https://i.imgur.com/mo1VzhH.mp4
Reply
#9
(2 hours ago)rich2005 Wrote: The problem with not using the on-canvas crop is determining what the result looks like Wink
Just to show I am not a complete dinosaur, you can use GEGL      -     Filters  -> Generic -> GEGL graph and make a preset such as
Code:
crop
x=1
y=1
width=100
height=100

Works like this: https://i.imgur.com/mo1VzhH.mp4


I was thinking about scripting but it is not the same crop on all images, so I did not follow on that.

That GEGL solution is very cool  Cool  , I didn't know that. 
But its a bit like scratching your left ear over your head with the right hand... Wink a simple crop button would be much easier.
(In Krita if you start entering values, the cropping is shown on the image, so you see exactly what the results will look like.)

In the company I'm working for we have to request Photoshop and due to its cost it is only granted for a REALLY good reason. 
Everytime I mention Gimp to my workmates as a great alternative, there is this face expression... You know that stinky cheese expression. 
When I ask them why, the answer is everytime the usability. For me that tells the whole story.

3.0 brought a lot of UI improvements and I hope there will be more to close the gap to other paint software. 


I really appreciate your answers as it shows that it's not even a V8 under the hood but rather a V12. 
If one takes the time to get used to it, it's really a powerful software!
Reply
#10
(2 hours ago)Steve_k2400 Wrote: ...snip...
I was thinking about scripting but it is not the same crop on all images, so I did not follow on that.
...snip...

That little script-fu I posted does allow you to change the parameters just the same as in the crop tool options.

It is basically a one liner, a sort-of shell I use for a quick menu entry.

Early days for g\imp 3 but there is https://docs.gimp.org/3.0/en/gimp-scripting.html as a starter
Reply


Forum Jump: