Hacker News new | ask | show | jobs
by moron4hire 3791 days ago
Are you simulating the powder on the GPU or the CPU? I couldn't find any shader code that looked relevant to the sim, so I'm guessing it's the CPU. Any plans on making a GPU version? Seems loke you'd be able to overcome the perf issues and finally make that 3D version.
2 comments

Everything's on the CPU right now. Since the interactions between particles is incredibly complex and is designed for serial execution, the best place to start is rendering visuals like fire and blob effects. However, on my machine there is little difference in performance when toggling this feature on/off.
I have serious doubts a 3d version would be better. It would be hard (if possible at all) to make an equally simple interface that conveys the same information and is equally easy and fast to use while allowing free 3d interaction.

Maybe that becomes a lot easier once virtual reality and 3d input devices become common, but until then I think there are better ways to use extra computation power

The grandparent said GPU simulation, for the extreme parallel benefits, not making it 3D. Encoding the simulation in a GPU shader, for example.
I should have been clearer, I was referring only to the last part of the last sentence

>Seems loke you'd be able to overcome the perf issues and finally make that 3D version.

Which I interpreted as "once GPU simulation makes things fast, why not make a 3d simulation"

Apart from that part I agree with the ancestor comment, the code seems to do CPU simulation and GPU simulation is likely to be faster. On the other hand GPU simulation would likely mean rewriting the entire simulation engine from scratch, so I'm not holding my breath.

There was commentary in the FAQ that he was not going to try to make a 3D version because of the perf issues. I assumed that meant figuring out GPU sim would mean he'd try to make a 3D version.
The sheer number of particle types would make a gpu implementation pretty tricky.. but for a vanilla version it can work.