how to get top view of an image from snapshot taken from a camera kept at an angle?

2 ビュー (過去 30 日間)
Senthil Kumaran
Senthil Kumaran 2011 年 2 月 23 日
編集済み: Efe 2014 年 9 月 29 日
i want the top view of a particular 2D object(like a painting on the wall). but i cant place the camera on top. i have to click the object from an angle. now what do i do to get the top view from this clicked image?

回答 (2 件)

Doug Eastman
Doug Eastman 2011 年 2 月 23 日
The Image Processing Toolbox has functions like IMTRANSFORM that can adjust the perspective of an image. See this example.
You will need some information to create the appropriate transformation (for example you could use the fact that the border of the image should be rectangular).
  1 件のコメント
Efe
Efe 2014 年 9 月 29 日
The link you have provided is now broken. Could you send the unbroken one, please?

サインインしてコメントする。


Efe
Efe 2014 年 9 月 29 日
編集済み: Efe 2014 年 9 月 29 日
I will ask more specific question about this problem.
The command imtransform() needs a picture to transform and a transformation object. I create this object with maketform() command and i know that this function needs a transformation type and NxN matrix to be written inside. I changed the parameters of NxN matrix billion times and all i got is a single line or a point. Can someone explain the logic behind this operation?
My Code is:
I = imread('yol.jpg');
tform = maketform('projective',[1 0 3; 1 2 1; 0 0 0]); % <--- dont know how to define this matrix
out=imtransform(I,tform);
subplot(2,1,1); imshow(I); subplot(2,1,2); imshow(out);
And the operation i wanted to do is attached

カテゴリ

Help Center および File ExchangeGet Started with Image Processing Toolbox についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by