Crop Tool Bug

B
Posted By
BillH
Apr 22, 2004
Views
498
Replies
16
Status
Closed
I apologize if this has been discussed before, I searched and couldn’t find any similar topics.

Anyway, the crop tool seems to have a bug that causes the dimensions specified in the width and height boxes to behave oddly.

Here’s how to replicate it:
(note: i’m using pixels as units)
(to my knowledge this bug exists in PS7 and CS)

1. Open up any image (preferably not too small of one) and select the crop tool.

2. Type in any value in the width box (say 245) but leave the height box blank. (If you were to crop now, the image would be sized to the width you specified (245) and the height would be based on the original image proportions)

3. Save that setting in your crop tool presets.

4. Select the preset you just made.
(At this point the crop tool should still work as expected.)

5. Now type in a different value for the width (say 300), still leaving the height box blank. (Here is the bug: when you try and crop now, it constrains the height to what was the old width value (although sometimes it just gives the height a seemingly random value). The height box will remain blank, but if you crop and then check the image dimensions you’ll see your old width value is now the height. (if you used the same values as me, you’ll get an image 300 x 245))

Now, a slight problem is that I can’t always get this bug to appear, but usually if you repeat steps 4 – 5 a few times, selecting different crop presets, the bug appears.

Can anyone else reproduce this?

Master Retouching Hair

Learn how to rescue details, remove flyaways, add volume, and enhance the definition of hair in any photo. We break down every tool and technique in Photoshop to get picture-perfect hair, every time.

GA
George_Austin
Apr 23, 2004
BillH,

"…2. Type in any value in the width box (say 245) but leave the height box blank. (If you were to crop now, the image would be sized to the width you specified (245) and the height would be based on the original image proportions)…"

When the units are PIXELS, and the height and resolution are left blank, the resolution of the cropped output is the same as the original resolution, and the height is determined NOT BY THE ORIGINAL IMAGE PROPORTIONS, but by the proportions of the contour which you drag out with the crop tool. The output will then always have a fixed width in inches given by the specified crop width in pixels divided by the original resolution in pixels per inch. The cropped output’s height will be the cropped width times the aspect ratio of the contour you drew expressed as the height to width ratio of that contour—again, NOT the aspect ratio of the original image.

Be aware that the rules change if you specify crop dimensions in inches rather than pixels. In that case resolution is NOT preserved. What is preserved is the number of pixels within the crop contour. There is no resampling. You keep all the original pixels within that contour and you do not fabricate any new ones by interpolation. The size of the individual pixels changes. It’s a different ballgame than when you specify pixels for the units.

George
MM
Mac_McDougald
Apr 23, 2004
Resolution is not preserved using pixel settings in crop tool either. Otherwise it would not be adjustable crop frame.

Image is either downsampled or upsampled (usually the latter) to fit the area you select into the pixel dimensions you select.

The rectangular marquee too DOES preserve resolution, in that it will grab only actual original pixels that you specify (note that the box is not adjustable, only moveable).

Also, original pixels are not retained using inch settings either with crop tool.

The only way to NOT resample with crop tool is either:
– don’t specify anything, just crop
– put in inch/pixel settings that exactly already match at least one dimension of the crop you will actually make (unlikely).

Mac
B
BillH
Apr 23, 2004
George,

That’s all well and good, but doesn’t really address the bug I was talking about.
GA
George_Austin
Apr 23, 2004
Mac, We must have different machines—or, perhaps you’re from an alien planet? 🙂

BillH, To pursue the alleged "bug" let’s start with an understandable scenario. When you "crop" are you dragging the crop tool contour from corner to corner of the entire image, which you seem to be doing, or are you more conventionally dragging out a rectangle that is smaller than the original?

George
B
BillH
Apr 23, 2004
George,

You are using the crop tool to drag out a rectangle smaller then the original image.

If you follow the steps I outlined, you should come across the bug.

Maybe I can be more clear, try this:

1. Pick the crop tool and set the width to 300px, leave the height blank, and set the resolution to 72px/inch.
(Don’t crop the image right now, but if you did, the crop tool will crop to 300px, and the height will remain variable.)

2. Save this setting as a preset.

3. Change your crop tool settings by selecting a different preset then the one you just made.

4. Select the "300px X ?" preset you just made.

5. Change the 300px in the width box to another value…say 200px, leave the height blank and the resolution at 72px/inch

6. If you try and crop now, you’ll see that the height is fixed (as if you typed in a value into the height box) when it should remain variable.
MM
Mac_McDougald
Apr 23, 2004
Specifiying either pixels OR inches, you are resampling with the crop tool, pretty much guaranteed.

Unless in the HIGHLY unlikey event with pixel dimensions set, you actually happen to pick EXACTLY the same number of original pixels in the image, or using inches, you go all the way to one edge with same dimension set as the original.

I’m not even commenting on "the bug". That was such a complicated scenario I didn’t even work through it. Was only commenting on your statements that you can use the crop tool with dimensions specified without resampling (or so it seems to me).

Mac
MM
Mac_McDougald
Apr 23, 2004
First of all, even though I still don’t see "the bug", it would be helpful to forget about ppi here if working strictly with pixel dimension settings; this will remove one confusing, and unnecessary, setting.

A 300×200 pixel image is the same "rez" whether tagged at 72 or 7200ppi., same number of pixels, same pixel dimensions.

You can set ppi easily for print output in another dialogue if you need to.

Of course, if you are doing all this for web output (as I assume you must be, if you are thinking pixel dimensions), then ppi won’t come into play at all anyway, doesn’t matter, fuggetaboudit.

Mac
GA
George_Austin
Apr 23, 2004
Mac,

On the crop tool option bar, leave the resolution box BLANK.

With the resolution box blank, if you specify dimensions in INCHES, there will be NO RESAMPLING.

With the resolution box blank, if you specify dimensions in PIXELS, there will be resampling.

George
GA
George_Austin
Apr 23, 2004
BillH,

If your crop tool is not outlining the entire image ( BTW using the entire image is not something I would do but it is not a totally absurd use of the crop tool if you’re looking for an alternative way to resize), then the original image proportions (aspect ratio) have no bearing whatsoever on the final cropped dimensions. Since this contradicts your statement in Step 2 of your initial post, I thought it would be prudent to get the basics straightened out.

I see that you are also specifying a resolution rather than leaving the resolution box blank. I’ll get back to this in a day or so and will follow your routine to see what happens with width specified in pixels, height left blank, resolution fixed (at 72ppi), and the image partially outlined by the crop tool contour.

George
B
BillH
Apr 23, 2004
Just a side note:

Specifying the resolution doesn’t seem to have an effect on the appearance of the bug, I’ve had it appear both with resolution set at nothing and 72ppi.
GA
George_Austin
Apr 23, 2004
BillH,

I took a quick look—without time to ponder why—and I confirm your weird result. A fixed crop height not of my choosing comes up. Damn it! When I go to that dinner party tonight I’m going to be preoccupied. Maybe a stiff drink will mute my subconcious which now seems to have your attention.

George
B
BillH
Apr 23, 2004
I knew I wasn’t crazy!

I’ve been trying to figure out where photoshop pulls that height value from.

Sometimes its the ‘old’ value for the width, and other times its a seemingly random value.
MM
Mac_McDougald
Apr 23, 2004
With the resolution box blank, if you specify dimensions in INCHES, there will be NO RESAMPLING.

With the resolution box blank, if you specify dimensions in PIXELS, there will be resampling.

Oh..okay…correct.

If I implied differently than this, I was on a tangent or hadn’t read closely enough.

Thought I kept seeing both of you going on premise of having a ppi specified.

Mac
MM
Mac_McDougald
Apr 23, 2004
2. Save this setting as a preset.
3. Change your crop tool settings by selecting a different preset then the one you just made.
4. Select the "300px X ?" preset you just made.
5. Change the 300px in the width box to another value…say 200px, leave the height blank and the resolution at 72px/inch
6. If you try and crop now, you’ll see that the height is fixed (as if you typed in a value into the height box) when it should remain variable.

After the other tangent, went back to this post of yours, so leaving in yours steps above.
Now that I really see the glitch, YES, I can confirm this behaves same for me also, with NO ppi specified.

Have to go to some other preset or type in the second dimension, then it "clears its memory" or somesuch, and is back to normal.

PS 7 here. Pretty minor though, doesn’t seem to really be a workflow stopper.

Mac
GA
George_Austin
Apr 23, 2004
Mac,

"…If I implied differently than this, I was on a tangent or hadn’t read closely enough…"

"Implied"??? C’mon,Mac, you could not have asserted your point more forcefully or unconditionally. But that’s OK. I’m inclined to go out on limbs myself. And I don’t regret it when I do, because I learn faster that way. The last time, back in 1985,… 🙂

George
MM
Mac_McDougald
Apr 24, 2004
What I mean was, I was basing everything I said re the inch settings on fact I thought you were inserting ppi value in crop dialogue, since OP with problem was, although he was using pixel setting.

But you’re correct, my statements were certainly more than "implications"; they were very assertive – and wrong for the circumstances you were actually describing.

So a big mea culpa.

Anyway, you see where I definitely can replicate the "bug" also?

Mac

How to Improve Photoshop Performance

Learn how to optimize Photoshop for maximum speed, troubleshoot common issues, and keep your projects organized so that you can work faster than ever before!

Related Discussion Topics

Nice and short text about related topics in discussion sections