![Logo](tetiere_ht.jpg) |
DATAKIT API
V2025.1
|
|
Datakit API allows you to read data coming from many software in the same way:
- You have to Enable the readers you want to use and then Start the Api.
- When API is started you can Use OpenDocument() method to read a file.
This method recognizes file format and calls the corresponding reader to give you an assembly tree.
- From assembly tree, you choose the component you want to read and call ReadComponent method to get Construction tree.
- From this second tree, you call Get.. method on node following his type to make the reader access to full data information.
- You have to close opened component with EndComponent() and opened document with EndDocument() method to free data used by the reader.
- In the end, you need to stop the API.
All classes except Dtk_API and Dtk_readers are handled via Smart Pointers.
You have to use the Create method to handle them. They are deleted automatically when they are not used any more.
@ ReadPathSearch
Definition: dtk_api.hpp:54
Dtk_ErrorStatus EndDocument(Dtk_MainDocPtr &inoutDocument)
Close a Document.
Dtk_ErrorStatus FindAttribute(const Dtk_string &name, Dtk_Val &val) const
uint32_t Dtk_ID
Definition: define.h:689
int write_mesh_solid(Dtk_mesh *tm)
This is a high level face class.
Definition: util_mesh_dtk.hpp:870
Dtk_string GetName() const
Retrieves the entity name.
This is the Revolution Surface Class. U parametrisation : revolved curve parametrisation V parametris...
Definition: util_geom_dtk.hpp:1105
DTK_Text_subtype & TextSubType()
Retrieves the text subtype - get/set -.
Dtk_bool get_tesselationSuppressDuplicateFace()
: return current status of suppress duplicate face option default value is enable to deactivate this ...
Dtk_Size_t GetNumTexts() const
Retrieves the texts number.
void tess_set_optimize_mesh(int ival)
: Activate or not the optimization of the vertex map
Dtk_ErrorStatus AddSearchPath(const Dtk_SearchFileEnum::RecursivityEnum &inRecursivityEnum, const Dtk_string &inPath)
Add search path to find missing files.
@ RootFolderFirstRecursivity
Definition: dtk_api.hpp:48
Dtk_bool IsNotNULL() const
Definition: util_ptr_dtk.hpp:119
void tess_set_Ratio(double tol)
: define a ratio
Dtk_ErrorStatus tess_ShellToMesh(const Dtk_ShellPtr &inShell, Dtk_MeshPtr &outMesh, Dtk_Int32 *outIsSolid)
: Make Tesselation from a Dtk_shell and create a Dtk_MeshPtr if available
Dtk_string GetPersistentName() const
#define DTK_TRUE
Definition: define.h:727
This is the general symbol class. It's basically composed of Dtk_CompositeText and geometrical elemen...
Definition: util_draw_dtk.hpp:6505
static Dtk_API * StartAPI(const Dtk_string &inTemporyDirectory, Dtk_ErrorStatus &outErrorCode, const Dtk_string &inCustomerID=Dtk_string())
Start DATAKIT API.
Dtk_bool IsTolBloc() const
Tell if the associated Dtk_text is part of Tolerance Block group - into Dtk_Dimension -.
DTK_FDT_MODIFIER
This is the several tolerances modifiers list.
Definition: util_draw_dtk.hpp:63
uint32_t Dtk_UInt32
Definition: define.h:688
This is a high level string class.
Definition: dtk_string.hpp:58
This is the Feature Indicator. It is part of the Dtk_FCFFeatureIndicator. .
Definition: util_draw_dtk.hpp:5898
size_t Dtk_Size_t
Definition: define.h:712
const Dtk_InfoPtr & GetInfo() const
Retrieves the text infos - read only -.
This is the base text class. It's part of Dtk_CompositeText. It's used into a lot of 2D Entities It c...
Definition: util_draw_dtk.hpp:1126
Definition: dtk_status.hpp:16
static Dtk_BodyPtr Create()
Create a body.
Dtk_ErrorStatus EndComponent(Dtk_ComponentPtr &inComponent)
EndComponent.
Dtk_ErrorStatus OpenDocument(const Dtk_string &inInputFile, Dtk_MainDocPtr &outDocument)
Open a Document (call EndDocument to close it)
#define DTK_FALSE
Definition: define.h:728
@ DTK_TYPE_SYMBOL
Definition: define.h:409
char Dtk_bool
Definition: define.h:725
FILE * OpenFile(const Dtk_string &inRights) const
File Utility : Open a file with the given rights.
static Dtk_SymbolPtr Create()
Base constructor.
void ActivateSearchFileEngine()
int tess_InitTesselation(Dtk_string inWorkingDirectory, double inTolerance)
Init the tesselation library.
double Dtk_Double64
Definition: define.h:699
void get_tesselation_activateSplitMode(int &outmode, double &outratio)
: read value of splitting of surface
@ DTK_ISERROR
Definition: dtk_status.hpp:9
@ DTK_TYPE_NURBS_SURFACE
Definition: define.h:495
Definition: dtk_val.hpp:67
int GetInt(Dtk_status &st=Dtk_status::GetDefaultStatus()) const
void tess_getBoundariesFromMeshFace(const Dtk_MeshPtr &mesh, const Dtk_mesh_face *inFace, Dtk_tab< Dtk_tab< Dtk_PolylinePtr > > &outBoundaries)
: reorder the polylines of a Dtk_mesh_face into correct loop
void ManageSearchFile(Dtk_SearchFileEnum::Status inStatus)
static Dtk_API * GetAPI()
Get DATAKIT API.
int tess_ComputeNormalesFromSurface()
: Check value of option compute normales of vertex from real surface
This is the Node Class The Dtk_Node object is used to retrieve informations in a Dtk_ComponentPtr obj...
Definition: dtk_maindoc.hpp:230
int32_t Dtk_Int32
Definition: define.h:687
Dtk_ErrorStatus TesselationIsStarted()
: Check if tesselation is initialized
@ DTK_TYPE_FACE
Definition: define.h:141
int get_id()
Return the face Id.
Dtk_bool IsTolUpperTol() const
Tell if the associated Dtk_text is part of Tolerance Upper Value group - into Dtk_Dimension -.
This is the Dtk_Preview class.
Definition: util_ent_dtk.hpp:688
static Dtk_LumpPtr Create(const Dtk_BodyPtr &inParentBody)
Create a lump in a body.
@ AdditionalPathSearch
Definition: dtk_api.hpp:55
static Dtk_SmartPtr< T > DtkDynamicCast(const Dtk_SmartPtr< T2 > &p)
Definition: util_ptr_dtk.hpp:101
int end_stl_fic(int *ient)
static Dtk_HyperbolaPtr Create(const Dtk_Hyperbola &inToCopy)
Dtk_ErrorStatus
Definition: error_dtk.hpp:6
Dtk_ErrorStatus SetSearchPositionMode(Dtk_Int32 inPosition, Dtk_SearchFileEnum::PriorityModeEnum inSearchEnum)
Set Search Position.
Definition: util_ptr_dtk.hpp:37
void set_tesselationSuppressDuplicateFace(Dtk_bool inBval)
: Enable or disable the suppression of duplicate face before tessellation
@ LocalSearch
Definition: dtk_api.hpp:53
void reinit_SplitMode()
: disable splitting of surface
const char * c_str() const
Retrieve the ASCII conversion string.
void SetInternalReadPathSearchFlag(Dtk_bool inActivationFlag)
Allow Internal Read Path Search for files of assembly.
This is the Dtk_GraphicalData Class. The Dtk_GraphicalDataPtr object is used to store preview data It...
Definition: dtk_graphical.hpp:27
Dtk_bool tess_disableTolAngular()
: return state of Angular tolerance method
Dtk_string GetString(Dtk_status &st=Dtk_status::GetDefaultStatus()) const
Dtk_FCFFeatureIndicatorTypeEnum
Definition: util_draw_dtk.hpp:5901
This is a mathematical point class.
Definition: dtk_pnt.hpp:22
type_detk
Definition: define.h:32
void set_TesselateSurfaceMethod(int ival)
: select computation method for surface tesselation
This is the DTK_Text_subtype class. It's used to provide semantic data about Dtk_Text type....
Definition: util_draw_dtk.hpp:1012
static Dtk_ParabolaPtr Create(const Dtk_Parabola &inToCopy)
This is the composite text class. It's basically a Dtk_Text Container. This class represents a group ...
Definition: util_draw_dtk.hpp:1557
Dtk_bool CheckUseEdgeTolerance()
: return current status of if we use the tolerance of edge and face read from the part available valu...
@ DTK_TYPE_EDGE
Definition: define.h:128
double GetDouble(Dtk_status &st=Dtk_status::GetDefaultStatus()) const
int tess_ComputeBoundariesFromMesh()
: Check value of option memorize noundaries of mesh
void ActivateKeepKernelData()
Keep Kernel Data option (see "How to use KeepKernelData option")
@ Enable
Definition: dtk_api.hpp:63
Dtk_ErrorStatus ClearSearchPriority()
Clear Search Priority.
void SetAdditionnalPathSearchFlag(Dtk_bool inActivationFlag)
Allow Additionnal Path Search for files of assembly.
Dtk_Size_t size() const
Returns the size of the array.
Definition: util_stl_dtk.hpp:502
@ DTK_NOERROR
Definition: dtk_status.hpp:10
void tess_set_angular(double angle)
: Set angle for cord heigh ratio method
static void StopAPI(Dtk_API *&inAPI, Dtk_bool inWriteTimeInLog=1)
Stop DATAKIT API.
const Dtk_InfoPtr & GetInfo() const
Retrieves the infos.
void tess_EndTesselation()
Free the data used by tesselation library.
Dtk_ErrorStatus ReadComponentGraphic(const Dtk_ComponentPtr &inComponent, Dtk_GraphicalDataPtr &outGraphicalData)
Read graphical data from Component (Call EndComponent to free data allocated)
int init_stl_write(Dtk_string sfic)
TypeEnum
Definition: util_draw_dtk.hpp:6197
void tess_set_MaxSize(double tol)
: sets maximum size of triangles
Dtk_bool tess_disableTolLinear()
: return state of linear tolerance method
const Dtk_FCFFeatureIndicatorTypeEnum & GetIndicatorType() const
Retrieves the IndicatorType semantic Type - Read Only -.
Definition: util_draw_dtk.hpp:5976
T & at(Dtk_Size_t k)
Definition: util_stl_dtk.hpp:396
@ dtkNoError
Definition: error_dtk.hpp:140
Dtk_ErrorStatus ReadComponent(const Dtk_ComponentPtr &inComponent, Dtk_NodePtr &outRootNode)
Read Component from Assembly Tree (Call EndComponent to free data allocated)
void set_tesselation_activateSplitMode(const int inmode, const double inratio)
: memorize option for splitting of surfaces before tessellation
Dtk_ErrorStatus CreateGeometries(Dtk_tab< Dtk_CurvePtr > &outGeoms) const
Process IndicatorType Related geometries.
This is a mathematical direction class.
Definition: dtk_dir.hpp:15
void tess_set_linear(double tol)
: Set tolerance for linear tolerance method
Definition: dtk_api.hpp:75
static Dtk_VolumePtr Create(const Dtk_BodyPtr &inParentBody)
Create a volume in a body.
void SetLocalPathSearchFlag(Dtk_bool inActivationFlag)
Allow Local Path Search for files of assembly.