0

I am new to Photoshop/Illustrator. I would like to warp an image like the attached truncated pie.

Assuming this truncated pie is part of a circle, then outer radius of curvature should be 15 units and inner radius of curvature should be 5 units, and angle of pie should be 60 degrees.

More specifically I want to use the unit as centimeter such that once this warped image is done, I can print it and the results are as per specification (i.e. outer radius is 15 cm and inner radius is 5 cm and angle is 60 degrees).

I have edited the attached image on photopea.com but there is no control of parameters there.

truncated pie

2
  • Hey Nimish, welcome! I noticed that you tagged scripting, are you looking for a script to do this? – WELZ Oct 4 '19 at 12:44
  • @WELZ, it will be really helpful if it can be done by scripting. I want to generate such images on the fly using certain input parameters. – Nimish Jain Oct 4 '19 at 12:50
0

Draw the wanted frame in Illustrator. You can for ex. align 2 circles and lines. Then fill the wanted piece with the Shape builder. Delete the extra parts and use the frame as the top object in Object > Envelope Distort > Make with Top Object.

It's tried here:

enter image description here

The lines were originally vertical, they are rotated plus and minus 30 degrees to get 60 degrees sector.

You must have right drawing dimensions to avoid losing resolution when you export the result as PNG or JPG. You can also copy and paste it to Photoshop straight from Illustrator. Before pasting open a big enough (in pixels) new document in Photoshop.

Photoshop can also make the warping. You can use Edit > Transform > Warp > Arc with negative percentage. In your case the right percentage is -33,3%. That's because 60 degrees is 33,3% of 180 degrees.

To get the wanted radiuses you must before warping stretch, squeeze or crop the image to certain dimensions and be sure that the photo is a freely deformable layer, not locked like the background.

The latter is required because the generated warped layer is bigger than the image size.

Let's assume you want sector angle = A, inner radius = R and outer radius = Q. With elementary trigonometry you get the following formulas to the needed rectangular image size before warping.

Width: W=2Rsin(A/2) Height: H=Q-R

If R=50 mm Q=150 mm and A=60 degrees, then W=50 mm and H=100 mm.

The layer size will be much bigger. New width will be W2=2Qsin(A/2). New height will be H2=Q-Rcos(A/2)

The next image has our Penguin photo stretched to 50 x 100 millimeters and warped to -33,3 % Arc. You see the result is much bigger:

enter image description here

In your case W2=150 millimeters and H2=106,7 millimeters. You must resize the canvas to this size.

This is the canvas resizing dialog:

enter image description here

And this is the resized image:

enter image description here

NOTE: Photoshop rounds image dimensions to full pixels. Thus it's well possible that the image is one pixel width too big or small. I guess the error is unnoticeable even at screen resolution.

There's a comment "you need a script". For it a programmer is needed. Unfortunately I'm not one.

1
  • thank you for such a detailed answer. I am sure it will help me. – Nimish Jain Oct 4 '19 at 19:24
0

In Photoshop you can use Edit → Transform → Warp, and choose Arc in the tool options along the top. Then you change the shape by clicking and dragging the top handle.

Example

enter image description here

1
  • thank you for the answer. I will try it and I am sure that it will work. – Nimish Jain Oct 4 '19 at 19:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.