Reads and writes a physical file containing a PRC model file; and creates and accesses model file entities. More...
Data Structures | |
struct | A3DAsmModelFileData |
ModelFile structure. More... | |
Functions | |
A3DStatus | A3DAsmModelFileCreate (const A3DAsmModelFileData *pData, A3DAsmModelFile **ppModelFile) |
Creates a new A3DAsmModelFile using the data in the given A3DAsmModelFileData structure. More... | |
A3DStatus | A3DAsmModelFileDelete (A3DAsmModelFile *pModelFile) |
Deletes the entire A3DAsmModelFile entity from memory. More... | |
A3DStatus | A3DAsmModelFileGet (const A3DAsmModelFile *pModelFile, A3DAsmModelFileData *pData) |
Populates the A3DAsmModelFileData structure. More... | |
A3DStatus | A3DAsmModelFileGetUnit (const A3DAsmModelFile *pModelFile, A3DDouble *pdUnit) |
Gives the unit of the model. More... | |
A3DStatus | A3DAsmModelFileUnloadParts (A3DAsmModelFile *pModelFile, A3DUns32 uiPartsSize, A3DAsmProductOccurrence **ppParts) |
Removes all tessellation and geometry of an A3DAsmProductOccurrence entity This can only be done on parts. More... | |
Detailed Description
Reads and writes a physical file containing a PRC model file; and creates and accesses model file entities.
The A3DAsmModelFile is the root entity of the PRC data. It is the starting point for parsing a PRC file. It is also one of the arguments used to create a 3D annotation within a PDF document.
Entity type is kA3DTypeAsmModelFile.
- See also
- Technical Overview
Enumeration Type Documentation
◆ A3DEModellerType
enum A3DEModellerType |
A3DSDKStructure.
Modeller type
- Version
- 2.1
Function Documentation
◆ A3DAsmModelFileGet()
A3DStatus A3DAsmModelFileGet | ( | const A3DAsmModelFile * | pModelFile, |
A3DAsmModelFileData * | pData | ||
) |
Populates the A3DAsmModelFileData structure.
- Version
- 2.0
- Parameters
-
pModelFile A reference to the model file, which is created by invoking A3DAsmModelFileLoadFromFile pData A reference to the A3DAsmModelFileData structure in which the HOOPS Exchange Library stores the model file data
- Returns
- A3D_INITIALIZE_NOT_CALLED
-
A3D_INVALID_DATA_STRUCT_SIZE
-
A3D_INVALID_DATA_STRUCT_NULL
-
A3D_MODELFILE_INCONSISTENT_EMPTY
-
A3D_INVALID_ENTITY_NULL
-
A3D_INVALID_ENTITY_TYPE
-
A3D_SUCCESS
- Sample code
◆ A3DAsmModelFileCreate()
A3DStatus A3DAsmModelFileCreate | ( | const A3DAsmModelFileData * | pData, |
A3DAsmModelFile ** | ppModelFile | ||
) |
Creates a new A3DAsmModelFile using the data in the given A3DAsmModelFileData structure.
By creating a model file, you are responsible of deleting it later with A3DAsmModelFileDelete.
The new model file must have a root product occurrence. If the input data doesn't contain any, A3DAsmModelFileCreate will implicitly create one. This new product occurrence can be retrieved back on calling A3DAsmModelFileGet with ppModelFile
.
- Parameters
-
in pData The data used to create the model file. out ppModelFile a handle to the newly created model file.
- Version
- 2.0
◆ A3DAsmModelFileDelete()
A3DStatus A3DAsmModelFileDelete | ( | A3DAsmModelFile * | pModelFile | ) |
Deletes the entire A3DAsmModelFile entity from memory.
This operation will recursively delete all entities inside the model file, thus deleting the whole PRC tree. This function is responsible for freeing the all memory allocated for pModelFile
. After this call, access to the model file is no longer possible, and pModelFile
is invalid.
- Remarks
- This function is only applicable to a model file.
- Warning
- This function must not be applied within an HOOPS Visualize Context.
See A3DEntityDelete for a more generic approach.
- See also
- Deleting a PRC tree
- Version
- 2.0
◆ A3DAsmModelFileUnloadParts()
A3DStatus A3DAsmModelFileUnloadParts | ( | A3DAsmModelFile * | pModelFile, |
A3DUns32 | uiPartsSize, | ||
A3DAsmProductOccurrence ** | ppParts | ||
) |
Removes all tessellation and geometry of an A3DAsmProductOccurrence entity This can only be done on parts.
- Version
- 9.1
- Parameters
-
pModelFile The model file uiPartsSize Size of input array. ppParts Array of parts to unload.
◆ A3DAsmModelFileGetUnit()
A3DStatus A3DAsmModelFileGetUnit | ( | const A3DAsmModelFile * | pModelFile, |
A3DDouble * | pdUnit | ||
) |
Gives the unit of the model.
- Version
- 12.0
- Parameters
-
pModelFile A reference to the model file, which is created by invoking A3DAsmModelFileLoadFromFile pdUnit A reference to the unit value