Search Unity

Question GPU instancing on small meshes - why not?

Discussion in 'General Graphics' started by opel_cobalt, Dec 29, 2022.

  1. opel_cobalt

    opel_cobalt

    Joined:
    May 18, 2021
    Posts:
    26
    Documentation on instancing says:

    as a general rule, don’t use GPU instancing for meshes that have fewer than 256 vertices

    Could someone please explain the details as to why?

    And why do particle systems don't fit this general rule, as they do have instancing option?
     
    adamgryu likes this.
  2. topitsky

    topitsky

    Joined:
    Jan 12, 2016
    Posts:
    100
    particle systems use dynamic instancing, which is somehow different.
     
  3. burningmime

    burningmime

    Joined:
    Jan 25, 2014
    Posts:
    845
    Instancing is more important on small meshes than big ones because the overhead of draw call setup and state switching is high relative to time to execute the actual draw call.

    For static (non-moving) geometry, Unity has static batching. It also has dynamic batching, although that's of questionable value nowadays. Both of those work with small (<256 vert) meshes.