The RenderMan Interface - Paul Bourke
The RenderMan Interface - Paul Bourke
The RenderMan Interface - Paul Bourke
- No tags were found...
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
RtFloat knot[12] = { 0,0,0,1,1,2,2,3,3,4,4,4 };<br />
RtFloat min[1] = { 0 };<br />
RtFloat max[1] = { 4 };<br />
RtInt n[1] = { 9 };<br />
RtFloat u[9] = { 1.0, 1.0, 1.0, 0.0, 0.0, 0.0, 1.0, 1.0, 1.0 };<br />
RtFloat v[9] = { 0.5, 1.0, 2.0, 1.0, 0.5, 0.0, 0.0, 0.0, 0.5 };<br />
RtFloat w[9] = { 1.0, 1.0, 2.0, 1.0, 1.0, 1.0, 2.0, 1.0, 1.0 };<br />
RiTrimCurve (nloops, ncurves, order, knot, min, max, n, u, v, w);<br />
SEE ALSO<br />
RiNuPatch, RiSolidBegin<br />
5.3 Subdivision Surfaces<br />
<strong>The</strong> <strong>RenderMan</strong> <strong>Interface</strong> includes support for subdivision surfaces. Ordinary cubic B-<br />
spline surfaces are rectangular grids of tensor-product patches. Subdivision surfaces generalize<br />
these to control grids with arbitrary connectivity. <strong>The</strong> API for subdivision surfaces<br />
looks a lot like RiPointsPolygons, with additional parameters to permit the specification<br />
of scheme-specific and implementation-specific enhancements.<br />
A subdivision surface, like a parametric surface, is described by its control mesh of points.<br />
<strong>The</strong> surface itself can approximate or interpolate this control mesh while being piecewise<br />
smooth. Furthermore, its control mesh is not confined to be rectangular, which is a major<br />
limitation of NURBs and uniform B-splines. In this respect, the control mesh is analogous<br />
to a polygonal description. But where polygonal surfaces require large numbers of<br />
data points to approximate being smooth, a subdivision surface is smooth — meaning that<br />
polygonal artifacts are never present, no matter how the surface animates or how closely it<br />
is viewed.<br />
RiSubdivisionMesh ( RtToken scheme, RtInt nfaces, RtInt nvertices[], RtInt vertices[],<br />
RtInt ntags, RtToken tags[], RtInt nargs[],<br />
RtInt intargs[], RtFloat floatargs[], ...parameterlist...)<br />
RiSubdivisionMesh defines a subdivision mesh or surface obeying the subdivision<br />
scheme specified by scheme. <strong>The</strong> only standard scheme is ”catmull-clark”, specifying<br />
the Catmull-Clark subdivision method. Implementations may also support other<br />
schemes. <strong>The</strong> subdivision mesh is made up of nfaces faces. <strong>The</strong> array nvertices,<br />
of length nfaces, contains the number of vertices in each face. <strong>The</strong> array vertices<br />
contains, for each face vertex, an index into the vertex primitive variable arrays. <strong>The</strong><br />
array vertices has a length equal to the sum of all the values in the array nvertices.<br />
All the arrays are 0-based.<br />
75