Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Mathematica > Data Manipulation > Image Processing & Analysis > Image Geometry > ImagePerspectiveTransformation >

ImagePerspectiveTransformation

ImagePerspectiveTransformation
applies a linear fractional transform specified by a matrix m to the positions of each pixel in image.
ImagePerspectiveTransformation
gives an image of the specified size.
AspectRatioAutomaticaspect ratio of the output image
DataRangeAutomaticrange of coordinates in the original image
PlotRangeAutomaticrange of coordinates in the resulting image
PaddingBlackpadding method
ResamplingAutomaticresampling method
  • DataRange->Automatic is equivalent to a setting of , where represents the aspect ratio of the original image.
  • For possible size specifications, see the reference page for ImageResize.
Transform an image using a perspective transformation:
Transform an image using a perspective transformation:
In[1]:=
Click for copyable input
Out[1]=
Specify the size of the resulting image:
Use a geometric transformation matrix:
Set the input range of the function to be the actual pixel coordinates:
Use a fixed padding while rotating the image:
Use reflected padding:
Use the PlotRange option to show all the transformed pixels from the original image:
Use different resampling methods:
Remove the perspective distortion of the road:
Enhance the perspective effect:
Segment out the building in an image:
Shear the image to straighten up the building:
When the function maps some coordinates to infinity, truncated output is displayed:
New in 8
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team
Format:   HTML  |  CDF