![]() |
PK_GOSGMT_f_t |
typedef void (*PK_GOSGMT_f_t) ( --- received arguments --- const int *segtyp, const int *ntags, const int *tags, const int *ngeom, const double *geom, const int *nlntp, const int *lntp, --- returned arguments --- int *ifail ); Output non hierarchical segment
PK_SESSION_ask_fru_o_t
PK_SESSION_frustrum_t
PK_SESSION_register_fru_o_t
The arguments have the following significance :- segtyp: type of segment 'segtyp' - the type of the segment; one of the following values SGTPED = 2006; --- Edge SGTPSI = 2007; --- Silhouette line SGTPPH = 2008; --- Planar hatch-line SGTPRH = 2009; --- Radial hatch-line SGTPRU = 2010; --- Rib line (unfixed blend) SGTPBB = 2011; --- Blend-boundary line SGTPPL = 2012; --- Parametric hatch line SGTPFT = 2016; --- Facet SGTPER = 2018; --- Error segment SGTPGC = 2019; --- Geometry ... curve. SGTPGS = 2020; --- Geometry ... surface. SGTPGB = 2021; --- Geometry ... surface boundary. SGTPMF = 2022; --- Mangled facet SGTPVT = 2023; --- Visibility segment (used for hierarchical output) SGTPTS = 2024; --- Facet strip SGTPVP = 2025; --- Parametrised Visibility segment SGTPIC = 2026; --- Interference curve SGTPCL = 2027; --- Clip curve SGTPSF = 2028; --- Sharp-mfin polyline SGTPLB = 2031; --- Lattice ball SGTPLR = 2032; --- Lattice rod When rendering a list of entities Parasolid may encounter a body, face or edge that it is unable to render (e.g. a rubber face). In such cases, Parasolid outputs an error segment (SGTPER), giving the tag of the bad entity and a code indicating why it was unable to render it. Parasolid then continues to render the remaining entities. If, during a call to PK_TOPOL_render_facet, either * user tolerances can't be matched, or * facets are created which self intersect or are severely creased, then geometric data is output as a segment type SGTPMF. In this case, the facets are always triangular. This does not apply to geometry (i.e. SGTPGC, SGTPGS and SGTPGB). These are never replaced by error segments, unrenderable geometry segments are not output at all. If edges/silhouettes/hatchlines/sharp-mfins are being output hierarchically then GOSGMT is called to output the whole geometry of the item (optional) and again to output the positions at which the visibility changes on the item (a visibility segment). When using the 3D viewport option in hidden line, auxiliary lines that arise from clipping to viewport boundaries may be output. Such lines will have segment type marked SGTPCL. When using the overlap option in hidden line, auxiliary lines that arise from face - face intersections may be output. Such lines will have segment type marked SGTPIC. When using the 'sharp_mfins' option in PK_TOPOL_render_line_o_t, sharp mfins on meshes will be chained into polylines and may be output. Such polylines will have segment type SGTPSF. ntags, tags: tags associated with segment 'ntags', 'tags' - an array of tags associated with the segment. The tags given depend upon the segment type as follows: SGTPED - tag of edge (or none if edge output hierarchically) SGTPSI, SGTPPH, SGTPRH, SGTPSF - tag of face on which silhouette, hatch, or sharp-mfin line lies (or none if silhouette or hatchline output hierarchically) SGTPPL - tag of face or surface on which the parametric hatch line lies (or none if hatchline output hierarchically) SGTPRU, SGTPBB - tag of edge blended SGTPFT - tag of face on which facet lies SGTPMF - tag of face on which mangled facet lies SGTPTS - tag of face on which facet strip lies SGTPGC - tag of the curve SGTPGS - tag of the surface SGTPGB - tag of the surface for which this is a boundary curve SGTPVT - none SGTPER - tag of entity which could not be rendered SGTPVP - none SGTPLB, SGTPLR - tag of lattice to which the ball or rod belongs If edges, silhouettes, hatchlines or sharp-mfin lines are output hierarchically then the tag information is given by GOOPSG and GOCLSG. If regional data was requested in a call to PK_TOPOL_render_line two further tags are given for SGTPED and SGTPSI segments, identifying the faces either side of the line in the image. Either or both face tags may be null. If edge tags were requested in a call to PK_TOPOL_render_facet, for each edge of the facet the tag of the model edge from which it was derived is given; or a null tag if it is not derived from a model edge. The number of edge tags given equals the number of vertices given in 'geom'. The first edge tag ( tags[1] ) is the tag of the edge from which is derived the first facet edge (which ends at the first vertex given in geom). The second edge tag is for the facet edge which ends at the second vertex, and so on. If facet strips have been requested in a call to PK_TOPOL_render_facet the format for the edges tags is as follows:- If the strip has n vertices, then there are 2 * (n - 2) + 1 edge tags The i-th element of the tags array (starting at i = 1) is the tag of the edge between vertex, floor ( (i - 1) / 2 ) + 1 and vertex, floor (i / 2) + 2 where, floor (x) is the integer portion of x. ngeom, geom: geometry of segment 'ngeom', 'geom' - an array of reals giving the geometry of the segment. The values given depend upon the type of the geometry, as specified in the second element of 'lntp'. L3TPSL - straight line: ngeom = 9 start point, end point, line direction. L3TPCC - complete circle: ngeom = 7 centre point, axis direction, radius. The forward direction of the circle is clockwise when viewing the circle along the axis direction. L3TPCI - circular arc: ngeom = 13 centre point, axis direction, radius, start point, end point. The forward direction of the circle is given above. L3TPCE - complete ellipse: ngeom = 11 centre point, major axis direction, minor axis direction, major radius, minor radius The forward direction of the ellipse is clockwise when viewing the ellipse along the axis direction. The axis direction is the vector cross product of the major axis with the minor axis in that order. L3TPEL - elliptical arc: ngeom = 17 centre point, major axis direction, minor axis direction, major radius, minor radius, start point, end point The forward direction of the ellipse is given above. L3TPPY - poly line: 'geom' holds 'ngeom' vectors. L3TPPC - non-rational B-curve in Bezier form: 'geom' holds 'ngeom' vectors of dimension 3. These are the Bezier vertices of the curve. L3TPRC - rational B-curve in Bezier form: 'geom' holds 'ngeom' vectors of dimension 4. These are the Bezier vertices of the curve, where each Bezier vertex consists of a 3-space point and a weight. L3TPNC - non-rational B-curve in NURBs form: 'geom' holds 'ngeom' reals. These consist of lntp[9] vectors of dimension 3, which are the bspline vertices followed by lntp[10] reals which are the knots. So ngeom is equal to 3 times lntp[9] plus lntp[10]. L3TPRN - rational B-curve in NURBs form: 'geom' holds 'ngeom' reals. These consist of lntp[9] vectors of dimension 4, which are the bspline vertices where each vertex consists of a 3-space point followed by a weight. These are followed by lntp[10] reals which are the knots. So ngeom is equal to 4 times lntp[9] plus lntp[10]. L3TPFV - facet vertices: 'geom' holds 'ngeom' vectors defining the vertices of a facet. L3TPFN - facet vertices plus surface normals: 'geom' holds * 'ngeom'/2 vectors defining the vertices of a facet followed by * 'ngeom'/2 vectors defining the surface normals at the vertices. L3TPFP - facet vertices plus parameters 'geom' holds * 'ngeom'/2 vectors defining the vertices of a facet followed by * 'ngeom'/2 vectors defining the surface and curve parameters (u,v,t) of the vertex L3TPFI - facet vertices plus normals plus parameters 'geom' holds * 'ngeom'/3 vectors defining the vertices of a facet followed by * 'ngeom'/3 vectors defining the surface normals at the vertices followed by * 'ngeom'/3 vectors defining the surface and curve parameters (u,v,t) of the vertex L3TPF1 - facet vertices + normals + parameters + 1st derivs 'geom' holds * 'ngeom'/5 vectors defining the vertices of a facet followed by * 'ngeom'/5 vectors defining the surface normals at the vertices followed by * 'ngeom'/5 vectors defining the surface and curve parameters (u,v,t) of the vertex followed by * 'ngeom'/5 vectors defining the dP/du surface derivatives at the vertices followed by * 'ngeom'/5 vectors defining the dP/dv surface derivatives at the vertices Note: Derivatives are never output for bodies or faces with facet geometry, a segment of type L3TPFI will be returned rather than one of type L3TPF1. L3TPF2 - facet vertices + normals + parameters + all derivs 'geom' holds * 'ngeom'/8 vectors defining the vertices of a facet followed by * 'ngeom'/8 vectors defining the surface normals at the vertices followed by * 'ngeom'/8 vectors defining the surface and curve parameters (u,v,t) of the vertex followed by * 'ngeom'/8 vectors defining the dP/du surface derivatives at the vertices followed by * 'ngeom'/8 vectors defining the dP/dv surface derivatives at the vertices followed by * 'ngeom'/8 vectors defining the d2P/du2 surface derivatives at the vertices followed by * 'ngeom'/8 vectors defining the d2P/dudv surface derivatives at the vertices followed by * 'ngeom'/8 vectors defining the d2P/dv2 surface derivatives at the vertices Note: Derivatives are never output for bodies or faces with facet geometry, a segment of type L3TPFI will be returned rather than one of type L3TPF2. L3TPFC - facet vertices + normals + curvatures 'geom' holds * 'ngeom'/5 vectors defining the vertices of a facet followed by * 'ngeom'/5 vectors defining the surface normals at the vertices followed by * 'ngeom'/5 vectors defining the first principal direction of curvature of the face at the vertices followed by * 'ngeom'/5 vectors defining the second principal direction of curvature of the face at the vertices followed by * 'ngeom'/5 vectors defining the principal curvatures of the face at the vertices; the x component of the vector contains the first principal curvature of the face at the vertices, the y component of the vector contains the second principal curvature of the face at the vertices and the z component of the vector is always returned as zero. L3TPFD - facet vertices + normals + parameters + curvatures 'geom' holds * 'ngeom'/6 vectors defining the vertices of a facet followed by * 'ngeom'/6 vectors defining the surface normals at the vertices followed by * 'ngeom'/6 vectors defining the surface and curve parameters (u,v,t) of the vertex followed by * 'ngeom'/6 vectors defining the first principal direction of curvature of the face at the vertices followed by * 'ngeom'/6 vectors defining the second principal direction of curvature of the face at the vertices followed by * 'ngeom'/6 vectors defining the principal curvatures of the face at the vertices; the x component of the vector contains the first principal curvature of the face at the vertices, the y component of the vector contains the second principal curvature of the face at the vertices and the z component of the vector is always returned as zero. L3TPTS - facet strip vertices: 'geom' holds 'ngeom' vectors defining the vertices of a facet strip. L3TPTN - facet strip vertices plus surface normals: 'geom' holds * 'ngeom'/2 vectors defining the vertices of a facet strip followed by * 'ngeom'/2 vectors defining the surface normals at the vertices. L3TPTN - facet strip vertices plus parameters: 'geom' holds * 'ngeom'/2 vectors defining the vertices of a facet strip followed by * 'ngeom'/2 vectors defining the surface and curve parameters (u,v,t) of the vertex L3TPTI - facet strip vertices plus normals plus parameters: 'geom' holds * 'ngeom'/3 vectors defining the vertices of a facet strip followed by * 'ngeom'/3 vectors defining the surface normals followed by * 'ngeom'/3 vectors defining the parameters of the vertex L3TPT1 - facet strip vertices + normals + parameters + 1st derivs 'geom' holds * 'ngeom'/5 vectors defining the vertices of a facet strip followed by * 'ngeom'/5 vectors defining the surface normals at the vertices followed by * 'ngeom'/5 vectors defining the surface and curve parameters (u,v,t) of the vertex followed by * 'ngeom'/5 vectors defining the dP/du surface derivatives at the vertices followed by * 'ngeom'/5 vectors defining the dP/dv surface derivatives at the vertices Note: Derivatives are never output for bodies or faces with facet geometry, a segment of type L3TPTI will be returned rather than one of type L3TPT1. L3TPT2 - facet strip vertices + normals + parameters + all derivs 'geom' holds * 'ngeom'/8 vectors defining the vertices of a facet strip followed by * 'ngeom'/8 vectors defining the surface normals at the vertices followed by * 'ngeom'/8 vectors defining the surface and curve parameters (u,v,t) of the vertex followed by * 'ngeom'/8 vectors defining the dP/du surface derivatives at the vertices followed by * 'ngeom'/8 vectors defining the dP/dv surface derivatives at the vertices followed by * 'ngeom'/8 vectors defining the d2P/du2 surface derivatives at the vertices followed by * 'ngeom'/8 vectors defining the d2P/dudv surface derivatives at the vertices followed by * 'ngeom'/8 vectors defining the d2P/dv2 surface derivatives at the vertices Note: Derivatives are never output for bodies or faces with facet geometry, a segment of type L3TPTI will be returned rather than one of type L3TPT2. L3TPTC - facet strip vertices + normals + curvatures 'geom' holds * 'ngeom'/5 vectors defining the vertices of a facet strip followed by * 'ngeom'/5 vectors defining the surface normals at the vertices followed by * 'ngeom'/5 vectors defining the first principal direction of curvature of the face at the vertices followed by * 'ngeom'/5 vectors defining the second principal direction of curvature of the face at the vertices followed by * 'ngeom'/5 vectors defining the principal curvatures of the face at the vertices; the x component of the vector contains the first principal curvature of the face at the vertices, the y component of the vector contains the second principal curvature of the face at the vertices and the z component of the vector is always returned as zero. L3TPTD - facet strip vertices + normals + parameters + curvatures 'geom' holds * 'ngeom'/6 vectors defining the vertices of a facet strip followed by * 'ngeom'/6 vectors defining the surface normals at the vertices followed by * 'ngeom'/6 vectors defining the surface and curve parameters (u,v,t) of the vertex followed by * 'ngeom'/6 vectors defining the first principal direction of curvature of the face at the vertices followed by * 'ngeom'/6 vectors defining the second principal direction of curvature of the face at the vertices followed by * 'ngeom'/6 vectors defining the principal curvatures of the face at the vertices; the x component of the vector contains the first principal curvature of the face at the vertices, the y component of the vector contains the second principal curvature of the face at the vertices and the z component of the vector is always returned as zero. L3TPCS - complete sphere: ngeom = 4 'geom' holds 1 vector corresponding to the centre of the sphere, together with the radius of the sphere. L3TPCY - complete cylinder: ngeom = 7 'geom' holds 2 vectors corresponding to the start and end of the cylindrical segment, together with the radius of the cylinder. L3TPCN - complete truncated cone: ngeom = 8 'geom' holds 2 vectors corresponding to the start and end of the conical segment, together with the start radius and end radius. If a facet has multiple loops the outer loop is output first and the inner loops follow. The vertices of the outer loop are ordered anticlockwise when viewed down the surface normal. The vertices of inner loops are ordered clockwise. Facets are manifold; i.e. no vertex coincides with any other in the same facet, nor does it lie in any edge in the same facet. For facet strips the vertices of the first facet in the strip are held in elements 0,1 and 2 of 'geom' and are ordered anticlockwise when viewed down the surface normal. The vertices of the second facet are held in elements 1,2 and 3 and are ordered clockwise. The vertices of the n-th facet are held in elements n-1, n and n+1 and are ordered anticlockwise if n is odd and clockwise if n is even. If lntp[1] is L3TPTS then the number of facets in a strip is given by 'ngeom' - 2. If lntp[1] is L3TPTN then the number of facet is given by 'ngeom'/2 - 2. For visibility segments (SGTPVT/SGTPVP) geom contains the visibility transition points (i.e. vectors in model space at which the edge changes visibility). Segments of type SGTPVP contain parameters as well. If the edge has only one visibility then no geometry is output. The geometry array in an unparametrised (SGTPVT) visibility segment holds a sequence of sets of three doubles {x,y,z} corresponding to the vector position of the transition points in model space. The geometry array in a parametrised (SGTPVP) visibility segment holds a sequence of sets of four doubles {x,y,z,t} corresponding to the vector position of the transition points and their parameter on the geometry segment. For error segments (SGTPER) 'ngeom' is zero. nlntp, lntp: type of geometry and other codes 'nlntp', 'lntp' - an array of integers specifying the type of geometry of the segment and other codes as follows: lntp[0] - Occurrence number of the entity from which the segment was derived. If the segment type is SGTPER lntp[1] - Reason why Parasolid is unable to render the entity: ERNOGO = 4001; --- Unspecified error ERRUBB = 4002; --- Rubber entity (no geometry attached) ERSANG = 4003; --- Surface angular tolerance too small ERSDIS = 4004; --- Surface distance tolerance too small ERCANG = 4005; --- Curve angular tolerance too small ERCDIS = 4006; --- Curve distance tolerance too small ERCLEN = 4007; --- Chord chord length tolerance too small ERFWID = 4008; --- Facet width tolerance too small ERIFMF = 4009; --- Incremental Facetting: has missing face ERIFRE = 4010; --- Incremental Facetting: refinement required ERIFER = 4011; --- Incremental Facetting: unspecified error ERIFRM = 4012; --- Incremental Facetting: required missing face ERIFRR = 4013; --- Incremental Facetting: required due to refinement If the segment type is SGTPVT or SGTPVP * lntp contains an array of visibility codes for the edge/sharp-mfin line/silhouette/hatchline. * lntp+nlntp holds the smoothness codes for the edge/sharp-mfin line. * If any of the 'region', 'viewport_clipping' or 'sharp_mfins' options of PK_TOPOL_render_line_o_t were switched on in a call to PK_TOPOL_render_line, the lntp array will contain further information after the smoothness codes. See the Parasolid Downward Interfaces manual for more information. Otherwise lntp[1] - Geometry type; one of the values: L3TPSL = 3001; --- Straight line L3TPCI = 3002; --- Partial circle L3TPCC = 3003; --- Complete circle L3TPEL = 3004; --- Partial ellipse L3TPCE = 3005; --- Complete ellipse L3TPPY = 3006; --- Poly-line L3TPFV = 3007; --- Facet vertices L3TPFN = 3008; --- Facet vertices plus surface normals L3TPPC = 3009; --- Non-rational B-curve (Bezier) L3TPRC = 3010; --- Rational B-curve (Bezier) L3TPTS = 3011; --- Facet strip vertices L3TPTN = 3012; --- Facet strip vertices plus surface normals L3TPNC = 3013; --- Non-rational B-curve (NURBs form) L3TPRN = 3014; --- Rational B-curve (NURBs form) L3TPFP = 3015; --- Facet vertices plus parameters L3TPFI = 3016; --- Facet vertices plus norms plus parameters L3TPTP = 3017; --- Facet strip vertices plus parameters L3TPTI = 3018; --- Facet strip verts plus norms plus params L3TPF1 = 3019; --- Facet verts + norms + params + 1st derivs L3TPF2 = 3020; --- Facet verts + norms + params + all derivs L3TPT1 = 3021; --- Facet strip verts+norms+params+1st derivs L3TPT2 = 3022; --- Facet strip verts+norms+params+all derivs L3TPFC = 3023; --- Facet verts + norms + curvatures L3TPFD = 3024; --- Facet verts + norms + params + curvatures L3TPTC = 3025; --- Facet strip verts + norms + curvatures L3TPTD = 3026; --- Facet strip verts+norms+params+curvatures L3TPCS = 3027; --- Complete sphere L3TPCY = 3028; --- Complete cylinder L3TPCN = 3029; --- Complete truncated cone If the geometry type is anything except L3TPCS, L3TPCY, L3TPCN, L3TPF* or L3TPT*: lntp[2] - Completeness; one of the values CODCOM = 1001; --- Segment complete CODINC = 1002; --- Segment incomplete CODUNC = 1003; --- Segment may or may not be complete CODOVP = 1004; --- Segment is out of viewport CODCVP = 1005; --- Segment coincides with a viewport boundary lntp[3] - Visibility; one of the values CODVIS = 1006; --- Line segment is visible CODINV = 1007; --- Line segment is invisible CODUNV = 1008; --- Visibility of line segment is unknown CODDRV = 1009; --- Line segment drafted visible CODISH = 1022; --- Line segment is invisible (hidden by own body occ) lntp[4] - Smoothness; one of the values CODSMO = 1014; --- Edge is "smooth" CODNSM = 1015; --- Edge is not "smooth" CODUNS = 1016; --- Edge "smoothness" is unknown CODSMS = 1017; --- Edge "smooth" but coincident with silhouette CODNSS = 1013; --- Edge/sharp-mfin line is not "smooth" but coincident with silhouette lntp[5] - Internal edge; one of the values CODINE = 1018; --- Edge is internal CODNIN = 1019; --- Edge is not internal CODINU = 1020; --- Not known whether edge is internal CODINS = 1021; --- Edge is internal, coincides with silhouette CODIGN = 1023; --- Edge lies on boundary of ignorable feature If segtyp is SGTPGC, SGTPGS or SGTPGB the lntp[2..5] are always lntp[2] = CODUNC = 1003; --- Segment may or may not be complete lntp[3] = CODUNV = 1008; --- Visibility of segment is unknown lntp[4] = CODUNS = 1016; --- "smoothness" is unknown lntp[5] = CODINU = 1020; --- Not known whether internal If regional data was requested in a call to PK_TOPOL_render_line lntp[6] and lntp[7] contain start and end point indices for SGTPED and SGTPSI segments. The indices uniquely identify the image points at each end of the segment. If the 'sharp_mfins' option of PK_TOPOL_render_line_o_t was set to PK_render_sharp_mfins_yes_c in a call to PK_TOPOL_render_line and segtyp is SGTPED: lntp[11] - Coincidence with a sharp mfin polyline; one of the values CODESF = 1024; --- Edge is coincident with sharp mfins CODNES = 1025; --- Edge is not coincident with sharp mfins CODUES = 1026; --- Edge coincidence with sharp mfins unknown Non-wire edges will always be output with code CODNES as they lie along laminar mfins which are by definition not sharp. If the geometry type is L3TPF* : lntp[2] - Number of loops in facet. lntp[3], lntp[4], ... - The number of vertices in each loop. If the geometry type is L3TPT* : lntp[2] - Number of vertices in the facet strip. If the geometry type is L3TPPC or L3TPRC: lntp[8] is the degree of the parametric curve If the geometry type is L3TPNC or L3TPRN: lntp[8] is the degree of the NURBs curve lntp[9] is the number of b-spline vertices lntp[10] is the number of knots If the geometry type is L3TPCS, L3TPCY or L3TPCN, lntp is an array of length 2 specifying the occurrence number and geometry type only. If segtyp type is SGTPMF there is one loop consisting of three vertices. If segtyp type is SGTPSI then the last element in the ltp array is the silhouette label. ifail: 'ifail' - a code indicating whether the Frustrum wants to abort graphic output. One of the values: CONTIN = 0; --- Continue: no errors ABORT = -1011; --- Abort: return control to caller