Login  Register

Re: Multithreading

Posted by Haroogan on Feb 14, 2011; 7:11pm
URL: https://forum.jogamp.org/Multithreading-tp2221001p2494876.html

I'm back again :)

Finally I have had my time to finish the idea, which was explained in my first post. The multi-threaded streaming works fine, but there is one problem with mapping buffers as WW said. I don't know why but it seems like my file reader does not fill mapped ByteBuffers (I'm not sure about it yet). I've done everything as WW said... But nothing on screen if I use mapping :(

If I use traditional glBufferData (then one which copies data to graphics card), then it works fine, but I think that's a bad idea to use glBufferData in rendering loop. I'm sure mapping should speed things up. I will try to figure out, right now, why it does not work, but anyway if you have some ideas on typical mistakes I could do while mapping - tell me.

For instance, I've used GL_STATIC_DRAW flag instead of GL_DYNAMIC_DRAW, is that acceptable?
Or maybe, something should changed in rendering code?