PDA

View Full Version : Speed up numerical computation with OpenGL ?



bob_white
09-26-2003, 02:26 AM
Hi all,

I work with digital terrain mapping.
I need to compute some parameters such as profile section betwen 2 points, max slope, which place is visible in a direction...
The problem is to compute these parameters very quickly and not to display this 3D environment

OpenGL is dedicated to visualize and transform 3D environment.
However, I am wondering if some OPENGL primitive could be used to speed up such process.
More praticaly, is it possible to perform basic operation on data (check visibility for instance) ?

Thank a lot for your point of views or ideas


Bob

Jan
09-26-2003, 03:10 AM
Yes, that is possible. There has been a long discussion on this board about it. Just search OpenGL.org, you should be able to find some stuff.

Jan.

roffe
09-26-2003, 01:53 PM
Originally posted by bob_white:
More praticaly, is it possible to perform basic operation on data (check visibility for instance) ?

I can think of three ways to do any kind of visibility computation on the gpu.

1.Simplest way. Render into depth buffer, read back to system memory. Sort out on the cpu what is visible and not.This would of course require you to render some kind of id ,instead of color for your primitives.

2. Occlusion queries (http://oss.sgi.com/projects/ogl-sample/registry/ARB/occlusion_query.txt) . Let the gpu tell you how much of a primitive(s) passed the depth test.

3. Advanced fragment programs. If you can find a mapping of your current problem into
the parallel nature of the gpu domain you might be able to solve your problem completely on the gpu. Here are some pioneering works you might find interesting, http://www.graphics.stanford.edu/papers/author.html#TimothyJPurcell

h2
09-26-2003, 02:44 PM
Pioneering? Come on, the idea to use OpenGL as a SIMD processor is almost as old as I am http://www.opengl.org/discussion_boards/ubb/smile.gif


[This message has been edited by h2 (edited 09-26-2003).]

roffe
09-26-2003, 03:44 PM
Originally posted by h2:
Pioneering? Come on, the idea to use OpenGL as a SIMD processor is almost as old as I am http://www.opengl.org/discussion_boards/ubb/smile.gif

I was referring to the works in the links,raytracing/GI on GPUs. If you know similiar work before this I'd be very interested to hear about it.


[This message has been edited by roffe (edited 09-26-2003).]

h2
09-27-2003, 02:30 AM
I thought that your "pioneering" is related to the whole area of "mapping of your current problem into the parallel nature of the gpu domain". Unfortunately, I'm not competent in RTRT area.