Skip to content

Testbed project exploring the performance of Unity's Job System/Burst compiler combined with GPU mesh instancing.

License

Notifications You must be signed in to change notification settings

GeorgeAdamon/JobSystem_IndirectInstancing_Testbed

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Unity Job System & Indirect Instancing Testbed

Testbed project exploring the performance of Unity's Job System / Burst compiler combined with GPU mesh instancing (using the DrawMeshInstancedIndirect function, and passing Job System's NativeArrays directly to the shaders as ComputeBuffers).

The functionality provided by this project is slowly becoming obsolete, as the Visual Effect Graph can handle at least an order of magnitude more particles at comparable frame rates.
It's still a good example for basic DOTS data generation & useful for situations where the use of GPU / VFX Graph is not preferred.

Tested on Unity 2022.1.2f1

Index

Modes

Currently 2 modes are explored:

  • Particle Swarm
    524.288 Particles
    See it in action 524.288 Particles
  • Animated Vector Field
    262.144 Vectors 262.144 Vectors

Performance:

CPU: Intel i7 5930k, GPU: Nvidia GTX 970

Swarm:

524.288 Particles particles at 60-70 fps
1.048.576 Particles particles at 30 fps

Packages Used

To Do

  • Add support for HDRP and URP
  • [Particle Swarm] Implement spatial binning using the Concurrent NativeMultiHashMap collection.
  • [Particle Swarm] Implement flocking / Boid behaviour.
  • [Particle Swarm] Implement Unity's ECS (Entity Component System)

About

Testbed project exploring the performance of Unity's Job System/Burst compiler combined with GPU mesh instancing.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published