Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 3 of 3

Thread: Rendering around camera or level based

Hybrid View

  1. #1
    Junior Member Newbie
    Join Date
    Nov 2012
    Posts
    13

    Rendering around camera or level based

    Hey,
    I have one thing to ask. I know that there is something like drawing distance in OpenGL but is that enough when creating a large game maps?
    I mean I would like to make a huge game environment but of course make it somehow playable . For example render only the part around the camera or split the level to some renderable areas and render only the parts which are near or something.
    I don't know how moder games handle this, I remember only some old mechanisms form the old ones but what is the best approach for a large map rendering? I have programmed only a small levels where I rendered normally everything at once so far.
    Could you please give me some tips or redirect me to some tutorials? I don't know where to start with this. I have some ideas but are there some common ways or algorithms to solve this?
    Many thanks and have a nice day ^^

  2. #2
    Member Regular Contributor Agent D's Avatar
    Join Date
    Sep 2011
    Location
    Innsbruck, Austria
    Posts
    254
    This is quite a huge topic.

    Modern games normally organize their map geometry in visibility graphs or trees to determine visible areas at runtime, so the don't waste resources rendering things that can't be seen anyway.

    There's a large amount of different algorithms for different scenarios, depending on whether you want to render indoor or outdoor scenes or how dynamically updatable the map geometry has to be.

    You might want to take a look at one of the following things:

    BSP Trees (good for indoor scenes, computed offline, used by the Quake engine, the Source Engine and other Quake descendants)
    Octrees (Easy to implement, also dynamically, some rendering engines like Ogre3D or Irrlicht implement these)
    Portal Based rendering (good for indoor scenes, easy to implement, scene is divided in rooms that are connected via portals)

    This is just what came to my mind when I briefly read your post. There are hundreds of approaches, also some that are trying to take advantage of modern GPUs (like "instance cloud culling").

    Since there is AFAIK no one ideal solution for everything, you might have to compromise on what types of scenes you want to render.

  3. #3
    Junior Member Newbie
    Join Date
    Nov 2012
    Posts
    13
    Quote Originally Posted by Agent D View Post
    This is quite a huge topic....
    Many thanks, I will check that out ^^

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •