Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Question optimizing batched vfx?

Discussion in 'Visual Effect Graph' started by laurentlavigne, Jul 3, 2021.

  1. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,225
    I finally batched all my vfx emitters using the position to texture trick. No more instance overhead.
    now there is no frustum culling of the bounds so it's not the most efficient for the GPU.
    I tried moving the bounds with the camera but if there is a large plum of smoke in the distance it disappears. Not the best.
    What ways do you recommend to optimize all that?
     
  2. JulienF_Unity

    JulienF_Unity

    Unity Technologies

    Joined:
    Dec 17, 2015
    Posts:
    324
    Hi, you can activate per particle frustum culling in your output (in the inspector). When no particle are visible, it will be an indirect draw call with 0 indices (so free on the GPU). In 21.2 We also have dynamic bounds computation
     
    laurentlavigne likes this.
  3. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,225
    which one is it?
    upload_2021-7-6_23-20-16.png
    upload_2021-7-6_23-19-43.png

    PS:
    good to know i can change the type without rewiring the output block
    upload_2021-7-6_23-20-49.png
     
  4. JulienF_Unity

    JulienF_Unity

    Unity Technologies

    Joined:
    Dec 17, 2015
    Posts:
    324
    Which version are you using? per particle frustum culling was added during 2020 cycle
     
  5. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,225
    the vfx that comes with urp 8.31 (2020.1.17)