...
In Katana, you will most likely bring in a subdivision surface via Alembic or some other geometry format that supports them. You as an artist are not likely to have to do anything special to utilize them in Katana. In Maya, using the RenderMan Archive workflow, you can embed the settings used on your geometry and RfK should simply use them as set.
Any texture coordinates or other primitive variables that you need for look development must be added upstream in your pipeline. They will be available when you import your geometry into Katana.
Info |
---|
To set an object that is ingested as a polymesh into a subdivision mesh requires you use an AttributeSet node with the string value set to subdmesh and the path to your required object. The PrmanObjectStatements can be added to specify the type of SubD Mesh (Catmull-Clark, Loop, etc.) The default is Catmull-Clark. However, the OpScript provided below on this page should match the default from Maya and Houdini should you need to match them (recommended) |
Info |
---|
Speed Trick: If your subdivision surface is off-screen or the pixel coverage is very small, it may make sense to convert the subdivision surface to a polygonal surface. This will save memory in your render, will shorten the time to seeing the first pixel, and depending on your scene complexity, will reduce render times. To change your geometry from a subdivision surface to a polygonal surface, use an AttributeSet node to set the "type" of the geometry to polymesh. Below is a screen snapshot of what you will need to do. |
...
- Create an OpScript node
- In the CEL section, select the mesh(es) where you wish to apply the attributes. In this case we've added the subdmeshes from Maya
- Custom CEL statements
- /root/world/geo//*{@type == "polymesh"}
- /root/world/geo//*{@type == "subdmesh"}
In the script section add the following:
Code Block language py title OpScript for Subdivs cpp Interface.SetAttr('geometry.facevaryinginterpolateboundary', IntAttribute(3)) Interface.SetAttr('geometry.facevaryingpropagatecorners', IntAttribute(0)) Interface.SetAttr('geometry.interpolateBoundary', IntAttribute(1)) Interface.DeleteAttr('geometry.vertex.N') Interface.SetAttr('type', StringAttribute('subdmesh'))
- Custom CEL statements
- In the CEL section, select the mesh(es) where you wish to apply the attributes. In this case we've added the subdmeshes from Maya
- We set several attributes above to match the Maya settings. Below we list the other options should you need to experiment.
- Options for geometry.facevaryinterpolateboundary
- 0 (old style)
- 1 (new style)
- 2 (new style, no corners)
- 3 (new style, smooth internal only) This is the current Maya default
- Options for 'geometry.facevaryingpropogatecorners'
- 0 (off) This is Maya default
- 1 (on)
- Options for 'geometry.interpolateBoundary'
- 0(no interpolation)
- 1(edge crease, corner crease) This is the Maya default
- 2(edge crease only)
- geometry.vertex.N'
- We delete the existing normals off the mesh as RenderMan will create its own for a subdivision mesh. This is explained in the above section.
- 'type'
- Changes the mesh to a subdivision surface
- Options for geometry.facevaryinterpolateboundary
...
- geometry.facevaryinginterpolateboundary
- geometry.facevaryingpropagatecorners
- geometry.interpolateBoundary
...