Particle Engine, Creating alot of Rain/Snow
I personally use one vertex (containing initial position, velocity, gravity factors, acceleration, time-since-spawn, etc) with forward/left/up values as shader constants, combined with instancing - everything is computed on the GPU from there and up to 16384 (arbitrary choice) particles are drawn per draw-call. There's no need whatsoever for any matrix changes and it runs faster than a slippery snot on a slope.
Again - show some more code, and how many draw calls?
Again - show some more code, and how many draw calls?
I think the other posters are on the same page as me. You may be making savings on the CPU by using a single vertex, but you're punishing the GPU by making many separate draw calls. It would probably run better if you had 200 vertices but pushed them through in a single batch.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement