SippBezierPatcho Command

SippBezierPatch resolution vertexlist patchlist shaderhandle [texture]

Define an object using a Bezier patch. resolution is the number of polygons to tessellate the surface into. Vertexlist is a list of vertices of the curve. Each element of the list is a list contain the X, Y and Z vertices.

Patchlist is list of indices into vertexlist that defined the patch. Each element of the list contains a list 4 lists. Each of these lists contain 4 indices. The indices are zero based. For example:

    {{ 0  1  2  3} {35 36 37 38} {28 29 30 31} {21 22 23 24}}
    {{21 22 23 24} {14 15 16 17} { 7  8  9 10} { 0  1  2  3}}
    {{ 3  4  5  6} {38 39 40 41} {31 32 33 34} {24 25 26 27}}
    {{ 6  5  4  3} {13 12 11 10} {20 19 18 17} {27 26 25 24}}}

Shaderhandle is handle to a previously created surface shading specification.

Texture is the texture mapping algorithm to use for the object. The texture coordinates are a bit special for the Bezier patches. CYLINDRICAL and SPHERICAL coordinates are not applicable, if they are specified, SIPP will use NATURAL anyway. The NATURAL mapping is a two dimensional mapping using the surface parameters u and v, see figure below. Note that these parameters range from 0 to 1 within each patch! Optional, WORLD is the default.

An object handle is returned.