Announcement

Collapse
No announcement yet.

Terrain vs static mesh outdoor levels for performance

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Terrain vs static mesh outdoor levels for performance

    Hi guys,

    If I were to create a rather big outdoor level would it be best to do the ground work in a 3d application or UDK's ingame terrain editor.

    Which one would be a better option Performance-wise.

    I'm wondering if the created terrain in UDK counts as BSP or something similar that uses too much processing power.

    #2
    Both ways can be good or bad.
    Terrain in UDK can be set to constantly adjust its poly size based on distance from the camera. So, the distant mountains may only be a fraction of the polys that they will be up close. That makes Terrain much faster if you use it. The down side is that if you ever run at a mountain, you'll notice the mountain changing shape as it gains more detail.

    Mesh can be split in to multiple pieces so that the engine can occlude any parts that aren't in the view port. Since it only renders the terrain bits that the camera can see, static mesh terrain can be very very fast if you cut it into lots of pieces and design it in such a way that the player will never see huge chunks at one time.

    You can use volumes and fog to limit max view distance in both cases to maximize performance.

    Terrain layers can get expensive, but you can make a single layer contain your entire terrain texture if you want to speed it up that way. Mesh requires that you skin it and have a pre-made texture, so you don't have the option of layers. Terrain has deco layers that mesh won't have, so you'll need to manually place every tree and bush.
    Overall, I'm guessing that mesh can be faster than terrain overall, but only as long as you keep it very low poly (About the same tessellation as the terrain has).

    Also, don't forget that you can stream in multiple persistent levels. So, you could have several terrains or meshes that don't load at all until the player gets close (Or hits a trigger). Then, they can unload and completely go away once the player is far away from it. That way, you can have giant levels that only spawn the parts that are needed at that moment. That can cause lag spikes as a new chunk loads if the level has a lot of meshes or tessellation though, so test often if you use it to make sure that you're not pushing your PC too hard.

    Comment


      #3
      Terrain is also automatically split into several parts, usually every 16x16 block with the default setting, so none of the faces from such a 16x16 block is visible, the whole block won't be rendered.

      For UE2 they said that Terrain renders faster than BSP but slower than StaticMeshes, but that surely has changed in UE3 again due to the new Terrain features and the overall polycount. But I would rather go with a Terrain than with a StaticMesh.. this is just what it was made for and it gives you more flexibility afterwards when you need to do some changes in your map geometry again.


      And Terrain dynamically chooses the PhysMat for the texture layer that is currently the most dominant one when you walk on it, so you easily get different walking sounds when you walk on grass or stone on your Terrain.

      Comment


        #4
        Cheers for the great replies guys.

        I think I'll go with the UDK terrain editor due to the fact that it is easier to work with.

        The game is to be played from an isometric perspective so there will always be a big chunk visible on screen. The levels won't be as detailed as an fps level though. Just to give an idea of what it will look like, the old desert strike, jungle strike series is the type I'm aiming for.

        The terrain automatically splitting sounds really helpful if it avoids rendering the rest of the map that is offscreen.

        Comment


          #5
          Originally posted by Wyldhunt View Post
          Both ways can be good or bad.
          Terrain in UDK can be set to constantly adjust its poly size based on distance from the camera. So, the distant mountains may only be a fraction of the polys that they will be up close.
          How can you make that happend?

          Comment

          Working...
          X