DATAKIT SDK  V2026.1
testwriters.h File Reference

Go to the source code of this file.

Macros

#define CHECK_OK(X)   {Dtk_ErrorStatus res;if ((res=X)!=dtkNoError) {printf("error : %s\n", dtkTypeError(res).c_str());return res;}}
 
#define PRINT_ERROR(inStatus)
 

Functions

int _3dxmlWriteSample (const Dtk_string &inResultDirectory)
 
int _3mfWriteSample (const Dtk_string &inResultDirectory)
 
int CatiaV5WriteSample (const Dtk_string &inResultDirectory)
 
int CgrWriteSample (const Dtk_string &inResultDirectory)
 
int ColladaWriteSample (const Dtk_string &inResultDirectory)
 
int FbxWriteSample (const Dtk_string &inResultDirectory)
 
int GltfWriteSample (const Dtk_string &inResultDirectory)
 
int IfcWriteSample (const Dtk_string &inResultDirectory)
 
int IgesWriteSample (const Dtk_string &inResultDirectory)
 
int JtWriteSample (const Dtk_string &inResultDirectory)
 
int ObjWriteSample (const Dtk_string &inResultDirectory)
 
int ParasolidWriteSample (const Dtk_string &inResultDirectory)
 
int PdfWriteSample (const Dtk_string &inResultDirectory)
 
int PlmxmlWriteSample (const Dtk_string &inResultDirectory)
 
int SatWriteSample (const Dtk_string &inResultDirectory)
 
int StepWriteSample (const Dtk_string &inResultDirectory)
 
int SwWriteSample (Dtk_API *inDtkAPI, const Dtk_string &inResultDirectory)
 
int UgWriteSample (const Dtk_string &inResultDirectory)
 

Macro Definition Documentation

◆ CHECK_OK

#define CHECK_OK (   X)    {Dtk_ErrorStatus res;if ((res=X)!=dtkNoError) {printf("error : %s\n", dtkTypeError(res).c_str());return res;}}

◆ PRINT_ERROR

#define PRINT_ERROR (   inStatus)
Value:
{ \
if ( ( inStatus ) != dtkNoError) \
std::cout << __FUNCTION__ << " encountered an error at line " << __LINE__ << " : " << dtkTypeError(inStatus).c_str() << std::endl; \
}

Function Documentation

◆ _3dxmlWriteSample()

int _3dxmlWriteSample ( const Dtk_string inResultDirectory)
225 {
226  Dtk_MeshPtr CubeMesh;
227  Dtk_MeshPtr CylinderMesh;
228  Dtk_string outputFileName, outputDirectory;
229 
230  cout << endl << "----------------------------------------------" << endl;
231  cout << "3dxml Write start" << endl;
232 
233  // Choosing output directory and file name
234  outputDirectory = inResultDirectory + L"CatiaV6/";
235  outputDirectory.FixPathSeparator();
236  outputDirectory.mkdir();
237  outputFileName = outputDirectory + L"sample.3dxml";
238 
239  // Cube Sample
240  CubeMesh = sampleWriter::CreateMeshCube();
241 
242  // Cylinder Sample
243  CylinderMesh = sampleWriter::CreateMeshCylinder( 30 );
244 
245  // CREATING HIERARCHY
246 
247  // Root
248  // |
249  // | __Node(Node_1)
250  // | |
251  // | |
252  // | CylinderMesh(Node_2)
253  // |
254  // | __CubeWireMesh(Node_3)
255  // |
256  // |
257  // | __CylinderMesh(Node_4)
258 
259  _3dxmlw::WriteOptions Options;//no option for the moment
260  Dtk_string inLogFile;//no config for the moment
261  DtkErrorStatus errorSt = _3dxmlw::InitWrite( outputFileName, inLogFile, Options );
262 
263  if( errorSt == dtkNoError )
264  {
265  WriteEntity( CubeMesh, CylinderMesh );
266  }
267  else
268  cout << "error : " << dtkTypeError( errorSt ).c_str() << endl;
269 
271 
272  if( errorSt == dtkNoError )
273  cout << "=> " << outputFileName.c_str() << endl << "3dxml Write end" << endl;
274 
275  return errorSt;
276 }

◆ _3mfWriteSample()

int _3mfWriteSample ( const Dtk_string inResultDirectory)
12 {
14  Dtk_MeshPtr cubeMesh = NULL;
15  Dtk_MeshPtr cylinderMesh = NULL;
16  Dtk_string outputFileName, outputDirectory;
17 
18  cout << endl << "----------------------------------------------" << endl;
19  cout << "3mf Write start" << endl;
20 
21  // Choosing output directory and file name
22  outputDirectory = inResultDirectory + L"3mf/";
23  outputDirectory.FixPathSeparator();
24  outputDirectory.mkdir();
25  outputFileName = outputDirectory + L"sample.3mf";
26 
27  // Cube Sample
28  cubeMesh = sampleWriter::CreateMeshCube();
30 
31  // Cylinder Sample
32  cylinderMesh = sampleWriter::CreateMeshCylinder( 30 );
33 
34  // First we initialize writing
36  Dtk_3MFWriter *_3mfw = new Dtk_3MFWriter();
37  err = _3mfw->InitWrite( outputFileName, Dtk_string( "test3mfw.log" ), options );
38 
39  if( err != dtkNoError )
40  cout << "error : " << dtkTypeError( err ).c_str() << endl;
41 
42 
43  // Lets write a small part composed by one cube and one cylinder
44 
45  // Let write the cube
46  cubeMesh->info() = Dtk_Info::create();
47  cubeMesh->info()->SetName( "Cube" );
48 
49  if( err == dtkNoError )
50  err = _3mfw->WriteEntity( Dtk_EntityPtr::DtkDynamicCast( cubeMesh ) );
51 
52  // Let write the cylinder
53  cylinderMesh->info() = Dtk_Info::create();
54  cylinderMesh->info()->SetName( "Cylinder" );
55 
56  if( err == dtkNoError )
57  err = _3mfw->WriteEntity( Dtk_EntityPtr::DtkDynamicCast( cylinderMesh ) );
58 
59  // We finish process and free memory allocated for writing
60  _3mfw->EndWrite();
61  if( err == dtkNoError )
62  cout << "=> " << outputFileName.c_str() << endl << "3mf Write end" << endl;
63  delete _3mfw;
64  return err;
65 }

◆ CatiaV5WriteSample()

int CatiaV5WriteSample ( const Dtk_string inResultDirectory)
482 {
483  // First we initialize writing with name of files and protection fonction
484  //First you have to initialize the CATIA V5 writer
485  Dtk_string outputDirectory;
486 
487  cout << endl << "----------------------------------------------" << endl;
488  cout << "CatiaV5 Write start" << endl;
489 
490  // Choosing output directory and file name
491  outputDirectory = inResultDirectory + L"CatiaV5/";
492  outputDirectory.FixPathSeparator();
493  outputDirectory.mkdir();
494 
495  catiav5w::WriteOptions options;
496  Dtk_ErrorStatus st = options.SetFileRelease( 19 );
497  if( st != dtkNoError )
498  {
499  cout << "error : " << dtkTypeError( st ).c_str() << endl;
500  return st;
501  }
502 
503  st = catiav5w::InitWrite( outputDirectory + L"V5W_LogFile.log", NULL, options );
504  if( st != dtkNoError )
505  {
506  cout << "error : " << dtkTypeError( st ).c_str() << endl;
507  return st;
508  }
509 
510  ProcessAsm( inResultDirectory );
511 
512  //...and the Main writter
514 
515  return dtkNoError;
516 }

◆ CgrWriteSample()

int CgrWriteSample ( const Dtk_string inResultDirectory)
13 {
14  int status;
15  Dtk_MeshPtr CubeMesh;
16  Dtk_MeshPtr CylinderMesh;
17  Dtk_MeshPtr WireMesh;
18  Dtk_AxisSystemPtr TmpAxis;
19  Dtk_mesh_asm_node * mesh_asm = NULL;
20  Dtk_mesh_asm_node * mesh_asm_1 = NULL;
21  Dtk_mesh_asm_node * mesh_asm_2 = NULL;
22  Dtk_mesh_asm_node * mesh_asm_3 = NULL;
23  Dtk_mesh_asm_node * mesh_asm_4 = NULL;
24  Dtk_string outputFileName, outputDirectory;
25 
26  cout << endl << "----------------------------------------------" << endl;
27  cout << "Cgr Write start" << endl;
28 
29  // Choosing output directory and file name
30  outputDirectory = inResultDirectory + L"Cgr/";
31  outputDirectory.FixPathSeparator();
32  outputDirectory.mkdir();
33  outputFileName = outputDirectory + L"sample.cgr";
34 
35  // Axis System
37 
38  // Cube Sample
39  CubeMesh = sampleWriter::CreateMeshCube();
40 
41  // Cylinder Sample
42  CylinderMesh = sampleWriter::CreateMeshCylinder( 30 );
43 
44  // Wire Sample
45  WireMesh = sampleWriter::CreateMeshWire();
46 
47  // PART5 : CREATING HIERARCHY
48 
49  // CREATE ROOT ASM NODE
50  mesh_asm = new Dtk_mesh_asm_node();
51 
52  mesh_asm->set_id( 0 ); // id of node
53  Dtk_transfo * transfo1 = new Dtk_transfo(); // transformation matrix
54  //apply scale
55  transfo1->setXdir( Dtk_dir( 0.8, 0.0, 0.0 ) );
56  transfo1->setYdir( Dtk_dir( 0.0, 0.8, 0.0 ) );
57  transfo1->setZdir( Dtk_dir( 0.0, 0.0, 0.8 ) );
58  transfo1->setOrigin( Dtk_pnt( 0.0, 0.0, 0.8 ) );
59  transfo1->setScale( 1.0 );
60 
61  // CREATE ASM 1
62  mesh_asm_1 = new Dtk_mesh_asm_node(); //create new node
63  mesh_asm_1->set_id( 1 ); // id of node
64  mesh_asm->add_asm_instance( mesh_asm_1, transfo1 ); // add mesh_asm_1 node in mesh_asm
65 
66  //WRITE AXIS SYSTEM
67  mesh_asm->add_axis_system(TmpAxis); // add axis system in mesh_asm
68 
69  //WRITE CUBE MESH
70  mesh_asm->add_mesh( CubeMesh );
71 
72  //WRITE CUBE MESH
73  mesh_asm_2 = new Dtk_mesh_asm_node(); //create new node
74  mesh_asm_2->set_id( 2 ); // id of node
75  Dtk_transfo * transfo2 = new Dtk_transfo();
76  transfo2->setOrigin( Dtk_pnt( -4, -4, -4 ) );
77  mesh_asm->add_asm_instance( mesh_asm_2, transfo2 ); // add mesh_asm_2 node in mesh_asm
78  mesh_asm_2->add_mesh( CubeMesh ); // add mesh in instance mesh_asm_2
79 
80  //WRITE WIRE MESH
81  mesh_asm_3 = new Dtk_mesh_asm_node(); //create new node
82  mesh_asm_3->set_id( 3 ); // id of node
83  mesh_asm_2->add_asm_instance( mesh_asm_3, transfo2 ); // add mesh_asm_3 node in mesh_asm_2
84  mesh_asm_3->add_mesh( WireMesh ); // add wireframe in instance mesh_asm_3
85 
86  //WRITE CYLINDER MESH
87  mesh_asm_4 = new Dtk_mesh_asm_node(); //create new node
88  mesh_asm_4->set_id( 4 ); // id of node
89  Dtk_transfo * transfo3 = new Dtk_transfo();
90  transfo3->setOrigin( Dtk_pnt( -6., -7., -6. ) );
91  mesh_asm_1->add_asm_instance( mesh_asm_4, transfo3 ); // add mesh_asm_4 node in mesh_asm_1
92  Dtk_RGB rgb = Dtk_RGB( 0, 0, 255 );
93  mesh_asm_4->set_color( rgb ); // set color in instance mesh_asm_2
94  mesh_asm_4->add_mesh( CylinderMesh ); // add mesh in instance mesh_asm_4
95 
96 
97  WriteOptions options;
98 
99  //initialize writing
100  options.SetFileRelease( 14 );
101 
102  //CGR write start here
103  // First we initialize writing with name of files and protection fonction if needed (3rd parameter)
104  status = cgrw_InitWrite( outputFileName, outputDirectory + L"testcgrw.log", NULL, L"", options );
105  if( status != 0 )
106  {
107  cgrw_EndWrite();
108  delete mesh_asm;
109  cout << "error : " << dtkTypeError( status ).c_str() << endl;
110  return status;
111  }
112  // Then we write for the mesh assembly constructed
113  cgrw_WriteMeshAsm( mesh_asm );
114 
115  // And free memory allocated for writing
116  cgrw_EndWrite();
117 
118  cout << "=> " << outputFileName.c_str() << endl << "Cgr Write end" << endl;
119 
120  delete mesh_asm;
121 
122  return 0;
123 }

◆ ColladaWriteSample()

int ColladaWriteSample ( const Dtk_string inResultDirectory)
12 {
14  int status;
15  Dtk_MeshPtr cubeMesh = NULL;
16  Dtk_MeshPtr cubeMeshVC = NULL;
17  Dtk_MeshPtr cylinderMesh = NULL;
18  Dtk_MeshPtr wireMesh = NULL;
19  Dtk_ModelDisplayPtr modelDisplay = NULL;
20  Dtk_RenderInfosPtr renderInfos = NULL;
21  Dtk_string outputFileName, outputDirectory;
22  Dtk_string nodeName;
23  Dtk_tab<Dtk_MetaDataPtr> tabMetadata;
24  Dtk_tab<Dtk_ID> tabNodesView1;
25  Dtk_tab<Dtk_ID> tabNodesView2;
26  Dtk_tab<Dtk_ID> tabNodesView3;
27  Dtk_tab< Dtk_tab <Dtk_ID> > tabNodesViews;
28  Dtk_ID nodeID = 0;
29  Dtk_bool reinstanciate = DTK_TRUE;
30  Dtk_InfoPtr info;
31 
32  cout << endl << "----------------------------------------------" << endl;
33  cout << "Collada Write start" << endl;
34 
35  // Choosing output directory and file name
36  outputDirectory = inResultDirectory + L"Collada/";
37  outputDirectory.FixPathSeparator();
38  outputDirectory.mkdir();
39  outputFileName = outputDirectory + L"sample.dae";
40 
41  // Cube Sample
42  cubeMesh = sampleWriter::CreateMeshCube();
44 
45  // Cylinder Sample
46  cylinderMesh = sampleWriter::CreateMeshCylinder( 30 );
47 
48  //RenderInfos Sample
50 
51  // First we initialize writing
52  Colladaw::WriteOptions options;
53  options.ConvertRenderInfos = 1;
54 
55  status = Colladaw::InitWrite( outputFileName, Dtk_string( "testcolladaw.log" ), options );
56 
57  if( status != 0 )
58  {
59  err = Colladaw::EndWrite();
60  cout << "error : " << dtkTypeError( status ).c_str() << endl;
61  return status;
62  }
63 
64  // Lets write a small assembly composed by one cube and one cylinder
65 
66  // let a matrix moving the cube on the left
67  Dtk_transfo cubetransfo;
68  cubetransfo.addTranslate( Dtk_dir( -10, 0, 0 ) );
69 
70  // let a matrix moving the cylinder
71  Dtk_transfo cyltransfo;
72  cyltransfo.addTranslate( Dtk_dir( 10, 0, 0 ) );
73 
74  // let a matrix moving the first instance
75  Dtk_transfo transfo;
76  transfo.addTranslate( Dtk_dir( 100, 100, 100 ) );
77  transfo.setXdir( 0.0, 1.0, 0.0 );
78  transfo.setYdir( 0.0, 0.0, 1.0 );
79  transfo.setZdir( 1.0, 0.0, 0.0 );
80 
81  // Rootnode creation
82  if( err == dtkNoError )
83  {
84  nodeName = "RootNode";
85  err = Colladaw::InitNode( nodeName );
86  }
87  // Facetted data node creation
88  if( err == dtkNoError )
89  {
90  nodeName = "Facetted data";
91  info = Dtk_Info::create();
92  err = Colladaw::InitNode( nodeName, Dtk_transfo(), info, nodeID );
93  }
94 
95  // from this node, create a Child for the cube, giving its matrix, and naming it "Cube"
96  if( err == dtkNoError )
97  {
98  nodeName = "Cube";
99  err = Colladaw::InitNode( nodeName, cubetransfo );
100  }
101  cubeMesh->info() = Dtk_Info::create();
102  cubeMesh->info()->AddRenderInfos( renderInfos );
103  // Write the mesh cube
104  if( err == dtkNoError )
106  // Close the mesh cube node
107  if( err == dtkNoError )
108  err = Colladaw::EndNode();
109 
110  // From root node again, create a Child for the cylinder, giving its matrix, and naming it "Cylinder"
111  if( err == dtkNoError )
112  {
113  nodeName = "Cylinder";
114  err = Colladaw::InitNode( nodeName, cyltransfo );
115  }
116  // Write the mesh cylinder
117  if( err == dtkNoError )
118  err = Colladaw::WriteEntity( Dtk_EntityPtr::DtkDynamicCast( cylinderMesh ) );
119  // Close the mesh cylinder
120  if( err == dtkNoError )
121  err = Colladaw::EndNode();
122  // Close the facetted data node
123  if( err == dtkNoError )
124  err = Colladaw::EndNode();
125 
126  if( reinstanciate )
127  {
128  // "Facetted data (Reinstanciated)" creation
129  if( err == dtkNoError )
130  {
131  nodeName = "Facetted data (Reinstanciated)";
132  err = Colladaw::InitNode( nodeName, transfo );
133  }
134  // Reinstanciating prototype nodeID
135  if( err == dtkNoError )
136  err = Colladaw::ReinstanciatePrototype( nodeID );
137  // Closing node
138  if( err == dtkNoError )
139  err = Colladaw::EndNode();
140  }
141  // Rootnode closing : VERY IMPORTANT, you must close all nodes that were opened.
142  if( err == dtkNoError )
143  err = Colladaw::EndNode();
144  // And free memory allocated for writing
145  if( err == dtkNoError )
146  err = Colladaw::EndWrite();
147 
148  cout << "=> " << outputFileName.c_str() << endl << "Collada Write end" << endl;
149 
150  return err;
151 }

◆ FbxWriteSample()

int FbxWriteSample ( const Dtk_string inResultDirectory)
88 {
89  Dtk_string outputDirectory, fileName;
90  cout << endl << "----------------------------------------------" << endl;
91 
92  // Choosing output directory and file name
93  outputDirectory = inResultDirectory + L"Fbx/";
94  outputDirectory.FixPathSeparator();
95  outputDirectory.mkdir();
96 
97  cout << "Fbx Write start" << endl;
98  // sample 1 : just wirte 2 meshes
99  fileName = outputDirectory + L"twomeshes.fbx";
100  Dtk_ErrorStatus err = FbxwTwoMeshes( fileName );
101  if( err == dtkNoError )
102  cout << "=> " << fileName.c_str() << endl;
103  else
104  cout << "error : " << dtkTypeError( err ).c_str() << endl;
105 
106  // sample 2 : write instances
107  fileName = outputDirectory + L"twomeshes.fbx";
108  err = FbxwInstances( fileName );
109  if( err == dtkNoError )
110  cout << "=> " << fileName.c_str() << endl;
111  else
112  cout << "error : " << dtkTypeError( err ).c_str() << endl;
113 
114  cout << "Fbx Write end" << endl;
115 
116  return err;
117 }

◆ GltfWriteSample()

int GltfWriteSample ( const Dtk_string inResultDirectory)
97 {
98  Dtk_string outputDirectory, fileName;
99  cout << endl << "----------------------------------------------" << endl;
100 
101  // Choosing output directory and file name
102  outputDirectory = inResultDirectory + L"Gltf/";
103  outputDirectory.FixPathSeparator();
104  outputDirectory.mkdir();
105 
106  cout << "Gltf Write start" << endl;
107  cout << "sample 1" << endl;
108  // sample 1 : just write 2 meshes
109  fileName = outputDirectory + L"twomeshes.gltf";
110  Dtk_ErrorStatus errorStatus = GltfwTwoMeshes( fileName );
111  if( errorStatus == dtkNoError )
112  cout << "=> " << fileName.c_str() << endl;
113  else
114  cout << "error : " << dtkTypeError( errorStatus ).c_str() << endl;
115 
116  cout << "sample 2" << endl;
117  // sample 2 : write instances
118  fileName = outputDirectory + L"instances.gltf";
119  errorStatus = GltfwInstances( fileName );
120  if( errorStatus == dtkNoError )
121  cout << "=> " << fileName.c_str() << endl;
122  else
123  cout << "error : " << dtkTypeError( errorStatus ).c_str() << endl;
124 
125  cout << "Gltf Write end" << endl;
126 
127  return errorStatus;
128 }

◆ IfcWriteSample()

int IfcWriteSample ( const Dtk_string inResultDirectory)
193 {
194  Dtk_string outputDirectory, outputFileName;
195  cout << endl << "----------------------------------------------" << endl;
196  cout << "Ifc Write start" << endl;
197 
198  // Choosing output directory and file name
199  outputDirectory = inResultDirectory + L"Ifc/";
200  outputDirectory.FixPathSeparator();
201  outputDirectory.mkdir();
202 
203  //The ProjectInformation class enables you to set global information while initializing the writer module
204  //This information is optionnali
206  myInfo.projectAuthor = L"my name";
207  myInfo.buildingName = L"sample building";
208  myInfo.siteLatitude = 45.7;
209  myInfo.siteLongitude = 4.8;
210  myInfo.siteElevation = 173000;
211 
212  // First we initialize writing with name of files, log file and the configuration we want to use
213  Ifcw::WriteOptions myOptions;
214  myOptions.versionIndicator = 0; //IFC4
215  myOptions.buildingTypeRecognition = 0; //Forces building type recognition. If set to true, all IfcElement without a building element type set will be analyzed (looking through their metadata etc.. to see if we can deduce their building type
216  outputFileName = outputDirectory + L"sample.ifc";
217  Dtk_ErrorStatus st = Ifcw::InitWrite( outputFileName, Dtk_string( outputDirectory + L"testifcw.log" ), myOptions, &myInfo );
218 
219  if( st != dtkNoError )
220  {
221  cout << "error : " << dtkTypeError( st ).c_str() << endl;
222  return st;
223  }
224 
225  //Write an ifc object/entity
226  ProcessBasicWall( myOptions.versionIndicator != 1 );
230 
231  Ifcw::EndWrite();
232 
233  cout << "=> " << outputFileName.c_str() << endl << "Ifc Write end" << endl;
234 
235  return 0;
236 }

◆ IgesWriteSample()

int IgesWriteSample ( const Dtk_string inResultDirectory)
143 {
144  cout << endl << "----------------------------------------------" << endl;
145  cout << "Iges Write start" << endl;
146  //Standard Iges Sample File Processing
147  int err = IgesAssemblySample( inResultDirectory );
148  cout << "Iges Write end" << endl;
149 
150  return err;
151 }

◆ JtWriteSample()

int JtWriteSample ( const Dtk_string inResultDirectory)
1330 {
1331  cout << endl << "----------------------------------------------" << endl;
1332  cout <<"Jt Write start" << endl;
1333 
1334  tess_InitTesselation("./", 0.005); // Init Tessellation : working directory and default tolerance (needed for writing bodies)
1335  tess_ComputeBoundariesFromMesh(0); // Disable wire creation on mesh during Brep tessellation.
1336 
1337  int err = AllJtWTests(inResultDirectory); // all tests.
1338 
1339  tess_EndTesselation(); // End of tessellation
1340  cout <<"Jt Write end" << endl;
1341 
1342 
1343  return err;
1344 }

◆ ObjWriteSample()

int ObjWriteSample ( const Dtk_string inResultDirectory)
75 {
76  cout << endl << "----------------------------------------------" << endl;
77  cout << "Obj Write start" << endl;
78  //Standard Obj Sample File Processing
79  int err = StandardObjSample( inResultDirectory );
80  cout << "Obj Write end" << endl;
81  return err;
82 }

◆ ParasolidWriteSample()

int ParasolidWriteSample ( const Dtk_string inResultDirectory)
13 {
14  cout << endl << "----------------------------------------------" << endl;
15  cout << "Parasolid Write start" << endl;
16  // Choosing output directory and file name
17  Dtk_string outputDirectory = inResultDirectory + L"Parasolid/";
18  outputDirectory.FixPathSeparator();
19  outputDirectory.mkdir();
20  Dtk_string outputFileName0 = outputDirectory + L"sample_listofbody.x_t";
21 
22  // We construct 3 parts
26 
27  // We add the 3 parts in an array
28  Dtk_tab<Dtk_BodyPtr> arrayOfParts;
29  arrayOfParts.push_back( body1 );
30  arrayOfParts.push_back( body2 );
31  arrayOfParts.push_back( body3 );
32 
33  // First we initialize writing with name of files and protection function if needed (3rd parameter)
34  Dtk_bool muteMode = DTK_TRUE; // no log write
35  DtkErrorStatus status = psw_InitFile( outputFileName0, muteMode );
36 
37  if( status != dtkNoError )
38  {
39  cout << "error : " << dtkTypeError( status ).c_str() << endl;
40  return status;
41  }
42 
43 
44  // Then we write the 3 parts constructed
45  Dtk_Size_t i, l = arrayOfParts.size();
46  Dtk_tab<Dtk_ID> returnID;
47  for( i = 0; i < l; ++i )
48  status = psw_WriteBody( arrayOfParts[ i ], returnID );
49 
50  // And free memory allocated for writing
51  status = psw_EndFile( returnID );
52 
53 
54  if( status != dtkNoError )
55  {
56  cout << "error : " << dtkTypeError( status ).c_str() << endl;
57  }
58  else
59  cout << "=> " << outputFileName0.c_str() << endl;
60 
61 
62  // then we write the same 3 part as an assembly that use these parts 2 times
63  Dtk_string outputFileName1 = outputDirectory + L"sample_assemblyofbody.x_t";
64  status = psw_InitFile( outputFileName1, muteMode );
65 
66  // first we register all part ID
67  Dtk_tab<Dtk_ID> partID (l, 1);
68  for( i = 0; i < l; ++i )
69  {
70  returnID.clear();
71  status = psw_WriteBody( arrayOfParts[ i ], returnID );
72  if( returnID.size() > 1 )
73  { // if more than one parasolid body created we decide to create a subassembly
74  Dtk_ID outIdass;
75  status = psw_CreateEmptyAssembly( outIdass );
76  Dtk_transfoPtr MatrixIdentity = Dtk_transfo::create();
77  for( Dtk_Size_t j = 0; j < returnID.size(); j++ )
78  {
79  Dtk_ID outIdInst;
80  status = psw_CreateInstance( outIdass, returnID[ j ], MatrixIdentity, outIdInst );
81  }
82 
83  partID[ i ] = outIdass;
84  status = psw_LinkAttribut( outIdass );
85  }
86  else
87  partID[ i ] = returnID[ 0 ];
88 
89  Dtk_string partName = L"DtkPart";
90  partName.add_int((int)i);
92  info->SetName( partName );
93  info->SetId ( Dtk_Int32 (i + 1) );
94  Dtk_Val MyVal = Dtk_Val("MyValue");
95  info->AddCustomerDefinedAttribute("MyAttribute", MyVal);
96 
97  status = psw_CreateAttribut( partID[ i ], info );
98  }
99 
100  // we create an assembly
101  Dtk_ID assemblyID;
102  status = psw_CreateEmptyAssembly( assemblyID );
103 
104  Dtk_string assName = L"DtkAssembly";
105  Dtk_InfoPtr info = Dtk_Info::create();
106  info->SetName( assName );
107  info->SetId( 5 );
108 
109  status = psw_CreateAttribut( assemblyID, info );
110 
111  // we create each instance of the parts
112  for( i = 0; i < l; ++i )
113  {
115  Matrix1->setOrigin( Dtk_pnt( 100.0, 0.0, 0.0 ) );
116  Dtk_ID outIdInst;
117  status = psw_CreateInstance( assemblyID, partID[ i ], Matrix1, outIdInst );
118 
119  Dtk_string instName = L"DtkInstance";
120  instName.add_int( ( int )i );
121  info->SetName( instName );
122  info->SetId( Dtk_Int32( 10 + i) );
123  status = psw_CreateAttribut( outIdInst, info );
124 
125 
127  Matrix2->setOrigin( Dtk_pnt( 100.0, 100.0, 100.0 ) );
128  status = psw_CreateInstance( assemblyID, partID[ i ], Matrix2, outIdInst );
129 
130  Dtk_string instName2 = L"DtkInstance";
131  instName2.add_int( ( int )(i + l));
132  info->SetName( instName2 );
133  info->SetId( Dtk_Int32( 10 + i + l ) );
134  status = psw_CreateAttribut( outIdInst, info );
135  }
136 
137  status = psw_LinkAttribut( assemblyID );
138 
139  returnID.clear();
140  // And free memory allocated for writing
141  status = psw_EndFile( returnID );
142 
143  if( status != dtkNoError )
144  {
145  cout << "error : " << dtkTypeError( status ).c_str() << endl;
146  }
147  else
148  cout << "=> " << outputFileName1.c_str() << endl;
149 
150  cout << "Parasolid Write end" << endl;
151 
152  return 0;
153 }

◆ PdfWriteSample()

int PdfWriteSample ( const Dtk_string inResultDirectory)
1055 {
1056  Dtk_ErrorStatus errStatus;
1057  cout << endl << "----------------------------------------------" << endl;
1058  cout << "Pdf Write start" << endl;
1059 
1060  Dtk_string imageDirectory = L"../InputImages/";
1061  Dtk_string outputDirectory;
1062 
1063  // Choosing output directory and file name
1064  outputDirectory = inResultDirectory + L"Pdf/";
1065  outputDirectory.FixPathSeparator();
1066  outputDirectory.mkdir();
1067 
1068  Dtk_string pdfFileName = outputDirectory + L"PDFW_SampleOneMesh_1_1.pdf";
1069  errStatus = PdfwSampleOneMesh_1_1( pdfFileName );
1070 
1071  pdfFileName = outputDirectory + L"PDFW_SampleMeshes_1_2.pdf";
1072  errStatus = PdfwSampleMeshes_1_2( pdfFileName );
1073 
1074  pdfFileName = outputDirectory + L"PDFW_SampleOneMeshRender_1_3.pdf";
1075  errStatus = PdfwSampleOneMeshRender_1_3( pdfFileName, imageDirectory );
1076 
1077  pdfFileName = outputDirectory + L"PDFW_SampleBody_2_1.pdf";
1078  errStatus = PdfwSampleBody_2_1( pdfFileName );
1079 
1080  pdfFileName = outputDirectory + L"PDFW_SampleWireBody_2_2.pdf";
1081  errStatus = PdfwSampleWireBody_2_2( pdfFileName );
1082 
1083  pdfFileName = outputDirectory + L"PDFW_SampleBodyVisibility_2_3.pdf";
1084  errStatus = PdfwSampleBodyVisibility_2_3( pdfFileName );
1085 
1086  pdfFileName = outputDirectory + L"PDFW_SampleAssembly_3_1.pdf";
1087  errStatus = PdfwSampleAssembly_3_1( pdfFileName );
1088 
1089  pdfFileName = outputDirectory + L"PDFW_SamplePartInstances_3_2.pdf";
1090  errStatus = PdfwSamplePartInstances_3_2( pdfFileName );
1091 
1092  pdfFileName = outputDirectory + L"PDFW_SampleAsmInstances_3_3.pdf";
1093  errStatus = PdfwSampleAsmInstances_3_3( pdfFileName );
1094 
1095  pdfFileName = outputDirectory + L"PDFW_SampleInstancesColors_3_4.pdf";
1096  errStatus = PdfwSampleInstancesColors_3_4( pdfFileName );
1097 
1098  pdfFileName = outputDirectory + L"PDFW_SampleInstancesVisibility_3_5.pdf";
1099  errStatus = PdfwSampleInstancesVisibility_3_5( pdfFileName );
1100 
1101  pdfFileName = outputDirectory + L"PDFW_SampleMetadatas_4_1.pdf";
1102  errStatus = PdfwSampleMetadatas_4_1( pdfFileName );
1103 
1104  pdfFileName = outputDirectory + L"PDFW_SampleDocumentProperties_4_2.pdf";
1105  errStatus = PdfwSampleDocumentProperties_4_2( pdfFileName );
1106 
1107  pdfFileName = outputDirectory + L"PDFW_SampleSimplePMI_5_1.pdf";
1108  errStatus = PdfwSampleSimplePMI_5_1( pdfFileName );
1109 
1110  pdfFileName = outputDirectory + L"PDFW_SampleSimpleModelview_5_2.pdf";
1111  errStatus = PdfwSampleSimpleModelview_5_2( pdfFileName );
1112 
1113  pdfFileName = outputDirectory + L"PDFW_Sample_MV_association_5_3.pdf";
1114  errStatus = PdfwSample_MV_association_5_3( pdfFileName );
1115 
1116  pdfFileName = outputDirectory + L"PDFW_SamplePMI_Geom_association_5_4.pdf";
1117  errStatus = PdfwSamplePMI_Geom_association_5_4( pdfFileName );
1118 
1119  pdfFileName = outputDirectory + L"PDFW_SampleModelview_sections_5_5.pdf";
1120  errStatus = PdfwSampleModelview_section_5_5( pdfFileName );
1121 
1122  pdfFileName = outputDirectory + L"PDFW_SamplePMI_PMI_association_5_6.pdf";
1123  errStatus = PdfwSamplePMI_PMI_association_5_6( pdfFileName );
1124 
1125  pdfFileName = outputDirectory + L"PDFW_SampleAxis_References_5_7.pdf";
1126  errStatus = PdfwSampleAxis_References_5_7( pdfFileName );
1127 
1128  pdfFileName = outputDirectory + L"PDFW_SampleCloudPoint_6_1.pdf";
1129  errStatus = PdfwSampleCloudPoint_6_1( pdfFileName );
1130 
1131  pdfFileName = outputDirectory + L"PDFW_SampleBillboard_7_1.pdf";
1132 
1133  errStatus = PdfwSampleBillboard_7_1( pdfFileName, imageDirectory );
1134 
1135  pdfFileName = outputDirectory + L"PDFW_SampleSecuredPdf_8_1.pdf";
1136  errStatus = PdfwSampleSecuredPdf_8_1( pdfFileName );
1137 
1138  pdfFileName = outputDirectory + L"PDFW_SampleLayoutMultipleViews_9_1.pdf";
1139  errStatus = PdfwSampleLayoutMultipleViews_9_1( pdfFileName );
1140 
1141  cout << "Pdf Write end" << endl;
1142 
1143  return errStatus;
1144 }

◆ PlmxmlWriteSample()

int PlmxmlWriteSample ( const Dtk_string inResultDirectory)
101 {
102  std::cout << endl << "----------------------------------------------" << endl;
103  std::cout << "Plmxml Write start" << endl;
104 
105  tess_InitTesselation("./", 0.005); // For JT : Init Tessellation : working directory and default tolerance (needed for writing bodies)
106  tess_ComputeBoundariesFromMesh(0); // Disable wire creation on mesh during Brep tessellation.
107 
108  int err = PlmxmlwritesampleJT(inResultDirectory);
109 
110  tess_EndTesselation(); // End of tessellation
111  std::cout << "Plmxml Write end" << endl;
112 
113 
114  return err;
115 }

◆ SatWriteSample()

int SatWriteSample ( const Dtk_string inResultDirectory)
12 {
13  Dtk_string outputFileName, outputDirectory;
14 
15  cout << endl << "----------------------------------------------" << endl;
16  cout << "Acis Write start" << endl;
17 
18  // Choosing output directory and file name
19  outputDirectory = inResultDirectory + L"Acis/";
20  outputDirectory.FixPathSeparator();
21  outputDirectory.mkdir();
22  outputFileName = outputDirectory + L"sample.sat";
23 
24  // First you have to initialize the Sat writer
25  int status = satw_InitFile( outputFileName );
26 
27  if( status )
28  {
29  cout << "error : " << dtkTypeError( status ).c_str() << endl;
30  return status;
31  }
32 
33  // We create 2 bodies
36 
37  // We init the part
38  satw_InitPart();
39 
40  // We write the 2 bodies
41  satw_WriteBody( body1 );
42  satw_WriteBody( body2 );
43 
44  // We close the part
45  satw_EndPart();
46 
47  // We free memory allocated for writing
48  satw_EndFile();
49  cout << "=> " << outputFileName.c_str() << endl;
50  cout << "Acis Write end" << endl;
51 
52  return 0;
53 }

◆ StepWriteSample()

int StepWriteSample ( const Dtk_string inResultDirectory)
775 {
776  Dtk_string outputFileName, outputDirectory;
777 
778  std::cout << endl << "----------------------------------------------" << std::endl;
779  std::cout << "Step Write start" << std::endl;
780 
781  stepw_SetModeProp( 3 );
782  stepw_SetModeFdt( 1 );
783 
784  // Choosing output directory and file name
785  outputDirectory = inResultDirectory + L"Step/";
786  outputDirectory.FixPathSeparator();
787  outputDirectory.mkdir();
788 
789  // First, initialize the Step writer
790  //int codeForAP203 = 1;
791  int codeForAP214 = 2;
792  //int codeForAP203E2 = 3;
793  int codeForAP242 = 4;
794  int dummy;
795  {
796  outputFileName = outputDirectory + L"SampleMinimumProduct.step";
797  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
798  PRINT_ERROR( stepw::sample::Write_MinimumViableFile( L"SampleMinimumProduct", dummy ) );
800  std::cout << "=> " << outputFileName.c_str() << std::endl;
801  }
802  //[...]
803  //end_of_mainstepwrite
804  {
805  outputFileName = outputDirectory + L"SampleMinimumProduct_UserDefinedHeader.step";
806  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
807  stepw::sample::Write_UserDefinedHeader( L"SampleMinimumProduct_UserDefinedHeader", dummy );
809  std::cout << "=> " << outputFileName.c_str() << std::endl;
810  }
811  {
812  outputFileName = outputDirectory + L"SamplePart_BodyOnly.step";
813  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
814  stepw::sample::WritePart_BodyOnly( L"SamplePart_BodyOnly", dummy );
816  std::cout << "=> " << outputFileName.c_str() << std::endl;
817  }
818  {
819  outputFileName = outputDirectory + L"SamplePart_BodyWithAxisSystem.step";
820  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
821  stepw::sample::WritePart_BodyWithAxisSystem( L"SamplePart_BodyWithAxisSystem", dummy );
823  std::cout << "=> " << outputFileName.c_str() << std::endl;
824  }
825  {
826  outputFileName = outputDirectory + L"SamplePart_WireframeOnly.step";
827  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
828  stepw::sample::WritePart_WireframeOnly( L"SamplePart_WireframeOnly", dummy );
830  std::cout << "=> " << outputFileName.c_str() << std::endl;
831  }
832  {
833  outputFileName = outputDirectory + L"SamplePart_MeshOnly.step";
834  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
835  stepw::sample::WritePart_MeshOnly( L"SamplePart_MeshOnly", dummy );
837  std::cout << "=> " << outputFileName.c_str() << std::endl;
838  }
839  {
840  outputFileName = outputDirectory + L"SamplePart_MeshWithFaceColors.step";
841  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
842  stepw::sample::WritePart_MeshWithFaceColors( L"SamplePart_MeshWithFaceColors", dummy );
844  std::cout << "=> " << outputFileName.c_str() << std::endl;
845  }
846  {
847  outputFileName = outputDirectory + L"SamplePart_BodyAndMeshFromTessellation.step";
848  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
849  stepw::sample::WritePart_BodyAndMeshFromTessellation( L"SamplePart_BodyAndMeshFromTessellation", dummy );
851  std::cout << "=> " << outputFileName.c_str() << std::endl;
852  }
853  {
854  outputFileName = outputDirectory + L"SamplePart_WithProperties.step";
855  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP214 ) );
856  stepw::sample::WritePart_WithProperties( L"SamplePart_WithProperties", dummy );
858  std::cout << "=> " << outputFileName.c_str() << std::endl;
859  }
860  {
861  outputFileName = outputDirectory + L"SamplePart_BodyInNamedLayer.step";
862  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
863  stepw::sample::WritePart_BodyInNamedLayer( L"SamplePart_BodyInNamedLayer", dummy );
865  std::cout << "=> " << outputFileName.c_str() << std::endl;
866  }
867  {
868  outputFileName = outputDirectory + L"SamplePart_Datum.step";
869  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
870  stepw::sample::WritePart_Datum( L"SamplePart_Datum", dummy );
872  std::cout << "=> " << outputFileName.c_str() << std::endl;
873  }
874  {
875  outputFileName = outputDirectory + L"SamplePart_GeometricalTolerance.step";
876  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
877  stepw::sample::WritePart_GeometricalTolerance( L"SamplePart_GeometricalTolerance", dummy );
879  std::cout << "=> " << outputFileName.c_str() << std::endl;
880  }
881  {
882  outputFileName = outputDirectory + L"SamplePart_UsedByExternalAssembly.step";
883  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
884  stepw::sample::WritePart_UsedByExternalAssembly( L"SamplePart_UsedByExternalAssembly", dummy );
886  std::cout << "=> " << outputFileName.c_str() << std::endl;
887  }
888  {
889  outputFileName = outputDirectory + L"SampleAssembly.step";
890  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
891  stepw::sample::WriteAssembly( L"SampleAssembly" );
893  std::cout << "=> " << outputFileName.c_str() << std::endl;
894  }
895  {
896  outputFileName = outputDirectory + L"SampleAssembly_DimensionFDT.step";
897  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
898  stepw::sample::WriteAssembly_DimensionFDT( L"SampleAssembly_DimensionFDT");
900  std::cout << "=> " << outputFileName.c_str() << std::endl;
901  }
902  {
903  outputFileName = outputDirectory + L"SampleAssembly_WithProperties.step";
904  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
905  stepw::sample::WriteAssembly_WithProperties( L"SampleAssembly_WithProperties");
907  std::cout << "=> " << outputFileName.c_str() << std::endl;
908  }
909  {
910  outputFileName = outputDirectory + L"SampleAssembly_InstanceAttributes.step";
911  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
912  stepw::sample::WriteAssembly_InstanceAttributes( L"SampleAssembly_InstanceAttributes" );
914  std::cout << "=> " << outputFileName.c_str() << std::endl;
915  }
916  {
917  outputFileName = outputDirectory + L"SampleAssembly_BasicExternalReferences.step";
918  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
919  stepw::sample::WriteAssembly_BasicExternalReferences( L"SampleAssembly_BasicExternalReferences");
921  std::cout << "=> " << outputFileName.c_str() << std::endl;
922  }
923  {
924  outputFileName = outputDirectory + L"SampleAssembly_BasicExternalReference_DimensionFDT.step";
925  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
926  stepw::sample::WriteAssembly_BasicExternalReference_DimensionFDT( L"SampleAssembly_BasicExternalReference_DimensionFDT");
928  std::cout << "=> " << outputFileName.c_str() << std::endl;
929  }
930  {
931  outputFileName = outputDirectory + L"SampleAssembly_NestedExternalReferences.step";
932  PRINT_ERROR( stepw_InitFile( outputFileName, " sample ", codeForAP242 ) );
933  stepw::sample::WriteAssembly_NestedExternalReferences( L"SampleAssembly_NestedExternalReferences");
935  std::cout << "=> " << outputFileName.c_str() << std::endl;
936  }
937 
938  std::cout << "Step Write end" << std::endl;
939 
940  return 0;
941 }

◆ SwWriteSample()

int SwWriteSample ( Dtk_API inDtkAPI,
const Dtk_string inResultDirectory 
)
213 {
214  cout << endl << "----------------------------------------------" << endl;
215  cout << "Solidworks Write start" << endl;
216  // Choosing output directory and file name
217  Dtk_string outputDirectory = inResultDirectory + "Sw/";
218  outputDirectory.FixPathSeparator();
219  outputDirectory.mkdir();
220  {
221  //remove old file
222  Dtk_string temp;
223  temp = outputDirectory + L"my_test_part.sldprt";
224  temp.unlink();
225  temp = outputDirectory + L"my_test_part2.sldprt";
226  temp.unlink();
227  temp = outputDirectory + L"my_test_assembly.sldasm";
228  temp.unlink();
229  temp = outputDirectory + L"logwrite.txt";
230  temp.unlink();
231  }
232 
233  Dtk_ErrorStatus dtkerror;
234 
235  Dtk_string StrSchemaPath = inResultDirectory + L"../bin/Schema/";
236 
237 #ifdef PSKERNEL_USER
238  //First if you haven't done yet, start the parasolid session
239  StartParasolid();
240  //And informs that the session is started
242 
243  //Set the schema path
244 #ifndef Linux
245  wchar_t *schPath;
246  schPath = ( wchar_t* )malloc( sizeof( wchar_t ) * ( StrSchemaPath.len() + 10 ) );
247  swprintf( schPath, 255, L"P_SCHEMA=%s", StrSchemaPath.w_str() );
248  _wputenv( schPath );
249 #else
250  char *schPath;
251  schPath = ( char* )malloc( sizeof( char ) * ( StrSchemaPath.len() + 10 ) );
252  sprintf( schPath, "P_SCHEMA=%s", StrSchemaPath.c_str() );
253  putenv( schPath );
254 #endif
255 
256  //dont delete it because getenv doesn't work or retrun null string
257  //free(schPath);
258  //schPath=NULL;
259 #endif
260  if( inDtkAPI != NULL )
261  inDtkAPI->SetSchemaDir( StrSchemaPath );
262  else
263  {
264  return dtkErrorAPINotStarted;
265  }
266 
267  Dtk_string logwrite = inDtkAPI->GetWorkingDir() + L"logwrite.txt";
268  Dtk_string FilenamePart;
269  dtkerror = sw::sww::InitWriter( logwrite, NULL, sw::sww::english );
270 
271  Dtk_string xmtfile = inResultDirectory + L"/xmt/CS_WHEEL_CAP.X_T";
272 
273 
274  if( dtkerror == dtkNoError )
275  {
276  //how to create part file
277  FilenamePart = outputDirectory + L"my_test_part.sldprt";
278  create_part( FilenamePart, xmtfile );
279  }
280 
281 
282  if( dtkerror == dtkNoError )
283  {
284  FilenamePart = outputDirectory + L"my_test_part2.sldprt";
285  create_part( FilenamePart, xmtfile );
286  }
287 
288 
289  if( dtkerror == dtkNoError )
290  {
291  //how to create assembly file
292  Dtk_string FilenameAssm = outputDirectory + L"my_test_assembly.sldasm";
293  create_assembly( FilenameAssm, FilenamePart );
294  }
295 
297 
298 #ifdef PSKERNEL_USER
299  //Stop the parasolid session
301  StopParasolid();
302 #endif
303  cout << "Solidworks Write end" << endl;
304 
305  return dtkerror;
306 }

◆ UgWriteSample()

int UgWriteSample ( const Dtk_string inResultDirectory)
763 {
764  Dtk_string outputDirectory, nxDirectory;
765  Dtk_ErrorStatus errStatus;
766 
767  std::cout << endl << "----------------------------------------------" << endl;
768  std::cout << "Ug Write start" << endl;
769 
770  nxDirectory = inResultDirectory + L"NX-Unigraphics/";
771  nxDirectory.FixPathSeparator();
772  nxDirectory.mkdir();
773 
774  // Choosing output for version NX5
775  outputDirectory = inResultDirectory + L"NX-Unigraphics/nx5/";
776  outputDirectory.FixPathSeparator();
777  outputDirectory.mkdir();
778  errStatus = UgWriteSampleVersion(outputDirectory, DTK_UGW_VERSION_NX5);
779 
780  // Choosing output for version NX1980
781  outputDirectory = inResultDirectory + L"NX-Unigraphics/nx1980/";
782  outputDirectory.FixPathSeparator();
783  outputDirectory.mkdir();
784  errStatus = UgWriteSampleVersion(outputDirectory, DTK_UGW_VERSION_NX1980);
785 
786  // Choosing output for version NX2212
787  outputDirectory = inResultDirectory + L"NX-Unigraphics/nx2212/";
788  outputDirectory.FixPathSeparator();
789  outputDirectory.mkdir();
790  errStatus = UgWriteSampleVersion(outputDirectory, DTK_UGW_VERSION_NX2212);
791 
792  std::cout << "Ug Write end" << endl;
793 
794  return errStatus;
795 }
PdfwSampleSecuredPdf_8_1
Dtk_ErrorStatus PdfwSampleSecuredPdf_8_1(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:877
satw_InitPart
DtkErrorStatus satw_InitPart()
Initializes the writing of a 3D part.
Dtk_mesh_asm_node
This class gathers asm node related datas.
Definition: cgrw.hpp:21
ProcessAsm
Dtk_ErrorStatus ProcessAsm(const Dtk_string &inResultDirectory)
Definition: testlibcatiav5write.cpp:346
Dtk_ID
uint32_t Dtk_ID
Definition: define.h:692
Dtk_transfo
This is the Transformation dedicated class.
Definition: dtk_transfo.hpp:19
ProcessBasicWall
Dtk_ErrorStatus ProcessBasicWall(Dtk_bool inMesh)
Definition: testlibifcwrite.cpp:18
Ifcw::ProjectInformation::buildingName
Dtk_string buildingName
Definition: IFCWriter.h:56
PdfwSampleMetadatas_4_1
Dtk_ErrorStatus PdfwSampleMetadatas_4_1(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:475
psw_CreateInstance
DtkErrorStatus psw_CreateInstance(Dtk_ID inIdAss, Dtk_ID inIdPart, Dtk_transfoPtr &Matrix, Dtk_ID &outIdInst)
Create an Instance item of a part referenced by inIdPart.
Dtk_Info::SetName
Dtk_ErrorStatus SetName(Dtk_string inName)
sampleWriter::CreateMeshCube
Dtk_MeshPtr CreateMeshCube()
Mesh Cube sample.
Definition: testcreatemesh.cpp:204
stepw::sample::WritePart_MeshOnly
DtkErrorStatus WritePart_MeshOnly(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:132
PdfwSampleAxis_References_5_7
Dtk_ErrorStatus PdfwSampleAxis_References_5_7(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:759
psw_InitFile
DtkErrorStatus psw_InitFile(const Dtk_string &inFileOut, Dtk_bool muteMode, Dtk_Int32 inVersion=180)
Initialise a file to be written.
Colladaw::EndNode
DtkErrorStatus EndNode()
End the node.
catiav5w::WriteOptions
This class provides several options to tunes CatiaV5 Writter. It must be provided to catiav5w::InitWr...
Definition: catiav5w.hpp:41
Dtk_Info::AddCustomerDefinedAttribute
Dtk_ErrorStatus AddCustomerDefinedAttribute(Dtk_string name, Dtk_Val val)
Dtk_transfo::setOrigin
void setOrigin(const Dtk_pnt &O)
Set a new O center point.
Dtk_mesh_asm_node::set_id
void set_id(int inId)
Set an Id.
Dtk_transfo::create
static Dtk_SmartPtr< Dtk_transfo > create()
Dtk_transfo::setZdir
void setZdir(const Dtk_dir &Z)
Set a new Z vector.
Ifcw::ProjectInformation::siteElevation
Dtk_Double64 siteElevation
Definition: IFCWriter.h:62
Colladaw::InitWrite
DtkErrorStatus InitWrite(const Dtk_string &inOutputFile, const Dtk_string &inLogFile, WriteOptions &inOptions)
Initialize the Collada Writer
Ifcw::InitWrite
DtkErrorStatus InitWrite(const Dtk_string &inOutputFile, const Dtk_string &inLogFile, const WriteOptions &inOptions, ProjectInformation *inProjectInfo=nullptr)
Initialize the Ifc Writer and the IFC version you want to write.
Ifcw::WriteOptions::versionIndicator
int versionIndicator
Int representing IFC version to use : 0 ( default ) = IFC2x3; 1 = IFC4.
Definition: IFCWriter.h:28
tess_InitTesselation
int tess_InitTesselation(Dtk_string inWorkingDirectory, double inTolerance)
Init the tesselation library.
DTK_TRUE
#define DTK_TRUE
Definition: define.h:730
_3dxmlw::WriteOptions
This class provides several options to tune 3dxml Writer. It must be provided to _3dxmlw::InitWrite m...
Definition: 3dxmlw.hpp:89
Dtk_mesh_asm_node::add_axis_system
int add_axis_system(Dtk_AxisSystemPtr inAxisSystem)
Add an Dtk_AxisSystemPtr in Dtk_mesh_asm_node in the current asm node.
Ifcw::WriteOptions::buildingTypeRecognition
Dtk_bool buildingTypeRecognition
DTK_TRUE : enable building type recognition (deduces if an element is an IFCWALL, IFCWINDOW....
Definition: IFCWriter.h:30
create_assembly
void create_assembly(const Dtk_string &inFilename, const Dtk_string &inFilenamePart)
Definition: testlibswwrite.cpp:144
DTK_UGW_VERSION_NX5
#define DTK_UGW_VERSION_NX5
Definition: ugw.hpp:7
FbxwInstances
Dtk_ErrorStatus FbxwInstances(const Dtk_string &outputFileName)
Definition: testlibfbxwrite.cpp:53
PdfwSamplePartInstances_3_2
Dtk_ErrorStatus PdfwSamplePartInstances_3_2(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:232
Dtk_string
This is a high level string class.
Definition: dtk_string.hpp:53
Dtk_Size_t
size_t Dtk_Size_t
Definition: define.h:715
create_part
void create_part(const Dtk_string &inFilename, const Dtk_string &inParasolidFile)
Definition: testlibswwrite.cpp:56
Dtk_string::unlink
int unlink() const
File Utility : Delete a file.
stepw::sample::WritePart_BodyWithAxisSystem
DtkErrorStatus WritePart_BodyWithAxisSystem(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:95
Ifcw::ProjectInformation::projectAuthor
Dtk_string projectAuthor
Definition: IFCWriter.h:57
sampleWriter::CreateAxisSystem
Dtk_AxisSystemPtr CreateAxisSystem()
Definition: testcreatecube.cpp:1525
PdfwSampleLayoutMultipleViews_9_1
Dtk_ErrorStatus PdfwSampleLayoutMultipleViews_9_1(const Dtk_string &pdfFileName)
Definition: testlibpdfwrite.cpp:1001
PRINT_ERROR
#define PRINT_ERROR(inStatus)
Definition: testwriters.h:10
stepw::sample::WritePart_WireframeOnly
DtkErrorStatus WritePart_WireframeOnly(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:115
PdfwSampleModelview_section_5_5
Dtk_ErrorStatus PdfwSampleModelview_section_5_5(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:672
Dtk_bool
char Dtk_bool
Definition: define.h:728
Dtk_API::GetWorkingDir
const Dtk_string & GetWorkingDir() const
tess_ComputeBoundariesFromMesh
void tess_ComputeBoundariesFromMesh(int value)
Set boundaries computation from mesh option. Default value is enabled (1). See tess_getBoundariesFrom...
PdfwSampleBillboard_7_1
Dtk_ErrorStatus PdfwSampleBillboard_7_1(const Dtk_string &inOutputFileName, const Dtk_string &inImageDirectory)
Definition: testlibpdfwrite.cpp:844
dtkErrorAPINotStarted
@ dtkErrorAPINotStarted
Definition: error_dtk.hpp:105
Dtk_API::SetSchemaDir
Dtk_ErrorStatus SetSchemaDir(const Dtk_string &inSchemaDir)
Set Schema Directory needed for Unigraphics, Parasolid, Solidedge, Solidworks and Jt readers.
Dtk_mesh_asm_node::set_color
void set_color(Dtk_RGB &inColor)
set color on Dtk_mesh_asm_node
Colladaw::EndWrite
DtkErrorStatus EndWrite()
Creation of the output file and free the Collada Writer
Dtk_transfo::setXdir
void setXdir(const Dtk_dir &X)
Set a new X vector.
sampleWriter::FillFacesColors
void FillFacesColors(Dtk_MeshPtr &inoutCubeMesh)
Filling mesh faces with colors.
Definition: testcreatemesh.cpp:241
cgrw_EndWrite
int cgrw_EndWrite()
Free the Cgr Writer
stepw_SetModeProp
DtkErrorStatus stepw_SetModeProp(const int inMode)
Activates/Deactivates writing of properties : User Attributes, Product Data.
Dtk_3MFWriter::InitWrite
DtkErrorStatus InitWrite(const Dtk_string &inOutputFile, const Dtk_string &inLogFile, const WriteOptions &inOptions)
Initialize the 3mf Writer
Dtk_string::add_int
void add_int(const int integer, int force_unsigned_int=0)
concat an int to the Dtk_string (convert the int to Dtk_string)
psw_CreateAttribut
DtkErrorStatus psw_CreateAttribut(Dtk_ID inIdCompo, Dtk_InfoPtr &info)
Create all attribut attached to a component (body, assembly, instance)
Dtk_Val
Definition: dtk_val.hpp:67
Colladaw::WriteOptions
This class provides several options to tune Collada Writer. It must be provided to Colladaw::InitWrit...
Definition: colladaw.hpp:23
WriteEntity
Dtk_ErrorStatus WriteEntity(const Dtk_MeshPtr &inCubeMesh, const Dtk_MeshPtr &inCylinderMesh)
Definition: testlib3dxmlwrite.cpp:12
stepw_InitFile
DtkErrorStatus stepw_InitFile(const Dtk_string &inFileName, const char *inOriginatingSystem=" user ", const int inSchema=0)
Initializes a file to be written.
PdfwSampleInstancesVisibility_3_5
Dtk_ErrorStatus PdfwSampleInstancesVisibility_3_5(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:429
PlmxmlwritesampleJT
Dtk_ErrorStatus PlmxmlwritesampleJT(const Dtk_string &inResultDirectory)
Definition: testlibplmxmlwrite.cpp:36
stepw::sample::WriteAssembly_BasicExternalReferences
DtkErrorStatus WriteAssembly_BasicExternalReferences(const Dtk_string &inRootAssemblyName)
Definition: testlibstepwrite.cpp:612
sampleWriter::CreateMeshWire
Dtk_MeshPtr CreateMeshWire()
Wire mesh sample.
Definition: testcreatemesh.cpp:385
PdfwSampleOneMesh_1_1
Dtk_ErrorStatus PdfwSampleOneMesh_1_1(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:22
Colladaw::WriteOptions::ConvertRenderInfos
Dtk_bool ConvertRenderInfos
Definition: colladaw.hpp:33
stepw::sample::WritePart_BodyOnly
DtkErrorStatus WritePart_BodyOnly(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:77
sw::sww::InitWriter
Dtk_ErrorStatus InitWriter(const Dtk_string &inLogFile, Licence_dtk inLicFct, sw::sww::language inLanguage=sw::sww::english)
Initialize the Solidworks Writer
stepw_SetModeFdt
DtkErrorStatus stepw_SetModeFdt(const int inMode, const int inPolyline=2)
Activates/Deactivates writing of FDT.
_3dxmlw::EndWrite
DtkErrorStatus EndWrite()
Creation of the output file and free the 3dxmlw Writer
Dtk_3MFWriter::WriteOptions
This class provides several options to tune 3mf Writer. It must be provided to _3mfw::InitWrite metho...
Definition: 3mfw.hpp:29
PdfwSampleCloudPoint_6_1
Dtk_ErrorStatus PdfwSampleCloudPoint_6_1(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:788
stepw::sample::Write_MinimumViableFile
DtkErrorStatus Write_MinimumViableFile(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:52
ProcessMultiMeshWall
Dtk_ErrorStatus ProcessMultiMeshWall()
Definition: testlibifcwrite.cpp:141
Ifcw::ProjectInformation::siteLatitude
Dtk_Double64 siteLatitude
Definition: IFCWriter.h:60
cgrw_WriteMeshAsm
Dtk_status cgrw_WriteMeshAsm(Dtk_mesh_asm_node *inRoot)
Write a mesh assembly.
Dtk_Int32
int32_t Dtk_Int32
Definition: define.h:690
FbxwTwoMeshes
Dtk_ErrorStatus FbxwTwoMeshes(const Dtk_string &outputFileName)
Definition: testlibfbxwrite.cpp:12
stepw::sample::WritePart_BodyInNamedLayer
DtkErrorStatus WritePart_BodyInNamedLayer(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:357
IgesAssemblySample
int IgesAssemblySample(const Dtk_string &inResultDirectory)
Definition: testlibigeswrite.cpp:66
sw::sww::EndWriter
Dtk_ErrorStatus EndWriter()
Free the Solidworks Writer
Ifcw::WriteOptions
This class provides several options to tune the IFC Writer. It must be provided to Ifcw::InitWrite me...
Definition: IFCWriter.h:18
PdfwSampleBodyVisibility_2_3
Dtk_ErrorStatus PdfwSampleBodyVisibility_2_3(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:159
PdfwSampleMeshes_1_2
Dtk_ErrorStatus PdfwSampleMeshes_1_2(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:46
Dtk_SmartPtr< Dtk_Entity >::DtkDynamicCast
static Dtk_SmartPtr< Dtk_Entity > DtkDynamicCast(const Dtk_SmartPtr< T2 > &p)
Definition: util_ptr_dtk.hpp:101
GltfwTwoMeshes
Dtk_ErrorStatus GltfwTwoMeshes(const Dtk_string &outputFileName)
Definition: testlibgltfwrite.cpp:13
cgrw_InitWrite
int cgrw_InitWrite(Dtk_string inFileWritten, Dtk_string inLogFile, Licence_dtk inLicFct, Dtk_string inLicenceFile, const WriteOptions &inOptions=WriteOptions())
Initialize the Cgr Writer
psw_CreateEmptyAssembly
DtkErrorStatus psw_CreateEmptyAssembly(Dtk_ID &outIdass)
Create the entry item of an assembly.
Dtk_ErrorStatus
Dtk_ErrorStatus
Definition: error_dtk.hpp:6
satw_InitFile
DtkErrorStatus satw_InitFile(const Dtk_string &inFileOut, const satw_WriteOptions &inOptions=satw_WriteOptions())
Initializes a file to be written.
Dtk_3MFWriter::WriteEntity
Dtk_ErrorStatus WriteEntity(const Dtk_EntityPtr &inEntity)
Write the entity provided in parameter in a node.
stepw::sample::WritePart_Datum
DtkErrorStatus WritePart_Datum(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:231
sampleWriter::CreateCubeRenderInfos
Dtk_RenderInfosPtr CreateCubeRenderInfos()
Definition: testcreatemesh.cpp:495
Dtk_Info::SetId
Dtk_ErrorStatus SetId(const Dtk_Int32 &inId)
stepw::sample::WriteAssembly_InstanceAttributes
DtkErrorStatus WriteAssembly_InstanceAttributes(const Dtk_string &inRootAssemblyName)
Definition: testlibstepwrite.cpp:570
ProcessPrototypedColumns
Dtk_ErrorStatus ProcessPrototypedColumns(int columnNumber)
Definition: testlibifcwrite.cpp:90
stepw::sample::WriteAssembly_BasicExternalReference_DimensionFDT
DtkErrorStatus WriteAssembly_BasicExternalReference_DimensionFDT(const Dtk_string &inRootAssemblyName)
Definition: testlibstepwrite.cpp:693
Ifcw::EndWrite
DtkErrorStatus EndWrite()
Creation of the output file and free the Ifc Writer
Dtk_transfo::setScale
void setScale(Dtk_Double64 scale)
Set a new scale.
Dtk_SmartPtr
Definition: util_ptr_dtk.hpp:37
stepw_EndFile
DtkErrorStatus stepw_EndFile()
Ends the writing of the current STEP file.
Ifcw::ProjectInformation::siteLongitude
Dtk_Double64 siteLongitude
Definition: IFCWriter.h:61
dtkTypeError
Dtk_string dtkTypeError(Dtk_Int32 errNumero)
catiav5w::EndWrite
Dtk_ErrorStatus EndWrite()
Free the Catia V5 Writer
catiav5w::WriteOptions::SetFileRelease
Dtk_ErrorStatus SetFileRelease(const Dtk_UInt32 inRelease)
Sets the release for the written files.
Dtk_string::c_str
const char * c_str() const
Retrieve the ASCII conversion string.
sampleWriter::CreateMeshCylinder
Dtk_MeshPtr CreateMeshCylinder(int nbpoints)
Mesh Cylinder sample.
Definition: testcreatemesh.cpp:334
stepw::sample::Write_UserDefinedHeader
DtkErrorStatus Write_UserDefinedHeader(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:63
PdfwSampleInstancesColors_3_4
Dtk_ErrorStatus PdfwSampleInstancesColors_3_4(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:331
Dtk_mesh_asm_node::add_mesh
int add_mesh(Dtk_MeshPtr mesh)
Add an Dtk_mesh in Dtk_mesh_asm_node in the current asm node.
Dtk_transfo::setYdir
void setYdir(const Dtk_dir &Y)
Set a new Y vector.
PdfwSampleAssembly_3_1
Dtk_ErrorStatus PdfwSampleAssembly_3_1(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:191
Dtk_string::mkdir
int mkdir() const
File Utility : Create a Directory.
PdfwSampleSimplePMI_5_1
Dtk_ErrorStatus PdfwSampleSimplePMI_5_1(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:545
Dtk_pnt
This is a mathematical point class.
Definition: dtk_pnt.hpp:20
UgWriteSampleVersion
Dtk_ErrorStatus UgWriteSampleVersion(const Dtk_string &outputDirectory, int version)
Definition: testlibugwrite.cpp:690
PdfwSamplePMI_Geom_association_5_4
Dtk_ErrorStatus PdfwSamplePMI_Geom_association_5_4(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:640
psw_WriteBody
Dtk_ErrorStatus psw_WriteBody(Dtk_BodyPtr &inBody)
Writes a Body of a 3D part (3D content of a product), of any kind (solid, shell / faces,...
PdfwSampleAsmInstances_3_3
Dtk_ErrorStatus PdfwSampleAsmInstances_3_3(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:276
Dtk_string::FixPathSeparator
void FixPathSeparator()
File Utility : Fixes path separator consistency. It lets you replace the '\' or '/' by the OS needed ...
stepw::sample::WritePart_UsedByExternalAssembly
DtkErrorStatus WritePart_UsedByExternalAssembly(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:330
PdfwSample_MV_association_5_3
Dtk_ErrorStatus PdfwSample_MV_association_5_3(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:599
PdfwSampleDocumentProperties_4_2
Dtk_ErrorStatus PdfwSampleDocumentProperties_4_2(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:501
satw_EndPart
DtkErrorStatus satw_EndPart()
Ends the writing of a part.
sw::sww::english
@ english
Definition: solidworksw.hpp:25
Dtk_3MFWriter
3MF Writer main class.
Definition: 3mfw.hpp:16
Colladaw::ReinstanciatePrototype
DtkErrorStatus ReinstanciatePrototype(Dtk_ID inID)
Reinstanciate a node.
stepw::sample::WriteAssembly_WithProperties
DtkErrorStatus WriteAssembly_WithProperties(const Dtk_string &inRootAssemblyName)
Definition: testlibstepwrite.cpp:516
stepw::sample::WritePart_GeometricalTolerance
DtkErrorStatus WritePart_GeometricalTolerance(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:279
stepw::sample::WriteAssembly_NestedExternalReferences
DtkErrorStatus WriteAssembly_NestedExternalReferences(const Dtk_string &inRootAssemblyName)
Definition: testlibstepwrite.cpp:651
Dtk_tab
This is a high level array class.
Definition: util_stl_dtk.hpp:84
Dtk_transfo::addTranslate
void addTranslate(const Dtk_dir &V)
Translate the Dtk_transfo.
WriteOptions
This class provides several options to tunes cgr Writter. It must be provided to cgr::cgrw_InitWrite ...
Definition: cgrw.hpp:82
sampleWriter::CreateCube
Dtk_BodyPtr CreateCube()
Definition: testcreatecube.cpp:1316
stepw::sample::WritePart_BodyAndMeshFromTessellation
DtkErrorStatus WritePart_BodyAndMeshFromTessellation(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:170
Dtk_tab::size
Dtk_Size_t size() const
Returns the size of the array.
Definition: util_stl_dtk.hpp:503
Ifcw::ProjectInformation
This struct enables the user to define global properties regarding the project, construction site and...
Definition: IFCWriter.h:51
DTK_UGW_VERSION_NX1980
#define DTK_UGW_VERSION_NX1980
Definition: ugw.hpp:8
GltfwInstances
Dtk_ErrorStatus GltfwInstances(const Dtk_string &outputFileName)
Definition: testlibgltfwrite.cpp:53
_3dxmlw::InitWrite
DtkErrorStatus InitWrite(const Dtk_string &inOutputFile, const Dtk_string &inLogFile, WriteOptions &inOptions)
Initialize the 3dxmlw Writer
PdfwSamplePMI_PMI_association_5_6
Dtk_ErrorStatus PdfwSamplePMI_PMI_association_5_6(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:720
PdfwSampleWireBody_2_2
Dtk_ErrorStatus PdfwSampleWireBody_2_2(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:137
stepw::sample::WritePart_WithProperties
DtkErrorStatus WritePart_WithProperties(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:195
Dtk_string::len
int len() const
Retrieve the length of the Dtk_string.
Colladaw::InitNode
DtkErrorStatus InitNode(Dtk_string &inNodeName, const Dtk_transfo &inTransfo, Dtk_InfoPtr &inInfo, Dtk_ID &outID)
Initialize a node.
StandardObjSample
int StandardObjSample(const Dtk_string &inResultDirectory)
Definition: testlibobjwrite.cpp:12
psw_EndFile
DtkErrorStatus psw_EndFile(Dtk_tab< Dtk_ID > &inTabIds, Dtk_bool binForceListOfBody=DTK_FALSE)
Ends the writing of the Parasolid (x_t or x_b) file.
PdfwSampleSimpleModelview_5_2
Dtk_ErrorStatus PdfwSampleSimpleModelview_5_2(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:567
sampleWriter::CreateCurves
Dtk_BodyPtr CreateCurves()
Definition: testcreatecube.cpp:1357
stepw::sample::WriteAssembly
DtkErrorStatus WriteAssembly(const Dtk_string &inRootAssemblyName)
Definition: testlibstepwrite.cpp:390
Dtk_3MFWriter::EndWrite
DtkErrorStatus EndWrite()
Creation of the output file and free the Obj Writer
tess_EndTesselation
void tess_EndTesselation()
Free the data used by tesselation library.
stepw::sample::WriteAssembly_DimensionFDT
DtkErrorStatus WriteAssembly_DimensionFDT(const Dtk_string &inRootAssemblyName)
Definition: testlibstepwrite.cpp:429
dtkNoError
@ dtkNoError
Definition: error_dtk.hpp:147
Dtk_tab::push_back
void push_back(const T &x)
Inserts an element at the end of the array.
Definition: util_stl_dtk.hpp:416
catiav5w::InitWrite
Dtk_ErrorStatus InitWrite(const Dtk_string &inLogFile, Licence_dtk inLicFct, const WriteOptions &inOptions=WriteOptions())
Initialize the Catia V5 Writer
PdfwSampleOneMeshRender_1_3
Dtk_ErrorStatus PdfwSampleOneMeshRender_1_3(const Dtk_string &inOutputFileName, const Dtk_string &inImageDirectory)
Definition: testlibpdfwrite.cpp:101
satw_WriteBody
DtkErrorStatus satw_WriteBody(const Dtk_BodyPtr &inBody)
Writes a Body.
psw_LinkAttribut
DtkErrorStatus psw_LinkAttribut(Dtk_ID inIdAss)
link all attributes attached to an assembly
Dtk_tab::clear
void clear(int no_delete=0)
Resets the Dtk_tab content.
Definition: util_stl_dtk.hpp:352
PdfwSampleBody_2_1
Dtk_ErrorStatus PdfwSampleBody_2_1(const Dtk_string &inOutputFileName)
Definition: testlibpdfwrite.cpp:120
Dtk_RGB
Definition: dtk_rgb.hpp:7
AllJtWTests
int AllJtWTests(const Dtk_string &inResultDirectory)
Definition: testlibjtwrite.cpp:1240
WriteOptions::SetFileRelease
void SetFileRelease(const Dtk_UInt32 inRelease)
Sets the release for the written files.
Definition: cgrw.hpp:95
Dtk_Info::create
static Dtk_SmartPtr< Dtk_Info > create()
Calls default constructor to allocate a new object.
Colladaw::WriteEntity
Dtk_ErrorStatus WriteEntity(const Dtk_EntityPtr &inEntity)
Write the entity provided in parameter in a node.
Dtk_dir
This is a mathematical direction class.
Definition: dtk_dir.hpp:14
Dtk_mesh_asm_node::add_asm_instance
int add_asm_instance(Dtk_mesh_asm_node *inMeshAsm, Dtk_transfo *inTransfo)
Add an asm instance to the current asm node.
DTK_UGW_VERSION_NX2212
#define DTK_UGW_VERSION_NX2212
Definition: ugw.hpp:9
stepw::sample::WritePart_MeshWithFaceColors
DtkErrorStatus WritePart_MeshWithFaceColors(const Dtk_string &inPartName, int &outPartID)
Definition: testlibstepwrite.cpp:150
ProcessWallClassification
Dtk_ErrorStatus ProcessWallClassification()
Definition: testlibifcwrite.cpp:57
sampleWriter::CreateOpenShell
Dtk_BodyPtr CreateOpenShell()
Definition: testcreatecube.cpp:1343
sw::sww::SetIsAlreadyStart
void SetIsAlreadyStart(const Dtk_Int32 &inStop)
ONLY for PSKERNEL user.
satw_EndFile
DtkErrorStatus satw_EndFile()
Ends the writing of the Sat file.