DATAKIT SDK  V2026.2
stepw.hpp
Go to the documentation of this file.
1 #ifndef _STEPW_HEADER_
2 #define _STEPW_HEADER_
3 class stepw_ER;
4 
5 //! \defgroup step_write Step Write Functions
6 //! \brief Exported APIs for STEP Write Library
7 
8 //! \ingroup step_write
9 //! \brief Initializes a file to be written.
10 //! \param[in] inFileName : Step File to write
11 //! \param[in] inOriginatingSystem : optional, designation of Originating system. Will be written in file header
12 //! \param[in] inSchema : specifies a protocol. Supported input : 1 for AP203(E1), 2 for AP214, 3 for AP203E2, 4 for AP242E1, 5 for AP242E4, 0 to adapt to content that will be written.
13 //! \remark AP203 will be used by default. AP214 will be used if colors are written. AP242 will be used if FDT are written.
14 //! \return dtkNoError : the file has been correctly initialized.
15 //! \return dtkErrorAPINotStarted : API was not started.
16 //! \return dtkErrorVersionNotSupported : input schema isn't supported.
17 //! \return dtkErrorLicence : licence checking has failed.
18 DtkErrorStatus stepw_InitFile( const Dtk_string& inFileName, const char* inOriginatingSystem = " user ", const int inSchema = 0 );
19 
20 //! \ingroup step_write
21 //! \brief Sets STEP file header fields value.
22 //! \param[in] inNumItem : 0 description, 1 author, 2 organisation, 3 system, 4 authorization.
23 //! \param[in] inValItem : the value to be set. If empty, switch back to default settings for this field.
24 //! \return dtkNoError : value has been ccorectly set for this header field.
25 //! \return dtkErrorUnspecified : inNumItem is not a supported case.
26 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
27 DtkErrorStatus stepw_SetHeaderData( const int inNumItem, const wchar_t* inValItem );
28 
29 //! \ingroup step_write
30 //! \brief Sets STEP file header fields value.
31 //! \param[in] inNumItem : 0 description, 1 author, 2 organisation, 3 system, 4 authorization.
32 //! \param[in] inValItem : the value to be set. If empty, switch back to default settings for this field.
33 //! \return dtkNoError : value has been ccorectly set for this header field.
34 //! \return dtkErrorUnspecified : inNumItem is not a supported case.
35 DtkErrorStatus stepw_SetHeaderData( const int inNumItem, const Dtk_string& inValItem );
36 
37 //! \ingroup step_write
38 //! \brief Activates/Deactivates writing of FDT.
39 //! \param[in] inMode : FDT representation mode, -1 graphics only, 0 no writing, 1 fully semantic (with graphics).
40 //! \param[in] inPolyline : FDT presentation mode (graphic output), 1 minimal (placeholder), 2 polyline, 3 tessellated.
41 //! \return dtkNoError : the mode has been correctly activated/deactivated.
42 //! \return dtkErrorUnspecified : input mode isn't supported.
43 //! \return dtkErrorLicence : licence checking has failed.
44 DtkErrorStatus stepw_SetModeFdt( const int inMode, const int inPolyline = 2 );
45 
46 //! \ingroup step_write
47 //! \brief Activates/Deactivates writing of properties : User Attributes, Product Data.
48 //! \param[in] inMode : determines what input attributes or properties will be written. 0 no writing, 1 attributes ( stored in Dtk_Info ) and product data, 2 same as 1, with also metadata (Dtk_MetaData::TypeFileProperty and Dtk_MetaData::TypeUnknown are filtered), 3 same as 2, without any Dtk_Metadata filtering
49 //! \return dtkNoError : the mode has been correctly activated/deactivated.
50 //! \return dtkErrorUnspecified : input mode isn't supported.
51 DtkErrorStatus stepw_SetModeProp( const int inMode );
52 
53 //! \ingroup step_write
54 //! \brief Selects a mode for topological 3D items naming policy (shells, faces, edges ).
55 //! \param[in] inMode : 0 no writing (empty name), 1 use name recorded in Dtk_Info, 2 use ID recorded in Dtk_Info (as "no [ID]").
56 //! \return dtkNoError : the mode has been correctly activated/deactivated.
57 //! \return dtkErrorUnspecified : input mode isn't supported.
59 
60 //! \ingroup step_write
61 //! \brief Selects a mode of writing compact or compressed step files.
62 //! \param[in] inMode : 0 normal mode, 1 output a compressed .stp.Z file (ZIP algorithm), 2 output an archive .stpa file.
63 //! \return dtkNoError : the mode has been correctly activated/deactivated.
64 //! \return dtkErrorUnspecified : input mode isn't supported.
66 
67 //! \ingroup step_write
68 //! \brief On a solid or shell, allows the spreading of its first available face graphical attributes to the whole solid/shell.
69 //! \remark If the whole solid/shell has a color defined, this has no effect.
70 //! \param[in] inMode : true to activate, false to deactivate.
71 //! \return dtkNoError : the mode has been correctly activated/deactivated.
72 //! \return dtkErrorUnspecified : input mode isn't supported.
73 DtkErrorStatus stepw_SetModeInfoFirstFace( bool inModeInfoFirstFace );
74 
75 //! \ingroup step_write
76 //! \brief Sets file units in which the geometries, properties are to be written.
77 //! \details To be called before stepw_Init3DPart. It applies on all Parts following its call.
78 //! \param[in] inLength : Length Unit, 0 or 1 MM (default), 2 CM, 3 M, 4 KM, 5 IN(INCH), 6 FT(FOOT).
79 //! \param[in] inAngle : Angle Unit, 0 Radian (default), 1 Degree.
80 //! \warning : all 3D data and values are assumed to be defined in the chosen units.
81 //! \return dtkNoError : the unit has been correctly set.
82 //! \return dtkErrorUnspecified : input value isn't supported.
83 Dtk_ErrorStatus stepw_SetContextUnit( const int inLength, const int inAngle = 0 );
84 
85 
86 //! \ingroup step_write
87 //! \brief Sets file units in which the geometries, properties are to be written, and apply the conversion factor (from MM).
88 //! \details To be called before stepw_Init3DPart. It applies on all Parts following its call.
89 //! \param[in] inLength : Length Unit, 0 or 1 MM (default), 2 CM, 3 M, 4 KM, 5 IN(INCH), 6 FT(FOOT).
90 //! \warning : STEP writer will convert all 3D data and values to the defined length unit.
91 //! \return dtkNoError : the unit has been correctly set.
92 //! \return dtkErrorUnspecified : input value isn't supported.
94 
95 //! \ingroup step_write
96 //! \brief Sets length tolerance for the 3D geometry (uncertainty).
97 //! \details To be called before stepw_Init3DPart, applies on all Parts till new call.
98 //! \param[in] inTol : tolerance value, must be positive.
99 //! \remark Default applied tolerance is 0.005.
100 //! \return dtkNoError : the tolerance was correctly set.
101 //! \return dtkErrorUnspecified : input value is negative.
103 
104 //! \ingroup step_write
105 //! \brief Creates a unique file name for an external reference - applies to the current session (stepw_InitFile to stepw_EndFile).
106 //! \return "inFileName" if the input name wasn't registered as a file name yet.
107 //! \return "inFileName--i" if the input name was already registered as a file name. i is a integer set to make the name unique.
109 
110 //! \ingroup step_write
111 //! \brief Declares a product to be written as an external reference (separated file).
112 //! \param[in] inProductName : name of product to be referenced externally.
113 //! \param[in] inFileName : name of file in which its content will be written.
114 //! \param [out] outID : returned unique identifier for a product. To be used in other calls to identify it.
115 //! \param[in] inInstCompID : optional, defines a user identifier for this product.
116 //! \details If a sequence stepw_InitProduct - stepw_EndProduct is then called with outID identifier, it automatically produces
117 //! another file, with that name, in the same path as the master file.
118 //! \brief An external reference is written in the current file (only one per file) if this product is used in
119 //! an instance or if WriteExternalReference is explicitly called.
120 //! \warning Must be called before first use or first call to InitProduct.. or WriteExternalReference for this product.
121 //! \return dtkNoError if the product was correctly registered as an external reference.
122 //! \return dtkErrorUnspecified if product already written not as external reference.
123 Dtk_ErrorStatus stepw_AddExternalReference( const Dtk_string& inProductName, const Dtk_string& inFileName, int& outID, Dtk_ID inInstCompId = 0 );
124 
125 //! \ingroup step_write
126 //! \brief Writes a product as an external reference. Only one per file for a given product.
127 //! \brief Applies only on a product which has previously been declared as external by AddExternalReference.
128 //! \see stepw_AddExternalReference.
129 //! \param[in] inID : the identifier of the product. Must repeat the ID of the product given by AddExternalReference.
130 //! \details It is not necessary to call it : the first instance that uses this product will call automatically this function.
131 //! \return dtkNoError : the external reference has been correctly written.
132 //! \return dtkOutOfRange : inID does not identify a product.
133 //! \return dtkErrorUserBreak : external reference for this product has alredy already written.
134 //! \return dtkErrorUnspecified : the product was not declared by AddExternalReference.
136 
137 //! \ingroup step_write
138 //! \brief Checks if a product (known by its unique name), is already registered.
139 //! \return -1 : a product with this name isn't registered yet.
140 //! \return positive value : the identifier of the product alredy registered with this name.
141 int stepw_WhichProductID( const Dtk_string& inProductName );
142 
143 //! \ingroup step_write
144 //! \brief Creates a unique product name.
145 //! \remark if inProductName is an empty Dtk_string, it is inteprated as "Product".
146 //! \return "inProductName" if the input name wasn't registered as a product name yet.
147 //! \return "inProductName--i" if the input name was already registered as a product name. i is a integer set to make the name unique.
149 
150 //! \ingroup step_write
151 //! \brief Initializes the definition context of a product.
152 //! \warning assigned name must be unique in the whole step file.
153 //! \see stepw_WhichProductID, stepw_GiveUniqueProductName
154 //! \param[in] inProductName : name to be assigned to the product.
155 //! \param[out] outAssignedID : assigned unique identifier of the product. To be used in other calls to identify it.
156 //! \param[in] inProductUserID : optional, if positive, defines a user identifier for this product.
157 //! \return dtkNoError : product context has been correctly initialized.
158 //! \return dtkErrorUnspecified : error in calling sequence.
159 DtkErrorStatus stepw_InitProduct( const Dtk_string& inProductName, int& outAssignedID, Dtk_ID inProductUserID = 0 );
160 
161 //! \ingroup step_write
162 //! \brief Sets the LayerInfosSet to refer to when writing the current product. It uses its mapping between layer identifier and name.
163 //! \details 3D shapes can be assigned to a layer (through a layer index, in Dtk_Info). The Dtk_LayerInfoSet can further qualify those layers, by assigning them a name.
164 //! \details Setting the LayerInfoSet for the product has to happen after stepw_InitProduct, and before any calls to stepw_Write3DPartBody, to be taken into account.
165 //! \param[in] inLayerInfoSet : Pointer to the LayerInfosSet to refer to, in order to assign names to layers.
166 //! \return dtkNoError : LayerInfosSet has been correctly set for current product context.
167 //! \return dtkErrorUnspecified : error in calling sequence.
168 //! \return dtkErrorNullPointer : inLayerInfoSet is null.
170 
171 //! \ingroup step_write
172 //! \brief Adds an instance of a product ( child ) in an assembly product ( father ).
173 //! \param[in] inFatherProductID : unique identifier of the father product, provided by stepw_InitProduct.
174 //! \param[in] inChildProductID : unique identifier of the child product, provided by stepw_InitProduct.
175 //! \param[in] inPosition : the relative position of the child product instance, in the father product.
176 //! \param[in] inInstanceName : name to be assigned to the instance.
177 //! \return dtkNoError instance has been correctly added.
178 //! \return dtkErrorUnspecified : the child product do not exist yet (so the instance is not registered).
179 DtkErrorStatus stepw_AddInstance( const int inFatherProductID, const int inChildProductID, const Dtk_transfo& inPosition, const Dtk_string& inInstanceName ); // 0 OK, -1 ERROR
180 
181 //! \ingroup step_write
182 //! \brief Adds an instance of a product ( child ) in an assembly product ( father ), with provided attributes.
183 //! \param[in] inFatherProductID : unique identifier of the father product, provided by stepw_InitProduct.
184 //! \param[in] inChildProductID : unique identifier of the child product, provided by stepw_InitProduct.
185 //! \param[in] inPosition : the relative position of the child product instance, in the father product.
186 //! \param[in] inInstanceName : name to be assigned to the instance.
187 //! \param[in] inInstanceInfo : set of information to be attached to the instance, contains attributes (Dtk_Val).
188 //! \return dtkNoError instance has been correctly added.
189 //! \return dtkErrorUnspecified : the child product do not exist yet (so the instance is not registered).
190 DtkErrorStatus stepw_AddInstanceWithInfo( const int inFatherProductID, const int inChildProductID, const Dtk_transfo& inPosition, const Dtk_string& inInstanceName, const Dtk_InfoPtr& inInstanceInfo );
191 
192 //! \ingroup step_write
193 //! \brief Adds an instance of a product ( child ) in an assembly product ( father ), with provided attributes.
194 //! \param[in] inFatherProductID : unique identifier of the father product, provided by stepw_InitProduct.
195 //! \param[in] inChildProductID : unique identifier of the child product, provided by stepw_InitProduct.
196 //! \param[in] inPosition : the relative position of the child product instance, in the father product.
197 //! \param[in] inInstanceName : name to be assigned to the instance.
198 //! \param[in] inInstanceInfo : set of information attached to the instance, contains attributes (Dtk_Val).
199 //! \param[out] outInstanceID : the assigned identifier to the created instance.
200 //! \param[in] inInstanceUserID : optional, the identifier the user wants to provide to the instance, that will be use in addition to the one assigned by this library.
201 //! \param[in] inReferenceDesignator : optional, additional name identification field for the instance.
202 //! \return dtkNoError instance has been correctly added.
203 //! \return dtkErrorUnspecified : the child product do not exist yet (so the instance is not registered).
204 DtkErrorStatus stepw_AddInstanceWithInfo( const int inFatherProductID, const int inChildProductID, const Dtk_transfo& inPosition, const Dtk_string& inInstanceName, const Dtk_InfoPtr& inInstanceInfo,
205 int& outInstanceID, const int inInstanceUserID = 0, const Dtk_string& inReferenceDesignator = "" );
206 
207 
208 //! \deprecated Use stepw_SetInstanceUserID instead.
209 SetAsDeprecated( "2025.4", "Use stepw_SetInstanceUserID instead." )
210 DtkErrorStatus stepw_SetAnchorInstance( const int inInstanceID, const int inInstanceUserID );
211 
212 //! \ingroup step_write
213 //! \brief Sets the designated instance its user-defined identifier.
214 //! \param[in] inInstanceID : the already assigned identifier of the designated instance.
215 //! \param[in] inInstanceUserID :the identifier the user wants to provide to the instance, that will be use in addition to the one assigned by this library.
216 //! \return dtkNoError user-defined identifier has been correctly set.
217 //! \return dtkErrorUnspecified : the provided instance identifier does not identify a registered instance.
218 DtkErrorStatus stepw_SetInstanceUserID( const int inInstanceID, const int inInstanceUserID );
219 
220 //! \deprecated Use stepw_WhichInstanceID instead.
221 SetAsDeprecated( "2025.4", "Use stepw_WhichInstanceID instead." )
222 int stepw_AnchorInstanceID( const int inUserID );
223 
224 //! \ingroup step_write
225 //! \brief Checks if an instance (known by its user-defined identifier), is already registered.
226 //! \return 0 : an instance with this user-defined identifier isn't registered yet.
227 //! \return strictly positive value : the identifier of the instance alredy registered with this user-defined identifier.
228 int stepw_WhichInstanceID( const int inUserID );
229 
230 //! \ingroup step_write
231 //! \brief Defines properties to be attached directly to the product : considers the list of Dtk_Val in the Dtk_Info.
232 //! \param[in] inInfo : the Dtk_Info which brings the Dtk_Val objects to be written as properties.
233 //! \param[in] inItem : 0 dispatched between part (PDS) and product (PD), 1 on part only, 2 on product only.
234 //! \details PDS = PRODUCT_DEFINITION_SHAPE or part, PD = PRODUCT_DEFINITION or product.
235 //! \warning : must be called before stepw_Init3DPart of the product to be populated.
236 //! \details dispatch is done according to CAX-IF recommended practices for Geometric and Assembly Validation Properties.
237 //! \return dtkNoError : properties has been correctly attached.
238 //! \return dtk_ErrorOutOfRange : inItem value is not supported.
239 //! \return dtkErrorUnspecified : error in calling sequence.
241 
242 //! \ingroup step_write
243 //! \brief Sets attachment mode for next property writing : the whole Part, or to the following entity to be written.
244 //! \details Entities eligible for properties as metadata are : Dtk_Body, Dtk_Mesh.
245 //! \details this mode is to be set for each entity, it is reset by stepw_End3DPart and by each writing of an entity with properties.
246 //! \param[in] inMode : 0 attach property to the whole Part (default), 1 attach property to a body or mesh entity to be written.
247 //! \return dtkNoError : the mode has been correctly set.
248 //! \return dtkErrorOutOfRange : input mode isn't supported.
250 
251 //! \ingroup step_write
252 //! \brief Adds a roperty to a part (default), or to an entity, according to InitPropertySet mode.
253 //! \details Properties on the whole part can represent either "Product Data" or a property of any kind.
254 //! \details "Product Data" are predefined properties, their reserved titles are : "Part Number", "Nomenclature", "Description", "Definition", "Revision", "Document" or "Source".
255 //! \details All are optional (when absent, a default value is set), required to be TEXT,
256 //! \details "Source" must take these values : "MADE" or "BOUGHT" otherwise it is ignored.
257 //! \details Entity properties will be attached to the next written entity, so, to be called before writing the entity of attachment.
258 //! \details Entities eligible for properties as metadata are : Dtk_Body, Dtk_Mesh.
259 //! \param[in] inProperty : the MetaData to be written with the 3D Part.
260 //! \return dtkNoError : the property has been correctly added.
261 //! \return dtkErrorNullPointer : inProperty is null.
263 
264 //! \ingroup step_write
265 //! \brief Initializes the writing of a 3D part for the designated product.
266 //! \details Each product must have a 3D part, even empty : started by stepw_Init3DPart, ended by stepw_End3DPart. The 3D part can contain multiple geometries (body, mesh, wireframe).
267 //! \param[in] inProductID : unique identifier of the product, provided by stepw_InitProduct.
268 //! \return dtkNoError if done, dtkErrorOutOfRange if no call to stepw_InitProduct was done previously, or ID wrong
269 DtkErrorStatus stepw_Init3DPart( const int inProductID );
270 
271 //! \ingroup step_write
272 //! \brief Initializes the context to write entities in a node.
273 //! \details Typical entity that needs encapsulation in a node is FDT.
274 //! \param inNodeID : the identifier attached to this node, must be positive and unique in the scope of a product.
275 void stepw_InitNodeContext( const int inNodeID );
276 
277 //! \ingroup step_write
278 //! \brief Initializes the context to write entities in a node.
279 //! \param inNodeInfo : additional information/attributes to qualify the node (color, layer, invisibility).
280 //! \param inNodeID : the identifier attached to this node, must be positive and unique in the scope of a product.
281 void stepw_InitNodeContext( const int inNodeID, const Dtk_InfoPtr& inNodeInfo );
282 
283 //! \ingroup step_write
284 //! \brief Ends current node context.
285 void stepw_EndNodeContext( const int unused = 0 );
286 
288 
289 //! \ingroup step_write
290 //! \brief Writes a body of a 3D part (3D content of a product), of any kind (solid, shell / faces, wireframe / points).
291 //! \param[in] inBody : the body to be written.
292 //! \return dtkNoError : the body has been correctly written.
293 //! \return dtkErrorUnspecified : part context hasn't been initialized.
294 //! \return dtkErrorNullPointer : inBody is null.
296 
297 //! \ingroup step_write
298 //! \brief Writes a body of a 3D part (3D content of a product), associated with a mesh.
299 //! \details The mesh is assumed to be the result of computing tessellation on the body in case of association : its items can be bound with items of the body.
300 //! \warning not recommended for STEP versions before AP242.
301 //! \param[in] inBody : the body to be written.
302 //! \param[in] inMesh : the mesh to be written, ignored if null.
303 //! \param[in] inMode : mode of association, 0 as additional representation (default), 1 as alternate geometry (ignored before AP242).
304 //! \return dtkNoError : the body has been correctly written.
305 //! \return dtkErrorUnspecified : part context hasn't been initialized.
306 //! \return dtkErrorNullPointer : inBody is null.
307 DtkErrorStatus stepw_Write3DPartBodyWithMesh( const Dtk_BodyPtr& inBody, const Dtk_MeshPtr& inMesh, const int inMode = 0 );
308 
309 //! \ingroup step_write
310 //! \brief Writes a body as a construction geometry of a 3D part, of any kind (solid, shell / faces, wireframe / points).
311 //! \details Usually used to complement FDT definition.
312 //! \param[in] inBody : the body to be written.
313 //! \return dtkNoError : the body has been correctly written.
314 //! \return dtkErrorUnspecified : part context hasn't been initialized.
315 //! \return dtkErrorNullPointer : inBody is null.
316 //! \return dtkErrorTypeNotsupported : not supported in AP203 version.
318 
319 //! \ingroup step_write
320 //! \brief Writes an axis system of a 3D part, in STEP, it is a construction geometry based on an axis placement.
321 //! \details Usually used to complement FDT definition.
322 //! \param[in] inAxis : the axis to be written.
323 //! \return dtkNoError : the axis has been correctly written.
324 //! \return dtkErrorUnspecified : part context hasn't been initialized.
325 //! \return dtkErrorNullPointer : inAxis is null.
326 //! \return dtkErrorTypeNotsupported : not supported in AP203 version.
328 
329 //! \ingroup step_write
330 //! \brief Writes a mesh of a 3D part (3D content of a product).
331 //! \details Default is mockup mesh. If no mockup is defined, basic triangles are written instead.
332 //! \warning: correct mapping is with mockup; writing basic triangles of meshes is not efficient.
333 //! \param[in] inMesh : the mesh to be written.
334 //! \return dtkNoError : the mesh has been correctly written.
335 //! \return dtkErrorUnspecified : part context hasn't been initialized.
336 //! \return dtkErrorNullPointer : inMesh is null.
338 
339 //! \ingroup step_write
340 //! \brief Writes a mesh of a 3D part (3D content of a product), coming from a body, without writing the body itself.
341 //! \details The mesh is assumed to be the result of computing tessellation on the body in case of association : its items can be bound with items of the body.
342 //! \see Write3DPartBodyWithMesh : writes both the body and the mesh.
343 //! \param[in] inMesh : the mesh to be written.
344 //! \param[in] inBody : the body it comes from (not written), ignored if null (acts as Write3DPartMesh).
345 //! \return dtkNoError : the mesh has been correctly written.
346 //! \return dtkErrorUnspecified : part context hasn't been initialized.
347 //! \return dtkErrorNullPointer : inMesh is null.
349 
350 //! \ingroup step_write
351 //! \brief Adds a FDT in the current part context.
352 //! \details Can be called at any time between stepw_Init3DPart and stepw_End3DPart, writing takes place after the bodies.
353 //! \param[in] inFDT : the FDT to be written with the 3D part (according to ModeFdt, as semantic and/or graphic).
354 //! \return dtkNoError : the FDT has been correctly added.
355 //! \return dtkErrorNotProcessed : inFDT is null.
356 //! \return dtkErrorLicence : no licence active or stepw_SetModeFdt not called before starting.
358 
359 //! \ingroup step_write
360 //! \brief Adds a FDT in the current part context, with a predefined graphic presentation.
361 //! \details Can be called at any time between stepw_Init3DPart and stepw_End3DPart, writing takes place after the bodies.
362 //! \param[in] inFDT : the FDT to be written as semantic data with the 3D part.
363 //! \param[in] inFDT : the FDT to be used for graphical presentation with the 3D part.
364 //! \return dtkNoError : the FDT has been correctly added.
365 //! \return dtkErrorNotProcessed : inFDT is null.
366 //! \return dtkErrorLicence : no licence active or stepw_SetModeFdt not called before starting.
368 
369 //! \ingroup step_write
370 //! \brief Adds a FDT in the current part context, with an element reference (usually the target geometry).
371 //! \see stepw_CreateReference
372 //! \param[in] inFDT : the FDT to be written with the 3D part (according to ModeFdt, as semantic and/or graphic).
373 //! \param[in] inER : the element reference allowing the FDT to target entities (usually geometries).
374 //! \return dtkNoError : the FDT and its element reference have been correctly added.
375 //! \return dtkErrorNotProcessed : inFDT is null.
376 //! \return dtkErrorLicence : no licence active or stepw_SetModeFdt not called before starting.
378 
379 
380 //! \ingroup step_write
381 //! \brief Adds a view ( Dtk_ModelDisplay ) in the current part context.
382 //! \details Can be called at any time between stepw_Init3DPart and stepw_End3DPar, writing takes place after the bodies.
383 //! \param[in] inModelDisplay : the view to be written with the 3D Part.
384 //! \param[in] inMode : 0 no FDT/Annotation is attached to the view (default), 1 all FDT/Annotations are attached to the view.
385 //! \return dtkNoError : the view has been correctly added.
386 //! \return dtkErrorNullPointer : inModelDisplay is null.
387 //! \return dtkErrorLicence : no licence active or stepw_SetModeFdt not called before starting.
388 Dtk_ErrorStatus stepw_Add3DModelDisplay( const Dtk_ModelDisplayPtr& inModelDisplay, const int inMode );
389 
390 //! \ingroup step_write
391 //! \brief Adds a view ( Dtk_ModelDisplay ) with a link to a FDT, in the current part context.
392 //! \details Can be called at any time between stepw_Init3DPart and stepw_End3DPart - writing takes place after the bodies.
393 //! \details A same FDT can be used in several views.
394 //! \warning stepw_Add3dPartFDT call is required, here only the link with the view/model_display is recorded.
395 //! \remark There is no required order between Add3dPartFDT and Add3dFdtModelDisplay.
396 //! \param[in] inModelDisplay : the view to be written with the 3D Part.
397 //! \param[in] inFDT : the FDT to be linked to the view.
398 //! \return dtkNoError : the view and link have been correctly added.
399 //! \return dtkErrorNullPointer : inModelDisplay or inFDT is null.
400 //! \return dtkErrorLicence : no licence active or stepw_SetModeFdt not called before starting.
401 //! \deprecated Use stepw_Add3DModelDisplay and stepw_AddReference instead.
403 Dtk_ErrorStatus stepw_Add3DFdtModelDisplay( const Dtk_ModelDisplayPtr& inModelDisplay, const Dtk_FdtPtr& inFDT );
404 
405 
407 
408 //! \ingroup step_write
409 //! \brief Ends the writing of a product 3D part.
410 //! \return dtkNoError : context has been correclty closed.
411 //! \return dtkErrorUserBreak : error in calling sequence.
413 
414 //! \ingroup step_write
415 //! \brief Writes instances detained by a product.
416 //! \see stepw_EndProduct.
417 //! \param[in] inID : unique identifier for a product. Must be the same as for stepw_InitProduct.
418 //! \return dtkNoError : instances have been correctly written.
419 //! \return dtkErrorUnspecified : error in calling sequence.
420 DtkErrorStatus stepw_WriteAssemblyInstances( const int inID ); // inID must repeat that of InitProduct.
421 
422 //! \ingroup step_write
423 //! \brief Ends the writing of a product - calls WriteAssemblyInstances if not yet done.
424 //! \param[in] inID : unique identifier for a product. Must be the same as for stepw_InitProduct.
425 //! \return dtkNoError : context has been correclty closed.
426 //! \return dtkErrorUnspecified : error in calling sequence.
427 DtkErrorStatus stepw_EndProduct( const int inProductID );
428 
429 
430 //! \ingroup step_write
431 //! \brief Ends the writing of the current STEP file
432 //! \return dtkNoError : file context has been correctly closed.
434 
435 
436 //Classes to describe element references inside a product or between products.
437 class stepw_ER //Placeholder for element reference
438 {
439 public:
441  void* m_pData;
442 };
443 
444 class stepw_ERP //Placeholder for element reference path
445 {
446 public:
448  void* m_pData;
449 };
450 
451 //! \ingroup step_write
452 //! \brief Creates a reference to an entity located in the designated Product/Part context, or current context if not specified.
453 //! \param[in, out] inOutElementReference : object representing the reference, that will be used internally.
454 //! \param[in] inEntityID : identifier of a Dtk_Entity that will be referenced in current Product/Part.
455 //! \param[in] inProductID : identifier of the Product in which the entity is located. If equals 0, the current Product/Part context is used.
456 //! \param[in] inReferenceKind : Optional, character sequence to specify the reason of the reference. Supported sequences are "fdt", "group", "visible", "hidden".
457 //! "fdt" allows to specify that the target of the reference is a FDT entity (Dtk_Fdt).
458 //! "group" allows to specify that the target of the reference is a feature (interpreted as a group of geometries) (Dtk_Feature).
459 //! "visible" allows to specify that the target should be visible in the designated Product/Part context.
460 //! "hidden" allows to specify that the target should be hidden in the designated Product/Part context.
461 //! \see stepw_CreateReferenceToFdt
462 //! \see stepw_CreateReferenceToGroup
463 //! \return dtkNoError : content of inOutElementReference has been filled.
464 //! \return dtkErrorUnspecified : content of inOutElementReference has not been filled, allocation issue or unrecognized character sequence in case the reference reason has been specified.
465 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
466 DtkErrorStatus stepw_CreateReference( stepw_ER& inOutElementReference, const int inEntityID, const int inProductID = 0, const char* inReferenceKind = "");
467 
468 //! \ingroup step_write
469 //! \brief Creates a reference to a whole node (Dtk_Node), located in the designated Product/Part context.
470 //! \param [in, out] inOutElementReference : object representing the reference, that will be used internally.
471 //! \param[in] inNodeID : identifier of a Dtk_Node that will be referenced in current Product/Part context.
472 //! \param[in] inProductID : identifier of the Product in which the entity is located. If equals 0, the current Product/Part context is used.
473 //! \param[in] inReferenceKind : Optional, character sequence to specify the reason of the reference. Supported sequences are "fdt", "group", "visible", "hidden".
474 //! "fdt" allows to specify that the target of the reference is a node that contains a FDT (Dtk_Node, Dtk_Fdt).
475 //! "group" allows to specify that the target of the reference is a node that contains a feature (interpreted as a group of geometries) (Dtk_Node, Dtk_Feature).
476 //! "visible" allows to specify that the target should be visible in the designated Product/Part context.
477 //! "hidden" allows to specify that the target should be hidden in the designated Product/Part context.
478 //! \return dtkNoError : content of inOutElementReference has been filled.
479 //! \return dtkErrorUnspecified : content of inOutElementReference has not been filled, allocation issue or unrecognized character sequence in case the reference reason has been specified.
480 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
481 DtkErrorStatus stepw_CreateReferenceToNode( stepw_ER& inOutElementReference, const int inNodeID, const int inProductID = 0, const char* inReferenceKind = "");
482 
483 //! \ingroup step_write
484 //! \brief Registers the previously created element reference in the writer.
485 //! \param [in] inElementReference : object representing the reference, that will be used internally.
486 //! \return dtkNoError : content of inElementReference has been filled.
487 //! \return dtkErrorUnspecified : content of inElementReference is empty.
488 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
490 
491 //! \ingroup step_write
492 //! \brief Creates a reference to an entity located in the designated Product/Part context. The reference target is known to be an FDT (Dtk_FDT).
493 //! \param[in, out] inOutElementReference : object representing the reference, that will be used internally.
494 //! \param[in] inEntityID : identifier of a Dtk_Entity that will be referenced in current Product/Part (is an FDT).
495 //! \param[in] inProductID : identifier of the Product in which the entity is located. If equals 0, the current Product/Part context is used.
496 //! \remark Same as stepw_CreateReference( inOutElementReference, inEntityID, inProductID, "fdt" ).
497 //! \return dtkNoError : content of inOutElementReference has been filled.
498 //! \return dtkErrorUnspecified : content of inOutElementReference has not been filled, allocation issue.
499 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
500 DtkErrorStatus stepw_CreateReferenceToFdt( stepw_ER& inOutElementReference, const int inEntityID, const int inProductID );
501 
502 //! \ingroup step_write
503 //! \brief Creates a reference to an entity located in the designated Product/Part context. The reference target is known to be a feature (Dtk_Feature) (interpreted as a group of geometries).
504 //! \param[in, out] inOutElementReference : object representing the reference, that will be used internally.
505 //! \param[in] inEntityID : identifier of a Dtk_Entity that will be referenced in current Product/Part (is a feature).
506 //! \param[in] inProductID : identifier of the Product in which the entity is located. If equals 0, the current Product/Part context is used.
507 //! \remark Same as stepw_CreateReference( inOutElementReference, inEntityID, inProductID, "group" ).
508 //! \return dtkNoError : content of inOutElementReference has been filled.
509 //! \return dtkErrorUnspecified : content of inOutElementReference has not been filled, allocation issue.
510 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
511 DtkErrorStatus stepw_CreateReferenceToGroup( stepw_ER& inOutElementReference, const int inEntityID, const int inProductID );
512 
513 //! \ingroup step_write
514 //! \brief Initializes a path for the element reference, identifying the sequence of instances to pass through.
515 //!\details When in the context of an assembly with more than one depth level, to designates the instance of a part/product located at a deeper level, there is a need to identify all of the part/product instances we pass through.
516 //! \param[in, out] inOutElementReferencePath : object representing the reference path, that will be used internally.
517 //! \see stepw_AddInstanceWithInfo
518 //! \return dtkNoError : inOutElementReferencePath has been initialized.
519 //! \return dtkErrorUnspecified : content of inOutElementReferencePath has not been initialized, allocation issue.
520 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
521 DtkErrorStatus stepw_CreateInstancePath( stepw_ERP& inOutElementReferencePath );
522 
523 //! \ingroup step_write
524 //! \brief Appends an instance identifier to the element reference path. The instance identifier is provided by this library.
525 //!\details When in the context of an assembly with more than one depth level, to designates the instance of a part/product located at a deeper level, there is a need to identify all of the part/product instances we pass through.
526 //! \param[in, out] inOutElementReferencePath : object representing the reference path, that will be used internally.
527 //! \param[in] inInstanceID : identifier of an instance to append to the element reference path.
528 //! \see stepw_AddInstanceWithInfo
529 //! \return dtkNoError : the instance identifier has been appended to the element reference path.
530 //! \return dtkErrorUnspecified : content of inOutElementReferencePath is empty or instance identifier is invalid (does not identify a previously registered instance).
531 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
532 DtkErrorStatus stepw_AddInstanceToPath( stepw_ERP& inOutElementReferencePath, const int inInstanceID );
533 
534 //! \ingroup step_write
535 //! \brief Define the whole instance identifier sequence of the element reference path.
536 //!\details When in the context of an assembly with more than one depth level, to designates the instance of a part/product located at a deeper level, there is a need to identify all of the part/product instances we pass through.
537 //! \param[in, out] inOutElementReferencePath : object representing the reference path, that will be used internally.
538 //! \param[in] inInstancePath : sequence of instance identifiers to define for the element reference path.
539 //! \return dtkNoError : the sequence of instance identifiers has been set for the element reference path.
540 //! \return dtkErrorUnspecified : the sequence of instance identifiers is invalid (does not identify previously registered instances).
541 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
542 Dtk_ErrorStatus stepw_DefineInstancePath( stepw_ERP& inOutElementReferencePath, const Dtk_tab<Dtk_ID>& inInstancePath, const bool unused = false );
543 
544 //! \ingroup step_write
545 //! \brief Assigns the element reference path to the element reference.
546 //! \param[in, out] inOutElementReference : the element reference to which the path will be assigned.
547 //! \param[in] inElementReferencePath : the path to assign to the element reference.
548 //! \return dtkNoError : the path has been assigned.
549 //! \return dtkErrorUnspecified : either inOutElementReference or inElementReferencePath content is empty.
550 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
551 DtkErrorStatus stepw_SetReferencePath( stepw_ER& inOutElementReference, stepw_ERP& inElementReferencePath );
552 
553 //! \ingroup step_write
554 //! \brief Assigns information on an instance in multi-level assembly context.
555 //! \details The first identifier of the route designating the instance allows to deduce in which assembly context the instance will hold the information.
556 //! \details This produces the writing of a CONTEXT_DEPENDENT_OVERRIDING_STYLED_ITEM.
557 //! \param[in] inElementReferencePath : the instance route to designate the instance in the assembly.
558 //! \param[in] inOverrideInfo : the information to apply to this instance. Only color and blanked status are taken into account.
559 //! \see stepw_CreateInstancePath
560 //! \return dtkNoError : the override information has been correctly assigned to the instance.
561 //! \return dtkErrorUnspecified : inOutElementReference content is empty.
562 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
563 Dtk_ErrorStatus stepw_AddOverrideInstanceInfo( stepw_ERP& inElementReferencePath, Dtk_InfoPtr& inOverrideInfo );
564 
565 //! \ingroup step_write
566 //! \brief Declares the product as having an ANCHOR section. If the designated product is already declared as such, sets its user-defined identifier.
567 //! \details Having an ANCHOR section allows the product to declare entities that can be referenced from outside of the product file, in cases where this product is written in a separated file.
568 //! \param[in] inProductID : identifier of the product to declare.
569 //! \param[in] inUserID : identifier the user wants to provide to the product, to be able to retrieve it later.
570 //! \see stepw_AnchorProductID
571 //! \return dtkNoError : the product is declared as having an ANCHOR section.
572 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
573 DtkErrorStatus stepw_SetAnchorProduct( const int inProductID, const int inUserID );
574 
575 //! \ingroup step_write
576 //! \brief Finds the product having an ANCHOR section, by user identifier.
577 //! \param[in] inUserID : identifier the user previously provided to identify the product.
578 //! \see stepw_SetAnchorProduct
579 //! \return 0 : the product hasn't been found.
580 //! \return positive value : the found product corresponding identifier (non-user defined)
581 int stepw_AnchorProductID( const int inUserID );
582 
583 //! \ingroup step_write
584 //! \brief Registers an entity in the ANCHOR section, with an assigned GUID (optional).
585 //! \details Entities declared in the ANCHOR section can be referenced from outside of the product file, in cases where this product is written in a separated file.
586 //! \details If the designated product is not yet declared as having an ANCHOR section, it calls stepw_SetAnchorProduct.
587 //! \see stepw_SetAnchorProduct
588 //! \param[in] inEntityID : identifier of the entity to declare in the ANCHOR section.
589 //! \param[in] inProductID : identifier of the product where to declare entities in the ANCHOR section.
590 //! \param[in] inGUID : the GUID to assign to the entity.
591 //! \return dtkNoError : the entity has been correctly declared in the ANCHOR section.
592 //! \return dtkErrorUnspecified : the product identifier does not identify a product in the current file.
593 //! \return dtkErrorNotProcessed : the entity is already registered with a different GUID.
594 //! \return dtkErrorOpenFiles : STEPWriter is not initialized.
595 Dtk_ErrorStatus stepw_AddAnchorItem( const int inEntityID, const int inProductID, const Dtk_string& inGUID );
596 
597 
598 
599 #endif
stepw_CreateReferenceToGroup
DtkErrorStatus stepw_CreateReferenceToGroup(stepw_ER &inOutElementReference, const int inEntityID, const int inProductID)
Creates a reference to an entity located in the designated Product/Part context. The reference target...
stepw_SetModeInfoFirstFace
DtkErrorStatus stepw_SetModeInfoFirstFace(bool inModeInfoFirstFace)
On a solid or shell, allows the spreading of its first available face graphical attributes to the who...
Dtk_ID
uint32_t Dtk_ID
Definition: define.h:681
Dtk_transfo
This is the Transformation dedicated class.
Definition: dtk_transfo.hpp:19
stepw_ERP::m_pData
void * m_pData
Definition: stepw.hpp:448
stepw_AddOverrideInstanceInfo
Dtk_ErrorStatus stepw_AddOverrideInstanceInfo(stepw_ERP &inElementReferencePath, Dtk_InfoPtr &inOverrideInfo)
Assigns information on an instance in multi-level assembly context.
stepw_InitProduct
DtkErrorStatus stepw_InitProduct(const Dtk_string &inProductName, int &outAssignedID, Dtk_ID inProductUserID=0)
Initializes the definition context of a product.
stepw_ER::m_pData
void * m_pData
Definition: stepw.hpp:441
stepw_AddInstanceToPath
DtkErrorStatus stepw_AddInstanceToPath(stepw_ERP &inOutElementReferencePath, const int inInstanceID)
Appends an instance identifier to the element reference path. The instance identifier is provided by ...
stepw_SetProductLayerInfosSet
DtkErrorStatus stepw_SetProductLayerInfosSet(const Dtk_LayerInfosSetPtr inLayerInfoSet)
Sets the LayerInfosSet to refer to when writing the current product. It uses its mapping between laye...
stepw_Write3DConstructionGeometry
DtkErrorStatus stepw_Write3DConstructionGeometry(const Dtk_BodyPtr &inBody)
Writes a body as a construction geometry of a 3D part, of any kind (solid, shell / faces,...
stepw_ERP
Definition: stepw.hpp:445
stepw_WriteAssemblyInstances
DtkErrorStatus stepw_WriteAssemblyInstances(const int inID)
Writes instances detained by a product.
stepw_Write3DPartMesh
DtkErrorStatus stepw_Write3DPartMesh(const Dtk_MeshPtr &inMesh)
Writes a mesh of a 3D part (3D content of a product).
stepw_SetContextTolerance
Dtk_ErrorStatus stepw_SetContextTolerance(const double inTol)
Sets length tolerance for the 3D geometry (uncertainty).
Dtk_string
This is a high level string class.
Definition: dtk_string.hpp:53
stepw_SetInstanceUserID
DtkErrorStatus stepw_SetInstanceUserID(const int inInstanceID, const int inInstanceUserID)
Sets the designated instance its user-defined identifier.
stepw_DefineInstancePath
Dtk_ErrorStatus stepw_DefineInstancePath(stepw_ERP &inOutElementReferencePath, const Dtk_tab< Dtk_ID > &inInstancePath, const bool unused=false)
Define the whole instance identifier sequence of the element reference path.
stepw_WhichInstanceID
int stepw_WhichInstanceID(const int inUserID)
Checks if an instance (known by its user-defined identifier), is already registered.
stepw_Write3DPartBody
DtkErrorStatus stepw_Write3DPartBody(const Dtk_BodyPtr &inBody)
Writes a body of a 3D part (3D content of a product), of any kind (solid, shell / faces,...
stepw_Write3DPartBodyWithMesh
DtkErrorStatus stepw_Write3DPartBodyWithMesh(const Dtk_BodyPtr &inBody, const Dtk_MeshPtr &inMesh, const int inMode=0)
Writes a body of a 3D part (3D content of a product), associated with a mesh.
stepw_WriteExternalReference
Dtk_ErrorStatus stepw_WriteExternalReference(const int inID)
Writes a product as an external reference. Only one per file for a given product.
stepw_EndProduct
DtkErrorStatus stepw_EndProduct(const int inProductID)
Ends the writing of a product - calls WriteAssemblyInstances if not yet done.
stepw_SetModeProp
DtkErrorStatus stepw_SetModeProp(const int inMode)
Activates/Deactivates writing of properties : User Attributes, Product Data.
SetAsDeprecated
SetAsDeprecated("2025.4", "Use stepw_SetInstanceUserID instead.") DtkErrorStatus stepw_SetAnchorInstance(const int inInstanceID
stepw_Write3DPartMeshFromBody
DtkErrorStatus stepw_Write3DPartMeshFromBody(const Dtk_MeshPtr &inMesh, const Dtk_BodyPtr &inBody)
Writes a mesh of a 3D part (3D content of a product), coming from a body, without writing the body it...
stepw_GiveUniqueFileName
Dtk_string stepw_GiveUniqueFileName(const Dtk_string &inFileName)
Creates a unique file name for an external reference - applies to the current session (stepw_InitFile...
stepw_Add3DPartProperty
Dtk_ErrorStatus stepw_Add3DPartProperty(const Dtk_MetaDataPtr &inProperty)
Adds a roperty to a part (default), or to an entity, according to InitPropertySet mode.
stepw_SetReferencePath
DtkErrorStatus stepw_SetReferencePath(stepw_ER &inOutElementReference, stepw_ERP &inElementReferencePath)
Assigns the element reference path to the element reference.
stepw_InitFile
DtkErrorStatus stepw_InitFile(const Dtk_string &inFileName, const char *inOriginatingSystem=" user ", const int inSchema=0)
Initializes a file to be written.
stepw_CreateReference
DtkErrorStatus stepw_CreateReference(stepw_ER &inOutElementReference, const int inEntityID, const int inProductID=0, const char *inReferenceKind="")
Creates a reference to an entity located in the designated Product/Part context, or current context i...
inFDT
const Dtk_FdtPtr & inFDT
Definition: stepw.hpp:403
stepw_AnchorProductID
int stepw_AnchorProductID(const int inUserID)
Finds the product having an ANCHOR section, by user identifier.
stepw_AddExternalReference
Dtk_ErrorStatus stepw_AddExternalReference(const Dtk_string &inProductName, const Dtk_string &inFileName, int &outID, Dtk_ID inInstCompId=0)
Declares a product to be written as an external reference (separated file).
stepw_SetModeFdt
DtkErrorStatus stepw_SetModeFdt(const int inMode, const int inPolyline=2)
Activates/Deactivates writing of FDT.
stepw_Init3DPart
DtkErrorStatus stepw_Init3DPart(const int inProductID)
Initializes the writing of a 3D part for the designated product.
stepw_AddInstanceWithInfo
DtkErrorStatus stepw_AddInstanceWithInfo(const int inFatherProductID, const int inChildProductID, const Dtk_transfo &inPosition, const Dtk_string &inInstanceName, const Dtk_InfoPtr &inInstanceInfo)
Adds an instance of a product ( child ) in an assembly product ( father ), with provided attributes.
stepw_AddInstance
DtkErrorStatus stepw_AddInstance(const int inFatherProductID, const int inChildProductID, const Dtk_transfo &inPosition, const Dtk_string &inInstanceName)
Adds an instance of a product ( child ) in an assembly product ( father ).
stepw_Add3DPartFDT
DtkErrorStatus stepw_Add3DPartFDT(const Dtk_FdtPtr &inFDT)
Adds a FDT in the current part context.
Dtk_ErrorStatus
Dtk_ErrorStatus
Definition: error_dtk.hpp:6
stepw_SetPartProperties
DtkErrorStatus stepw_SetPartProperties(const Dtk_InfoPtr &inInfo, const int inItem)
Defines properties to be attached directly to the product : considers the list of Dtk_Val in the Dtk_...
stepw_SetModeItemName
DtkErrorStatus stepw_SetModeItemName(const int inMode)
Selects a mode for topological 3D items naming policy (shells, faces, edges ).
stepw_SetAnchorProduct
DtkErrorStatus stepw_SetAnchorProduct(const int inProductID, const int inUserID)
Declares the product as having an ANCHOR section. If the designated product is already declared as su...
Dtk_SmartPtr
Definition: util_ptr_dtk.hpp:37
stepw_EndFile
DtkErrorStatus stepw_EndFile()
Ends the writing of the current STEP file.
stepw_End3DPart
DtkErrorStatus stepw_End3DPart()
Ends the writing of a product 3D part.
stepw_Write3DAxisSystem
DtkErrorStatus stepw_Write3DAxisSystem(const Dtk_AxisSystemPtr &inAxis)
Writes an axis system of a 3D part, in STEP, it is a construction geometry based on an axis placement...
stepw_ERP::stepw_ERP
stepw_ERP()
stepw_AddReference
DtkErrorStatus stepw_AddReference(stepw_ER &inElementReference)
Registers the previously created element reference in the writer.
stepw_Add3DModelDisplay
Dtk_ErrorStatus stepw_Add3DModelDisplay(const Dtk_ModelDisplayPtr &inModelDisplay, const int inMode)
Adds a view ( Dtk_ModelDisplay ) in the current part context.
stepw_Write3DPartRoot
DtkErrorStatus stepw_Write3DPartRoot()
stepw_CreateReferenceToFdt
DtkErrorStatus stepw_CreateReferenceToFdt(stepw_ER &inOutElementReference, const int inEntityID, const int inProductID)
Creates a reference to an entity located in the designated Product/Part context. The reference target...
stepw_SetContextUnit
Dtk_ErrorStatus stepw_SetContextUnit(const int inLength, const int inAngle=0)
Sets file units in which the geometries, properties are to be written.
Dtk_tab
This is a high level array class.
Definition: util_stl_dtk.hpp:84
stepw_ER
Definition: stepw.hpp:438
stepw_CreateInstancePath
DtkErrorStatus stepw_CreateInstancePath(stepw_ERP &inOutElementReferencePath)
Initializes a path for the element reference, identifying the sequence of instances to pass through.
stepw_SetHeaderData
DtkErrorStatus stepw_SetHeaderData(const int inNumItem, const wchar_t *inValItem)
Sets STEP file header fields value.
stepw_CreateReferenceToNode
DtkErrorStatus stepw_CreateReferenceToNode(stepw_ER &inOutElementReference, const int inNodeID, const int inProductID=0, const char *inReferenceKind="")
Creates a reference to a whole node (Dtk_Node), located in the designated Product/Part context.
Pdfw::inInfo
Dtk_tab< Dtk_dir > Dtk_ID Dtk_InfoPtr inInfo
Definition: pdfw.hpp:677
stepw_SetModeCompress
DtkErrorStatus stepw_SetModeCompress(const int inMode)
Selects a mode of writing compact or compressed step files.
inInstanceUserID
const int inInstanceUserID
Definition: stepw.hpp:210
stepw_EndNodeContext
void stepw_EndNodeContext(const int unused=0)
Ends current node context.
Pdfw::outID
Dtk_tab< Dtk_dir > Dtk_ID & outID
Definition: pdfw.hpp:676
stepw_GiveUniqueProductName
Dtk_string stepw_GiveUniqueProductName(const Dtk_string &inProductName)
Creates a unique product name.
catiav5w::inInstanceName
const Dtk_string & inInstanceName
Definition: catiav5w.hpp:621
stepw_ER::stepw_ER
stepw_ER()
stepw_SetConversionLengthUnit
Dtk_ErrorStatus stepw_SetConversionLengthUnit(const int inLength)
Sets file units in which the geometries, properties are to be written, and apply the conversion facto...
stepw_InitPropertySet
Dtk_ErrorStatus stepw_InitPropertySet(const int inMode)
Sets attachment mode for next property writing : the whole Part, or to the following entity to be wri...
stepw_InitNodeContext
void stepw_InitNodeContext(const int inNodeID)
Initializes the context to write entities in a node.
stepw_AddAnchorItem
Dtk_ErrorStatus stepw_AddAnchorItem(const int inEntityID, const int inProductID, const Dtk_string &inGUID)
Registers an entity in the ANCHOR section, with an assigned GUID (optional).
stepw_SetNextSubBody
Dtk_ErrorStatus stepw_SetNextSubBody(const int mode)
stepw_WhichProductID
int stepw_WhichProductID(const Dtk_string &inProductName)
Checks if a product (known by its unique name), is already registered.