04/04/2015

Use of Temperature over Density in Fluid Dynamics

Through experimenting with the settings of the guild dynamics systems I've found two ways to achieve the look i want.

The first method uses the density of the voxels in the fluid container, and applies a colour ramp based on the value. Meaning more the higher the density in the container, the brighter the colour. This relies on the opacity ramp being set to apply to the density, not the temperature and i think it looks passable.


I like the way it seems to spill out of the crevices in the torch model, but it is quite soft around the edges, especially in the less dense areas around the top of the flame.

The alternative method, more similar to what i experimented with using the candle flame, is using the temperature to determine colour. Whilst this looks very nice and has a slightly more realistic appearance it takes far longer to calculate, as the temperature is another layer of calculations added into the fluid simulation. I found that working with the temperature controlled container it would increase the render time very rapidly especially past the 30 frame mark. 

It seems that some of my settings are making it continue to simulate the fluid long past the point it is still visible, as with the container set to automatically grow it ends up 4 or 5 times larger than using the density method, meaning more calculations per frame.


I also experimented with making the flame collide with the torch, which whilst the physics behind it may be more realistic, it seemed to leave holes in the back of the fire when the torch was moved, and didn't add any meaningful benefits to my tests.

No comments:

Post a Comment