Re: offscreen rendering and taking screenshot
Posted by c0d3x on Aug 01, 2019; 10:26am
URL: https://forum.jogamp.org/offscreen-rendering-and-taking-screenshot-tp4039872p4039895.html
Thanke you for response,
it's exactly the same frustum configured in a camera class that is contained in the renderer class that is passed
as
public void render(GLRenderer renderer, GLAutoDrawable drawable) {
...
}
the same renderer is used to render the corect image as you can see in the first screen shot.
It's definitely a depth buffer configuration issue, as you can see on the second screenshot. Look at the chairs in the car model where the rear chair should be covered by the front chair, but this is not the case. I also thought it was a Frustum problem in the first place and so I carefully checked everything that goes with my camera code.
The code i posted is converted from C++ and i used raw OpenGL code, in general we want avoid using specific jogl api and use raw OpenGL calls because we here have already experience.