shadeops / houdini-pbrt-v4

Houdini exporter for pbrt-v4
BSD 2-Clause "Simplified" License
11 stars 2 forks source link

RGBGrid Example #12

Closed renderdude closed 7 months ago

renderdude commented 7 months ago

Great stuff Jim.

Do you have an example of how to setup an RGBGridMedium? I was trying to use a billowy smoke pyro sop, but I can't get it to export the material.

I was able to use a straight volume and a cloud medium, but for a project need a wispier source.

shadeops commented 7 months ago

To setup a RGBGridMedium is completely non-obvious. (I really should make some help cards for some of this stuff, or at least a walk through YouTube video.)

To use the RGBGridMedium pbrt-v4 requires 6 volume fields instead of the normal 1 for a simple density based smoke field.

The 6 fields it requires are

I've attached a simple example that shows how to set it up. It focuses on using the Cd fields in a sim, then converting the Cd fields to sigma_s. Then depending on the look you want you can derive sigma_a in different ways. (Which is what the Switch SOP demos).

rgb_grid_example.hiplc.gz

Also, NanoVDBs are supported too. Which mean in your Houdini scene you can work with straight VDB primitives, and as long as you have nanovdb_convert (part of the OpenVDB distribution) in your path then your VDB prims will automatically be converted.

Pretty much any input pbrt-v4 supports, the converted can handle. Though as you've seen some guidance may be needed, so feel free to ask other questions (preferably as other tickets).

renderdude commented 7 months ago

Thanks. That's what I'm looking for. Now to translate it over to a .hip file. Can we make an 'examples' directory in the repo and start adding a few of these there?

shadeops commented 7 months ago

Yup I'll add the example hip in the previous comment as well as a few others to the repo.