Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ PEXQuadrilateralMesh(3) — Open3D 4.96

Media Vault

Software Library

Restoration Projects

Artifacts Sought

PEXQuadrilateralMesh(3)  —  Subroutines

Name

PEXQuadrilateralMesh - 3D Quadrilateral Mesh Primitive

Synopsis

void PEXQuadrilateralMesh(Display ∗display, XID resource_id, PEXOCRequestType req_type, int shape_hint, unsigned int facet_attributes, unsigned int vertex_attributes, int color_type, PEXArrayOfFacetData facet_data, unsigned int col_count, unsigned int row_count, PEXArrayOfVertex vertices)

Arguments

displayA pointer to a display structure returned by a successful XOpenDisplay call. 

resource_idThe resource identifier of the renderer or structure. 

req_typeThe request type for the output command (PEXOCRender, PEXOCStore, PEXOCRenderSingle or PEXOCStoreSingle).

shape_hintThe shape which describes all of the quadrilaterals (PEXShapeComplex, PEXShapeNonConvex, PEXShapeConvex, PEXShapeUnknown).

facet_attributes
A mask indicating the facet attributes provided (PEXGANone, PEXGAColor, PEXGANormal).

vertex_attributes
A mask indicating the vertex attributes provided (PEXGANone, PEXGAColor, PEXGANormal).

color_typeThe type of color data provided (PEXColorTypeIndexed, PEXColorTypeRGB, PEXColorTypeCIE, PEXColorTypeHSV, PEXColorTypeHLS, PEXColorTypeRGB8, PEXColorTypeRGB16).

facet_dataAn array of facet data. 

col_countThe number of columns in the vertex array. 

row_countThe number of rows in the vertex array. 

verticesA two-dimensional (row-major) array of vertices defining the quadrilateral mesh. 

Returns

None

Description

This function creates a quadrilateral mesh output primitive. 

The quadrilateral mesh surface is created from the vertices.  The vertex array is accessed in row major order (i.e. the column number varies fastest as vertices are accessed).  The (ith, jth), (i+1th, jth), (i+1th, j+1th), and (ith, j+1th) vertices are connected to create a single facet.  Adjacent vertices are interconnected until the entire facet network is processed. 

Normals for quadrilaterals, if not provided explicitly, are computed by taking the cross product of the diagonals.  For a quadrilateral with the above vertices, the cross product would be formed as follows:

normal(i,j) = (point(i+1, j+1) - point(i, j)) X (point(i, j+1) - point(i+1, j))

Normals are assumed to be unit length vectors.  If not unit length, the result is implementation-dependent. 

There must be an entry in the facet data array for each facet, if facet data is indicated by the facet attributes. 

All other aspects of this primitive are the same as PEXFillAreaSetWithData.

Data Structures

See the PEXStructuresman page.

Errors

BadPEXOutputCommand
The output command contains an invalid value.

BadPEXRenderer
The specified renderer resource identifier is invalid.

BadPEXStructure
The specified structure resource identifier is invalid.

See Also

PEXSetInteriorStyle, PEXSetInteriorStyleIndex, PEXSetSurfaceColorIndex,
PEXSetSurfaceColor, PEXSetReflectionAttributes, PEXSetReflectionModel,
PEXSetSurfaceInterpMethod, PEXSetBFInteriorStyle, PEXSetBFInteriorStyleIndex,
PEXSetBFSurfaceColorIndex, PEXSetBFSurfaceColor, PEXSetBFReflectionAttributes,
PEXSetBFReflectionModel, PEXSetBFSurfaceInterpMethod, PEXSetFacetCullingMode,
PEXSetFacetDistinguishFlag, PEXSetPatternSize,
PEXSetPatternAttributes, PEXSetPatternAttributes2D, PEXSetInteriorBundleIndex,
PEXSetSurfaceEdgeFlag, PEXSetSurfaceEdgeType, PEXSetSurfaceEdgeWidth,
PEXSetSurfaceEdgeColor, PEXSetSurfaceEdgeColorIndex, PEXSetEdgeBundleIndex

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026