Explain what isn't working. Are you using shaders? Rendering to fixed-point fb causes clamping. Maybe you are rendering to floating-point framebuffers/pbuffers?
Type: Posts; User: roffe
Explain what isn't working. Are you using shaders? Rendering to fixed-point fb causes clamping. Maybe you are rendering to floating-point framebuffers/pbuffers?
With today's fast hardware I would ignore "flagging" any single primitives. Your batches should be in the size of >300 anyway, otherwise you'll be very CPU-limited. It is key to performance with...
Start simple, without any space partitioning scheme. Can you draw one slice of the cube? If so, try two. When that works activate blending support. I would suggest starting with simple 2d textures....
Your code is a bit confusing.
In the beginning of Draw() you clear the depth buffer, but you never enable depth testing in Setup_Opengl(). Do you want depth testing or not?
You usually disable...
Treat the light as any other object, position it with its local coordinates. It will transform with your viewing transforms.
I'm assuming java has a callback functionality like most windowing api's. Whenever a window changes size(programatically or by user) some message/event should be sent to your callback function/class....
Do you get the pixel format you request? Check that glGetInteger(...) with GL_RED_BITS,GL_BLUE_BITS etc return what you expect(32 that is) after you created your context.
Your sample code uses GLUI. Download and link.
That's a good question. For a better explaination than I can give you go here: http://users.actcom.co.il/~choo/lupg/tutorials/xlib-programming/xlib-programming-2.html
Search for "color maps".
...
For your benchmarking adventures I would also try using a single texture and glTexSubImage2D for updates. Try NV_pixel_data_range if available/wait for ARB_Pixel_Buffer_Object some more.
Here are some useful steps you might take when debugging render to texture problems. Some might feel redundant, but they eliminate doubt later on(well at least for me).General tip: check for errors...
For sure, I use it all the time nowadays after I saw one of your postings. It's a life saver. Not only does it catch the obvious mistakes, but also helps finding inconsistencies within driver...
Hmm, power of two sized texture??
It looks perfectly fine to me. Remember that glCopyTexImage2D IS glTexImage2D but it takes pixel data from the frame buffer instead of system mem.
Not the best. I was writing some support classes that would implement support for floating point pbuffers w/ RTT for ATI and NVIDIA cards on Windows and Linux. It is possible but it gets messy. I...
If the driver has DRI enabled I would assume some performance improvement. Benchmark some simple stuff to get a rough estimate.
I don't think so.
[B] Scale your base texture with some...
You are not creating a color map. Check your XCreateWindow attributes.
Maybe the RGBE format is an alternative.
http://www.graphics.cornell.edu/~bjw/rgbe.html
I don't know about GLSL but Cg supports frexp/ldexp. Link has sample code.
Your glCopyTexSubImage2D call looks ok. It assumes a texture format has already been chosen/is present, no format parameter needed. For your glCopyTexImage2D call I would specify GL_RGB8 as the...
I think they mean that errors can come from other systems that OpenGL use. For example, on windows wglGetLastError would return errors from the window sub-system. glX uses some other error reporting....
I had the same problem. CopyTexImage from fp buffers on ATI cards just didn't work. Emailed
their support but I never received a reply.
I assumed it just wasn't supported.
Mathias
EDIT: Code...
No and no from what I know.
[/B]
Just because you use double buffering does not mean it's off-screen rendering. You have to use pbuffers to make use of off-screen rendering.
[/B]
Reading back pixels that fail the...
I don't know if this is worth it but,
usually when creating a window and registering a class you would specify to create a private DC for the window(in the RegisterClass call: CS_OWNDC). Even though...
If you are using a 32bit fixed-point frame buffer your values will be clamped[0.0-1.0].
Are you using glReadPixels with GL_UNSIGNED_BYTE to read back the framebuffer?