2d Warping.

Hello !

Forgive my English , please !

I’m developing a program to make deformations
(warping) on images. Speed is very critical for me. So , I want to know if the OpenGL and
hardware accelerators can help me .

What you think ?

Artur Correa

artur@ig.com.br

Yes, it can. There’s an example around the place about distortion. Its included with the Irix distribution on SGIs, but its likely to be around here, somewhere.

The trick is to render the frame to the back buffer, copy the image to texture memory and render a distorted polygon mesh. The mesh should be configured so the texture parameters and verticies point to the distorted and undistorted points. (Which way is better? who knows? :wink:

Hope this helps,

cheers,
John

Originally posted by john:
[b]Yes, it can. There’s an example around the place about distortion. Its included with the Irix distribution on SGIs, but its likely to be around here, somewhere.

The trick is to render the frame to the back buffer, copy the image to texture memory and render a distorted polygon mesh. The mesh should be configured so the texture parameters and verticies point to the distorted and undistorted points. (Which way is better? who knows? :wink:

Hope this helps,

cheers,
John[/b]

=============================================
Thanks for your response!

I must to study more and more about OpenGL after all. Your help was very useful.

I will buy a 3D Board in brief . So , I
will start the work !

Howdy,

glad to hear it. :wink: actually, my honours project last year was on this sort of thing. well, a part of it involved distorting the frame buffer. I maybe even have some really old demos of the distortion if you’re interested in it. No, i lie: I do have a glut-based demo. If you want me to send it to you to see how I distort the frame, let me know.

cheers
John

[QUOTE]Originally posted by john:
[b]Howdy,

I’d like to receive your examples, In order to examine it !

I’m very grateful

Same aspects of my project:

I’m Working in a Digital video workstation , for medical application.

Look this http://www.sismed.com.br/isi.htm

By this time , I’m improving the system with the digital subtraction resource:

  1. My system captures a continuation of frames , that shows the patient’s heart.
    (the coronary blood vessels)in animation .

  2. The Doctor chosses a frame (normaly the first) like a “mask”

  3. The digital subtraction system makes the animation , by subtracting each
    frame from the masc. So , we can see only the contrasted vessels , because
    the first frame don’t have contrasted vessels.

This technique is used to eliminate indesired objects, like Bones.

The problem is: The patient’s movement cause the dislocation of the frames
relating to the masc. So , the result of the subtraction became shadowed.

The Warping of the masc is a tool pointed to help in dis case. The idea
is to readapt the masc to each frame of the animation. I know that I will need
an automatic generation of the meshes , but that is another problem…

Artur Correa
arturapps@ig.com.br

Anyone tried implementing McMillans image warping algorithm in OPenGL. ie. Given one image, create a new one from a nearby viewpoint.

Tried various ways of implementing it and getting garbage. Im new to OPenGL so maybe thats the reason. Or maybe Im just thick.