Clipping a density volume with an SDF or object surface?
Posted: Tue Aug 11, 2020 7:07 pm
Hey, I'm currently evaluating Octane in Houdini.
I'm trying to set up a fluid surface with internal scattering and absorption, but I want it to be variable and defined by vdb volumes.
I've got this working great, up to a point. I can have separate volumes defining each effect as a volume object, and a separate mesh as the liquid surface - pathtracing works perfectly for letting light refract through the surface and scatter inside the volumes.
What I'm looking to do is clip the volume density values using either an SDF volume of the surface (multiply density by "is SDF < 0.0") or just by only rendering the volumes where they're inside the surface itself. Otherwise, there's ineviably aliasing issues near the liquid surface, where corners of voxels will "poke out", unless I upscale the volume resolution considerably, and then specifically fade-off the density to zero one voxel-depth beneath the surface, which isn't ideal.
Is there any way to do this in Octane without writing a whole bespoke OSL shader from the ground up? Is there any way to modify the inbuilt shaders?
I'm trying to set up a fluid surface with internal scattering and absorption, but I want it to be variable and defined by vdb volumes.
I've got this working great, up to a point. I can have separate volumes defining each effect as a volume object, and a separate mesh as the liquid surface - pathtracing works perfectly for letting light refract through the surface and scatter inside the volumes.
What I'm looking to do is clip the volume density values using either an SDF volume of the surface (multiply density by "is SDF < 0.0") or just by only rendering the volumes where they're inside the surface itself. Otherwise, there's ineviably aliasing issues near the liquid surface, where corners of voxels will "poke out", unless I upscale the volume resolution considerably, and then specifically fade-off the density to zero one voxel-depth beneath the surface, which isn't ideal.
Is there any way to do this in Octane without writing a whole bespoke OSL shader from the ground up? Is there any way to modify the inbuilt shaders?