pathToSchemaFiles
const char *
Path to the directory where schema files are located.
useBulletinBoard
PK_LOGICAL_t
Whether to enable automatic updates.
The useBulletinBoard argument will in general be PK_false. However, if
you wish to try out a new, undocumented feature of the integration, you may
pass PK_true as the useBulletinBoard argument. In this case, HP_Render_Entity
and HP_Delete_Entity_Geometry should never be called; instead, after
each Parasolid operation, a single call to HP_Update(void) will populate (and
de-populate) the HOOPS database with the appropriate geometry by analyzing
the Parasolid bulletin board. Contact support@techsoft3d.com if
you require information or assistance with using this feature, which should
be considered as being in a beta stage of development.
filename
const char *
Name of the Parasolid File to be parsed.
file_partition
PK_PARTITION_t
Partition to load parts into.
num_parts
int *
Pointer to number of parts loaded.
parts
PK_PART_t**
Pointer to array of parts loaded.
options
PK_PART_receive_o_t *
Pointer to receive options structure.
error
PK_ERROR_code_t
Error code (zero if OK).
When the caller is finished with this array, the caller should use PK_MEMORY_free(*parts)
to free the allocated memory.
Num_parts indicates the number of parts in the array.
If the file contains assemblies, then these assemblies, and any instances within them, are expanded into PK_BODY entities. Instanced entities are copied to become full-fledged PK_BODY entities. The returned array of PK_PART entities will not contain any assemblies.
If NULL is passed as the value for options, then default values will be used for transmitting the file, except that the default format will be the text format.
See the Parasolid documentation of the PK_PART_receive function for further
details; HP_Read_Xmt_File is function is similar to this Parasolid call.
filename
const char *
Name of file to save to.
parts
PK_PART_t *
Array of parts to save.
n_parts
int
Number of parts to save.
options
PK_PART_transmit_o_t *
Pointer to transmit options structure.
error
PK_ERROR_code_t
Parasolid error code.
count
unsigned long
number of Parasolid entities in the entities array.
entities
PK_ENTITY_t *
Array of Parasolid entity tagIDs.
PreserveSegments
bool true = delete geometry only, preserve segment structure
count
unsigned long
number of Parasolid entities in the entities array
entities
PK_ENTITY_t *
Array of Parasolid entities
transf
PK_TRANSF_t
Transformation matrix ID for view dependent tesselation (default is 0)
entity
PK_ENTITY_t
Parasolid entity
transf
PK_TRANSF_t
Transformation matrix ID for view dependent tesselation (default is 0)
flatten_assembly
bool
indicates whether or not assemblies contained within an XT file are to be flattened
list
string
A quoted string or a string variable containing a list of the desired settings.
[no] create body segments [= on, off]
Controls how each Parasolid Body entity is mapped to the HOOPS segment tree.
When you specify "create body segments = on", a HOOPS segment is created for each Parasolid body. These HOOPS segments are created as sub segments of the currently open segment. This is useful when you wish to apply unique HOOPS display/rendering attributes to a group of geometric primitives representing a Parasolid Body, or expect to apply additional transformations to individual Parasolid Bodies.
When you specify "create body segments = off", no extra HOOPS segments are created for individual bodies when they are rendered.
The default is "create body segments".
Controls how the Parasolid face entities are mapped to HOOPS shell primitives.
When you specify "merge faces", when each subsequent PK_BODY is finished being rendered, the HOOPS shells that have been generated (one for each face) will be merged together into a single shell. In the case of a multi-colored PK_BODY, the shells corresponding to PK_FACES that have the same color attribute will be merged into one HOOPS shell, resulting in as many HOOPS shells are there are distinct colors in the PK_BODY entity. This mapping results in optimal rendering speed at the expense of ease of manipulating individual PK_FACE entities. Applications that are concerned only with viewing, or that do not need to select at the PK_FACE level (to perform 'face level' Parasolid operations) may gain rendering speed advantages by making use of this feature.
When you specify "no merge faces", one HOOPS shell remains for each PK_FACE rendered. This mode is required if your application must interact with individual PK_FACEs.
The default is "no merge faces".
Controls whether the Parasolid rendered geometry will be partitioned into separate HOOPS segments based on color attributes. This will result in correct rendering of the geometry while maximizing performance by grouping like-colored geometry into the same segment.
When you specify "preserve color = on" , then a HOOPS segment is created for each unique color in the Parasolid geometry being rendered. These HOOPS segments are created as sub segments of the currently open segment. When specified in conjunction with "create body segments = on", the segment that is currently open at the time the color segments are created will be the segment that is unique to the PK_BODY being rendered. Otherwise, the currently open segment will be whatever HOOPS segment the user has opened at the time that the PK_TOPOL_render_facet or PK_TOPOL_render_line is called. Within each created HOOPS segment, the color attributes of the segment will be set (for lines and faces) to the appropriate values.
When you specify "preserve color = off", then color attributes in the Parasolid geometry are ignored when HOOPS geometry is created.
The default is "preserve color".
In addition to segments created for each unique color attribute set in the Parasolid geometry being rendered, one additional segment will be created if there is any Parasolid geometry that does not have any color attribute set on it. This segment, like the colored segments, will be created as a child segment of the currently open segment and a sibling segment of any colored segments if any exist. No color attributes will be set in this segment.
Parasolid PK_EDGEs in general do not have color attributes attached to them. If an edge itself does not have a color attribute attached, then these edges are treated as if they have the color attribute of their owning face. However, an edge may have more than one owning face (usually an edge will have two owning faces), and each of the owning faces may have a different color attribute. In this unusual case, the color of the PK_EDGE is undefined, and may be assigned a color of any one of its owning faces.
If you wish for PK_EDGEs to ignore color attributes, but you do want faces to be colored by their color attributes, then you can set a global color attribute for line color and specify an "attribute lock" on line color, which will override the line color attributes set in the created color segments (in the HOOPS world, Parasolid PK_EDGEs will correspond to HOOPS line entities, not HOOPS edge entities). As an example of how to do this, you could, in the same segment that is open when you call PK_TOPOL_render_xxxx, call the following two functions:
HC_Set_Color("lines = white");
HC_Set_Rendering_Options("attribute lock = (color = (lines))");
line_options
PK_TOPOL_render_line_o_t *
Parasolid options structure.
go_options
PK_TOPOL_render_facet_go_o_t *
Parasolid options structure.
generation_settings
PK_TOPOL_facet_mesh_o_t *
Parasolid options structure.
options
character string
a string which the function will write the current rendering options into
line_options
PK_TOPOL_render_line_o_t *
Parasolid options structure. Returned to user. Passed by reference.
go_options
PK_TOPOL_render_facet_go_o_t *
Parasolid options structure. Returned to user. Passed by reference.
generation_settings
PK_TOPOL_facet_mesh_o_t *
Parasolid options structure. Returned to user. Passed by reference.
tagID
PK_ENTITY_t
The Tag ID for the Parasolid entity provided for conversion.
max_count
long
Maximum number of keys that should be returned.
list
string
A quoted string or string variable specifying the particular types of Parasolid geometry that should be converted.
keys
HC_KEY *
Array of associated HOOPS keys. Returned to user.
count
long
Actual number of keys returned to user in keys array. Always less than or equal to max_count. Returned to user.
vertices
Calculate the keys of the HOOPS geometric primitives representing the PK_Vertex entities in the given Parasolid entity.
edges
Calculate the keys of the HOOPS geometric primitives representing the PK_Edge entities in the given Parasolid entity.
faces
Calculate the keys of the HOOPS geometric primitives representing the PK_Face entities in the given Parasolid entity.
bodies
Calculate the keys of the HOOPS segments representing the PK_Body entities in the given Parasolid entity.
tagID
PK_ENTITY_t
The Tag ID for the Parasolid entity provided for computation.
list
string
A quoted string or string variable specifying the particular types of Parasolid geometry that should be converted.
count
count
Number of HOOPS keys associated with the given Parasolid entity. Returned to user.
vertices
Calculate the keys of the HOOPS geometric primitives representing the PK_Vertex entities in the given Parasolid entity.
edges
Calculate the number of HOOPS geometric primitives representing the PK_Edge entities in the given Parasolid entity.
faces
Calculate the number of HOOPS geometric primitives representing the PK_Face entities in the given Parasolid entity.
bodies
Calculate the number of HOOPS geometric primitives representing the PK_Body entities in the given Parasolid entity.
key
HC_Key
HOOPS key provided for computing associated Parasolid entity TagID.
paraClass
PK_Class_t
Parasolid Class for desired entity associated with the input HOOPS key.
TagID
PK_ENTITY_t
The requested Parasolid tagID. Returned to user.
If no tagID can be found which corresponds to the given HOOPS key, a negative error token is returned. For an explanation of the possible error tokens, please see HOOPS/Parasolid Error Tokens.
key
HC_Key
HOOPS key that needs to be associated to the Parasolid entity
TagID
PK_ENTITY_t
Parasolid entity that should be associated to the HOOPS key
success
bool
Success of Operation. Returned to user.
These errors are obsolete, as the HOOPS-Parasolid integration no longer renumbers HOOPS keys. You should not see these error codes.
No HOOPS geometry exists for the given key.
The key provided does not map to an existing Parasolid entity. You have probably performed a Parasolid operation that deleted this entity, without first calling HP_Delete_Entity_Geometry.
There is no clear mapping from the given HOOPS key to the requested Parasolid entity class.
For example, if you pass the key to a HOOPS elliptical arc and ask for PK_FACE, you will get this error code returned. It makes more sense to ask for a PK_EDGE when passing a key to a HOOPS elliptical arc.
This error would likely indicate an internal error. Contact technical support.
This error would likely indicate an internal error, or possibly a case where there is no clear mapping from the given HOOPS key to a single entity of the requested class. Contact technical support.
This error would indicate an internal error. Contact technical support.
This error would indicate an internal error. Contact technical support.