Adjust the bifrostLiquidMaterial attributes: workflow example
The bifrostLiquidMaterial shader can either render the mesh that you generate from the liquid, or render the liquid voxels' isosurface directly. In this example, use the voxels for test renders while you adjust the shader attributes.
Select
Window > Rendering Editors > Render Settings, and make sure that
Render Using is set to
mental ray.
Go to the end of the simulation, and render the current frame.
Notice how the liquid is almost completely transparent. You can add some detail such as reflections and decrease transparency in the more turbulent areas of the liquid where foam might appear.
Since foam would be strongly affected by vorticity in real life, you can use the
Vorticity channel to control some of the material's properties, like its transparency and diffuse color.
Select the
liquid and click the
bifrostLiquidMaterial tab in the
Attribute Editor.
Under
Refraction/Transmission, make the following adjustments to make the water less transparent in areas of high vorticity:
Set the Color Remap Channel
to
Vorticity.
Expand
Refraction Color Remap, set the right hand color marker to middle grey (H:150, S:0, V: 0.24).
By setting the right marker to grey instead of full black, you still leave it partially transparent.
Set the
Transparency Remap Channel to
Vorticity.
If you render, the effect of transparency might still be a bit strong, so you can adjust the transparency weight values. In the
Transparency Weight Remap, set the ramp's left control to a value of 0.71.
You only want diffuse reflections to appear where there is relatively high vorticity in the liquid. Select
Diffuse and set the
Color Remap Channel to Vorticity.
Set the
Diffuse Color Remap so that very little color is added to areas of low vorticity while lighter green color is added to areas of higher vorticity. For example, set the left color marker to a very dark blue (H: 221, S 0.89, V 0.04) and the right color marker to gray/green (H: 150, S: 0.5 V: 056).
Remap the values to skew the distribution of diffuse color, so that only the areas of high vorticity are colored green. Click inside the
Diffuse Color Remap ramp to create a new point control to skew the diffuse color values:
Selected Position: 0.9
Selected Value: 0.240
Render the current frame again.
Use these material settings to render your Bifröst liquid mesh.