Very big objects in the Space

Hello! I have a problem with rendering of big objects in Space. Thre are some rendering artifacts, when I use they native sizes as parameters for rendering. It is normal, computer’s abilities are not infinite.

I want to use next system for fixing my problem:
I want to make small copy of universe (Sun, planets…), with original proportions but small size. And other space objects (spaceships, asteroids) with they native sizes. And render all it in next sequence:
1). Firstly render big space objects (Sun, planets…)
2). Then render small objects in stencil buffer.
3). Then superimpose z-buffer with stencil buffer to make “holes” in places with small objects.
4). Then render small objects on the screen.

It is easy for me, using OpenGL directly, but can I control the rendering process, the rendering sequence, using Panda3D?

I’m sorry for my english…

Yes, you can use DisplayRegions and binning to control render order. You can use the StencilAttrib to control use of the stencil buffer.

I’m not quite sure I understand your original problem, or your proposed solution, though. But maybe it doesn’t matter whether I understand it, as long as you do. :slight_smile:

David

what i do is create 2 display regions. Draw all planet & system stuff in one region then clear the depth buffer. Then draw all local objects over them.