What is a good practice for 2D scene graph partitioning for culling?
        Posted  
        
            by 
                DevilWithin
            
        on Game Development
        
        See other posts from Game Development
        
            or by DevilWithin
        
        
        
        Published on 2011-02-07T15:30:19Z
        Indexed on 
            2011/02/07
            15:34 UTC
        
        
        Read the original article
        Hit count: 333
        
I need to know an efficient way to cull the scene graph objects, to render exclusively the ones in the view, and as fast as possible.
I am thinking of doing it the following way, having in each object a local boundingbox which holds the object bounds, and a global boundingbox which holds the bounds of the object and all children.
When a camera is moved, the render list is updated by traversing the global boundingboxes. When only the object is being moved, it tries to enlarge or shrink the ancestors global boundingboxes, and in the end updating or not the renderlist.
What do you think of this approach? Do you think it will provide a fast and efficient culling?
Also, because the render list is a contiguous list, it could accelerate the rendering, right?
Any further tips for a 2D scene graphs are highly appreciated!
© Game Development or respective owner