Author Topic: Crop to a specific pixel width and height?  (Read 4052 times)

Offline Terry Danks

  • PixInsight Addict
  • ***
  • Posts: 137
Crop to a specific pixel width and height?
« on: 2011 September 19 04:42:18 »
I've tried both the Crop and Dynamic Crop tools but can't seem to get a crop box, say, 1920 px wide and 1080 px high?

Terry Danks

Offline georg.viehoever

  • PTeam Member
  • PixInsight Jedi Master
  • ******
  • Posts: 2132
Re: Crop to a specific pixel width and height?
« Reply #1 on: 2011 September 19 05:00:29 »
Try the Crop process (without "Dynamic" in its name).
Georg
Georg (6 inch Newton, unmodified Canon EOS40D+80D, unguided EQ5 mount)

Offline Terry Danks

  • PixInsight Addict
  • ***
  • Posts: 137
Re: Crop to a specific pixel width and height?
« Reply #2 on: 2011 September 19 07:45:23 »
Thanks, Georg. That narrows it down but I need more help than that.

I want to crop the image to 1920X1080 px and I can't see how to get the crop tool to do that. I can get it to do a crop that size FROM the image . . . but not allow me to take AS MUCH OF the image as I'd like and crop it to that size.

Offline NKV

  • PTeam Member
  • PixInsight Guru
  • ****
  • Posts: 677
Re: Crop to a specific pixel width and height?
« Reply #3 on: 2011 September 19 09:37:42 »
1) See attachment crop.JPG. :D
2) Also you can press Ctrl+Alt+I to crop all your images. Just drop nice blue triangle from ImageContainer to area near "mark 3" (see crop.JPG).
3) But, I think you looking for other instrument under codename Resample. See Resample.jpg

Best regards,
Nikolay.   

Offline Terry Danks

  • PixInsight Addict
  • ***
  • Posts: 137
Re: Crop to a specific pixel width and height?
« Reply #4 on: 2011 September 19 13:17:32 »
Many thanks, Nikolay.

You got me started but it seems a more complex procedure than it really should?

Goal: An image 1920 X 1080 px for computer wallpaper with a monitor of that native resolution.

With the image open:

1/ Use the Resample tool with the target set to 1920 px in width with Preserve Aspect Ratio box checked.
2/ On image resulting from step 1, use the Dynamic Crop tool to produce an image 1080 px in height. Place the box where you want it and execute the process.

Is there no way to tell PI to put a crop box 1920 by 1080 onto your image so you can slide it about until you have the framing you want and then execute to produce the 1920X1080 image framed as you like?

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: Crop to a specific pixel width and height?
« Reply #5 on: 2011 September 19 15:03:16 »
You only need DynamicCrop to do this:

- Open the DynamicCrop tool.

- Define a cropping rectangle covering the desired area on the image in one dimension (width or height). Let's say you want to fix the width.

- Open the Scale section and enter 1920 in the 'W' field. DynamicCrop will calculate the required horizontal scaling factor as 'Scale X'.

- Copy Scale X into Scale Y.

- Adjust the height of your cropping rectangle until you read 1080 for 'H'. Now you can move the rectangle as desired (click and drag inside the rectangle).

- If necessary, you can select a specific pixel interpolation. Usually the default 'Auto' setting works well.

- If necessary, you can click on one of the nine 'X' squares on the top right graph to read/set the corresponding coordinates of the cropping rectangle to exact pixel coordinates.

- Once you're done click the 'Execute' button.

Hope this helps.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline Terry Danks

  • PixInsight Addict
  • ***
  • Posts: 137
Re: Crop to a specific pixel width and height?
« Reply #6 on: 2011 September 20 06:35:02 »
BINGO!

Thanks, Juan. That did it. I knew I was making it more complicated that it had to be.  :D