Tell me more ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I'd like to perform a projective-transformation (a.k.a. perspective-transformation) warp on an image.
Given the 4 2D corners of the source and target quadrangles (from these the 3x3 Homography matrix can be easily calculated) and the source and target images, I'd like to use the iPhone's OpenGL interface to perform the warp.
I'd like a functionality similar to OpenCV's cvWarpPerspective().

share|improve this question
Model-view-projection matrices and textured plane are not enough for this task? – Notabene Sep 5 '11 at 21:18
@Notabene: Perhaps they are. It's been years since I last used OpenGL. If you have a snippet that shows how to do this, it will be great. – Adi Shavit Sep 6 '11 at 6:40
The question is (you are talking about computer vision right?). Do you have model of your camera? Position, direction, FOV? Or do you have 4 corners computed and transformed in camera space? Those are two different tasks. – Notabene Sep 6 '11 at 7:14
What I need is a geometric transform of a single 2D image. The camera model etc. is not relevant here. I need to warp a known (convex) 2D quadrangle in the image into another known convex quadrangle in another image. – Adi Shavit Sep 6 '11 at 7:48
And can you calculate that four points on your own? Than it should be really easy to render. (i will post some example how to do it when you got points, once i will be back home from work - in 8-9hours) – Notabene Sep 6 '11 at 8:23
show 3 more comments

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.