Delete transparency left after rotating layer

CA
Posted By
Chuck Anderson
Apr 11, 2005
Views
311
Replies
8
Status
Closed
I’ve searched and found a couple of discussions that touch on this topic, but I have not found any resolution.

I have a photo (several actually) where the horizon is a few to several degrees from horizontal. The best way I have found to rotate them is to convert the Background to a layer (double-click in the layer palette), stretch the canvas sides bigger than the image, and then use Edit – Transform – Rotate. In this manner, I can best decide when it appears level (especially if I Show – Grid) before I transform the image.

Now all I have to do is trim the slivers of transparency at all four corners. I select all of the transparency with the magic wand and then Invert Selection, hoping to crop to that selection (a perfect rectangle including only the visible image). Maddeningly, Image – Crop does nothing. I’ve even tried Copy / New Doc / Paste, but I get the entire image (including the transparent slivers).

(When selecting I turned off anti-alias and set Tolerance to 0.)

Why won’t the crop tool work? It seems to me like this should be a straight forward operation. And why doesn’t Edit Copy, copy only the selection?

Is there a way to make this work?

Is there another process for rotating images a few degrees and then trimming the transparency?


*****************************
Chuck Anderson • Boulder, CO
http://www.CycleTourist.com
Integrity is obvious.
The lack of it is common.
*****************************

How to Master Sharpening in Photoshop

Give your photos a professional finish with sharpening in Photoshop. Learn to enhance details, create contrast, and prepare your images for print, web, and social media.

I
iehsmith
Apr 11, 2005
On 4/11/05 12:41 AM, Chuck Anderson uttered:

I’ve searched and found a couple of discussions that touch on this topic, but I have not found any resolution.

I have a photo (several actually) where the horizon is a few to several degrees from horizontal. The best way I have found to rotate them is to convert the Background to a layer (double-click in the layer palette), stretch the canvas sides bigger than the image, and then use Edit – Transform – Rotate. In this manner, I can best decide when it appears level (especially if I Show – Grid) before I transform the image.
Now all I have to do is trim the slivers of transparency at all four corners. I select all of the transparency with the magic wand and then Invert Selection, hoping to crop to that selection (a perfect rectangle including only the visible image). Maddeningly, Image – Crop does nothing. I’ve even tried Copy / New Doc / Paste, but I get the entire image (including the transparent slivers).

(When selecting I turned off anti-alias and set Tolerance to 0.)
Why won’t the crop tool work? It seems to me like this should be a straight forward operation. And why doesn’t Edit Copy, copy only the selection?

Is there a way to make this work?

Is there another process for rotating images a few degrees and then trimming the transparency?

It seems to me that when you rotate you no longer have a perfect 90º rectangle. Use the crop tool in the tool palette instead. Or, the rectangle marquee to select and then Image Crop.
CA
Chuck Anderson
Apr 11, 2005
iehsmith wrote:

On 4/11/05 12:41 AM, Chuck Anderson uttered:

I’ve searched and found a couple of discussions that touch on this topic, but I have not found any resolution.

I have a photo (several actually) where the horizon is a few to several degrees from horizontal. The best way I have found to rotate them is to convert the Background to a layer (double-click in the layer palette), stretch the canvas sides bigger than the image, and then use Edit – Transform – Rotate. In this manner, I can best decide when it appears level (especially if I Show – Grid) before I transform the image.
Now all I have to do is trim the slivers of transparency at all four corners. I select all of the transparency with the magic wand and then Invert Selection, hoping to crop to that selection (a perfect rectangle including only the visible image). Maddeningly, Image – Crop does nothing. I’ve even tried Copy / New Doc / Paste, but I get the entire image (including the transparent slivers).

(When selecting I turned off anti-alias and set Tolerance to 0.)
Why won’t the crop tool work? It seems to me like this should be a straight forward operation. And why doesn’t Edit Copy, copy only the selection?

Is there a way to make this work?

Is there another process for rotating images a few degrees and then trimming the transparency?

It seems to me that when you rotate you no longer have a perfect 90º rectangle. Use the crop tool in the tool palette instead. Or, the rectangle marquee to select and then Image Crop.
Duh. Don’t know what I was thinking. Once I got away from the problem for a while it occurred to me that I was mistaken.

Thanks for helping.

I guess I was thinking that there ought to be a function that could figure this one automatically (draw the selection as a level rectangle with its corner locations based on the innermost transparent/opaque edge on all four sides). I’ll just have to zoom in so I get an accurate selection (or learn how to write a plugin?).


*****************************
Chuck Anderson • Boulder, CO
http://www.CycleTourist.com
Integrity is obvious.
The lack of it is common.
*****************************
E
edjh
Apr 11, 2005
Chuck Anderson wrote:
I’ve searched and found a couple of discussions that touch on this topic, but I have not found any resolution.

I have a photo (several actually) where the horizon is a few to several degrees from horizontal. The best way I have found to rotate them is to convert the Background to a layer (double-click in the layer palette), stretch the canvas sides bigger than the image, and then use Edit – Transform – Rotate. In this manner, I can best decide when it appears level (especially if I Show – Grid) before I transform the image.
Now all I have to do is trim the slivers of transparency at all four corners. I select all of the transparency with the magic wand and then Invert Selection, hoping to crop to that selection (a perfect rectangle including only the visible image). Maddeningly, Image – Crop does nothing. I’ve even tried Copy / New Doc / Paste, but I get the entire image (including the transparent slivers).

(When selecting I turned off anti-alias and set Tolerance to 0.)
Why won’t the crop tool work? It seems to me like this should be a straight forward operation. And why doesn’t Edit Copy, copy only the selection?

Is there a way to make this work?

Is there another process for rotating images a few degrees and then trimming the transparency?
You say the Crop tool doesn’t work, but I don’t see that you’ve used the Crop tool. Use the Crop tool instead of Image>Crop.I think what’s happening is that your selection is already inside the best rectangle that can be cropped. With the Crop tool you can determine where the area to be cropped should be.

By the way, there is a better way to straighten an image. Use the Measure tool (little ruler under the eyedropper) and run a line very carefully along the edge you need to be vertical or horizontal. Then go to Image>Rotate> Arbitrary and hit Enter. The image will right itself.

You can also use the Crop tool to straighten images, but in this case you are probably better off with the Measure tool.


Comic book sketches and artwork:
http://www.sover.net/~hannigan/edjh.html
Comics art for sale:
http://www.sover.net/~hannigan/batsale.html
J
jjs
Apr 11, 2005
"Chuck Anderson" wrote in message

I guess I was thinking that there ought to be a function that could figure this one automatically […]

You might be able to use the ‘Trim’ option. It crops based upon transparent pixels.
I
iehsmith
Apr 11, 2005
On 4/11/05 8:28 AM, jjs uttered:

"Chuck Anderson" wrote in message

I guess I was thinking that there ought to be a function that could figure this one automatically […]

You might be able to use the ‘Trim’ option. It crops based upon transparent pixels.

I don’t think this would have worked in this case because Trim works on straight level rectangular areas and his has been rotated; no longer level; so he would end up with wedges remaining.

I personally would not want a program to automatically decide where I wanted to crop in any similar instance.

inez
CA
Chuck Anderson
Apr 11, 2005
iehsmith wrote:

On 4/11/05 8:28 AM, jjs uttered:

"Chuck Anderson" wrote in message

I guess I was thinking that there ought to be a function that could figure this one automatically […]
You might be able to use the ‘Trim’ option. It crops based upon transparent pixels.

I don’t think this would have worked in this case because Trim works on straight level rectangular areas and his has been rotated; no longer level; so he would end up with wedges remaining.

I personally would not want a program to automatically decide where I wanted to crop in any similar instance.

inez
Yes, Trim rightfully does not work in this case.

But there is only one crop selection size and shape (rectangle) possible that will give you *the* most amount of image without the wedges (what I always want to do when I correct a photo by rotating it). That can be calculated, thus there could be a plugin that creates that selection if you wanted it to. That’s a tool (a choice) I’d like to have.

As it is now, I have to zoom in many times to be sure that I am not including any background in my crop while not losing any more image pixels than I need to. This becomes tedious, as I have to scroll around to each corner to set them manually.


*****************************
Chuck Anderson • Boulder, CO
http://www.CycleTourist.com
Integrity is obvious.
The lack of it is common.
*****************************
CA
Chuck Anderson
Apr 11, 2005
edjh wrote:

Chuck Anderson wrote:

I’ve searched and found a couple of discussions that touch on this topic, but I have not found any resolution.

I have a photo (several actually) where the horizon is a few to several degrees from horizontal. The best way I have found to rotate them is to convert the Background to a layer (double-click in the layer palette), stretch the canvas sides bigger than the image, and then use Edit – Transform – Rotate. In this manner, I can best decide when it appears level (especially if I Show – Grid) before I transform the image.
Now all I have to do is trim the slivers of transparency at all four corners. I select all of the transparency with the magic wand and then Invert Selection, hoping to crop to that selection (a perfect rectangle including only the visible image). Maddeningly, Image – Crop does nothing. I’ve even tried Copy / New Doc / Paste, but I get the entire image (including the transparent slivers).

(When selecting I turned off anti-alias and set Tolerance to 0.)
Why won’t the crop tool work? It seems to me like this should be a straight forward operation. And why doesn’t Edit Copy, copy only the selection?

Is there a way to make this work?

Is there another process for rotating images a few degrees and then trimming the transparency?
You say the Crop tool doesn’t work, but I don’t see that you’ve used the Crop tool. Use the Crop tool instead of Image>Crop.I think what’s happening is that your selection is already inside the best rectangle that can be cropped. With the Crop tool you can determine where the area to be cropped should be.

By the way, there is a better way to straighten an image. Use the Measure tool (little ruler under the eyedropper) and run a line very carefully along the edge you need to be vertical or horizontal. Then go to Image>Rotate> Arbitrary and hit Enter. The image will right itself.
You can also use the Crop tool to straighten images, but in this case you are probably better off with the Measure tool.
That’s a new one for me – and I like it very much.

Thank you.


*****************************
Chuck Anderson • Boulder, CO
http://www.CycleTourist.com
Integrity is obvious.
The lack of it is common.
*****************************
I
iehsmith
Apr 12, 2005
On 4/11/05 4:59 PM, Chuck Anderson uttered:

You can also use the Crop tool to straighten images, but in this case you are probably better off with the Measure tool.

I’m still using PS 6.0.1, but I sure have been using perspective with the crop tool a lot lately with digital photos I have to work with (when they give me enough waste space on the sides, that is).

inez

MacBook Pro 16” Mockups 🔥

– in 4 materials (clay versions included)

– 12 scenes

– 48 MacBook Pro 16″ mockups

– 6000 x 4500 px

Related Discussion Topics

Nice and short text about related topics in discussion sections