Can jogl handle 3D volume rendering?

I try to render 256x256x256 3D data set by using jogl. I got a Java virtual machine internal memory leak. I doubt can jogl handle real time volume rendering or not. I post my jogl project and data set under the following link. Hopefullly, some experts can help me to find the error( might be in my code).

http://home.gwu.edu/~ruida/volren.rar

Thanks

–Cat

JOGL is a binding to OpenGL

So your question is: “Can OpenGL handle 3D volume rendering”

The answer is: yes.

[quote]I got a Java virtual machine internal memory leak.
[/quote]
What makes you so sure? You’d be the first to find it after all those years? 99.99% chance the bug is in your code.

256256256*RGBA (4 bytes) = 64M

You need to enlarge your native-heap first, and that might not be your worst problem, does your GPU have much more vRAM than 64M ?

My card ( GeForce 6800 GS ) has 256 MB memory. How do you expand the heap size?
I think the memory leak is caused by the glTexImage3D.

You still have not told ayone why you think its a memory leak.

What have you done to debug this? Have you run a profiler?

Could you tell me how. I am a new jogl user.

http://profiler.netbeans.org

You may have already resolved this, but in the case that you haven’t… I have a JOGL-based volume renderer (using GLSL shaders) that runs great. I display 512x256x128 datasets, usually on Geforce 6800 GS 256MB hardware, as well as some other geometry that I “overlay” into the volume rendering. On a 6800 GS, my renderer generally gets somewhere around 20fps, which makes the gamer in me cringe, but our users (doctors) are thrilled with it. It’s also worth noting that this renderer doesn’t get a chance to run standalone either; it is executed only from within our very bloated main application, so it’s doing all this with a substantial amount of other assorted dead weight code running.

At any rate, I can certainly say that JOGL is more than up to the task. 8)

hifujava,

Could you post a link for your volume rendering project? Thanks.

There isn’t a web page up for the project, but i’ll see what i can do about some screenshots or something.

I can personally attest that JAVA/JOGL is more than up to the task of Volume Rendering…
Go here: http://java.sun.com/javaone/sf/sessions/general/day4.jsp
Watch Segment One
About 22 minutes in or so you’ll find your evidence… :wink:

I was wondering if the .hdr and .img format for the two files in that archive u provided are standard.

I look at the code a bit and tried to compile, but your code won’t read the file. Plus, you appended “.raw” to the file string, where there is no “raw” file in the archive–did u mean, “img?” Wait! Does your “.hdr” means header info?

oh, in the display(…), you are allocating new buffers (xBuf and Eqx) everytime the window resizes and those are local vars–this may have been the cause of mem leaks. perhaps, an expert in this forum can provide sound analysis.

If you can lemme know more about the .hdr file, maybe i can help. well, it’s seems interesting to view a cubic image with clipping planes interesting it. well, good luck.