# Transform a centered isosceles trapezoid in a rectangle in 2-D

I must convert a isosceles trapezoid to a rectangle in 2-D with a shearing transformation (or with 2 shearing transformations). The isosceles trapezoid is centered in the origin of axes. It is right write:

 x' = x + αy
y'=y


with α>0 per y>0 , and α<0 per y<0 (then 2 transformations)? And if it's right how can I calculate the parameter α? Otherwise if it is all wrong as I do?

• Are you shearing the left and right halves of the trapezoid independently? Could you explain the underlying problem you are trying to solve? – trichoplax Sep 30 '16 at 11:17
• @trichoplax yes independently, but I am not convinced of the correctness of the exposed solution. The underlyng problem is transform the view frustum , a truncated pyramid, in a parallepiped (in 3-D) but isn't important for now. – Umbert Sep 30 '16 at 12:11
• I'd recommend describing the background of what you're trying to do because it can affect which solution is most useful. For example, if your objective is to draw a parallelepiped, a simple answer may be "start with a cube instead of a truncated pyramid". If your objective is to convert a 3D texture then the use of a shear may be essential to the end result you require. In other cases there may be an easier approach. Without knowing the reasons behind it, it's hard to know what simplifying assumptions can be made. – trichoplax Sep 30 '16 at 12:36
• thing And this is one transformation when you have perspective divide but not possible with one 3x3 matrix without one. – joojaa Sep 30 '16 at 13:30