Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Terrain Optimization

Discussion in 'General Graphics' started by BDamien54, Mar 1, 2015.

  1. BDamien54

    BDamien54

    Joined:
    Feb 22, 2015
    Posts:
    12
    Hello,

    I am currently working on a tropical terrain for my game. I painted all the trees with the terrain's "place trees" mod. When I test my game the Draw calls are between 3000 and 4000 which slow my game down a lot (10 FPS). I don't know how to optimizate it, I already searched but without success..

    I tried the static batching but it didn't work the way I did it.. Can someone help me please ?

    I'm sorry if my english is not so good ; I'm french.

    Thank's in advance !
     
  2. larsbertram1

    larsbertram1

    Joined:
    Oct 7, 2008
    Posts:
    6,911
    - trees: lower the billboard distance as each mesh tree produces 2 draw calls (6 if real time shadows are enabled).
    as built in billboards ar e not camera aligned you may think about buying the advanced foliage shader package from the asset store. next to other features it will make the transition between mesh trees and billboards much smoother.
    - grass: lower the detail resolution in the terrain settings (please note: you will have to repaint all details as they get cleared). low detail resolutions will reduce the number of draw calls but won’t let you position grass exactly.
    - lower the resolution of your height map.
     
    BDamien54 and theANMATOR2b like this.
  3. Ronald_McScotland

    Ronald_McScotland

    Joined:
    Jul 30, 2014
    Posts:
    174
    Increase the detail resolution per patch. The higher you set this, the more trees and grass it will batch into each draw call.
     
  4. BDamien54

    BDamien54

    Joined:
    Feb 22, 2015
    Posts:
    12
    Thanks a lot ! My game's back to 60 FPS thanks to you two ! :D