diff --git a/API_GeoDist.cpp b/API_GeoDist.cpp
new file mode 100644
index 0000000..581011d
--- /dev/null
+++ b/API_GeoDist.cpp
@@ -0,0 +1,55 @@
+//----------------------------------------------------------------------------
+// EgalTech 2018-2018
+//----------------------------------------------------------------------------
+// File : API_GeoDist.cpp Data : 15.12.18 Versione : 1.9l2
+// Contenuto : Funzioni di distanza tra oggetti del DB geometrico per API.
+//
+//
+//
+// Modifiche : 15.12.18 DS Creazione modulo.
+//
+//
+//----------------------------------------------------------------------------
+
+//--------------------------- Include ----------------------------------------
+#include "stdafx.h"
+#include "API.h"
+#include "/EgtDev/Include/EInAPI.h"
+#include "/EgtDev/Include/EXeExecutor.h"
+
+using namespace std ;
+
+//----------------------------------------------------------------------------
+BOOL
+__stdcall EgtPointCurveDist( const double ptP[3], int nId, int nRefType, double* pdDist, double* pdU)
+{
+ Point3d ptTemp ;
+ return ( ExePointCurveDist( ptP, nId, nRefType, pdDist, ptTemp, pdU) ? TRUE : FALSE) ;
+}
+
+//----------------------------------------------------------------------------
+BOOL
+__stdcall EgtPointCurveDistSide( const double ptP[3], int nId, const double vtN[3], int nRefType,
+ double* pdDist, double ptMin[3], int* pnSide)
+{
+ if ( pdDist == nullptr || ptMin == nullptr || pnSide == nullptr)
+ return FALSE ;
+ Point3d ptTmp ;
+ if ( ! ExePointCurveDistSide( ptP, nId, vtN, nRefType, pdDist, ptTmp, pnSide))
+ return FALSE ;
+ VEC_FROM_3D( ptMin, ptTmp)
+ return TRUE ;
+}
+
+//----------------------------------------------------------------------------
+BOOL
+__stdcall EgtPointSurfTmDist( const double ptP[3], int nId, int nRefType, double* pdDist, double ptMin[3], int* pnTria)
+{
+ if ( pdDist == nullptr || ptMin == nullptr || pnTria == nullptr)
+ return FALSE ;
+ Point3d ptTmp ;
+ if ( ! ExePointSurfTmDist( ptP, nId, nRefType, pdDist, ptTmp, pnTria))
+ return FALSE ;
+ VEC_FROM_3D( ptMin, ptTmp)
+ return TRUE ;
+}
diff --git a/API_GeoInters.cpp b/API_GeoInters.cpp
new file mode 100644
index 0000000..08ef8f5
--- /dev/null
+++ b/API_GeoInters.cpp
@@ -0,0 +1,55 @@
+//----------------------------------------------------------------------------
+// EgalTech 2018-2018
+//----------------------------------------------------------------------------
+// File : API_GeoInters.cpp Data : 15.12.18 Versione : 1.9l2
+// Contenuto : Funzioni intersezione tra oggetti del DB geometrico per API.
+//
+//
+//
+// Modifiche : 15.12.18 DS Creazione modulo.
+//
+//
+//----------------------------------------------------------------------------
+
+//--------------------------- Include ----------------------------------------
+#include "stdafx.h"
+#include "API.h"
+#include "/EgtDev/Include/EInAPI.h"
+#include "/EgtDev/Include/EXeExecutor.h"
+
+using namespace std ;
+
+//----------------------------------------------------------------------------
+BOOL
+__stdcall EgtLineSurfTmInters( const double ptP[3], const double vtDir[3], int nId, int nRefType, int*& vFlagInters, double*& vParInters, int* pnCount)
+{
+ // verifica parametri
+ if ( ptP == nullptr || vtDir == nullptr || &vFlagInters == nullptr || &vParInters == nullptr || pnCount == nullptr)
+ return FALSE ;
+ // eseguo intersezione
+ INTDBLVECTOR vInters ;
+ if ( ! ExeLineSurfTmInters( ptP, vtDir, nId, nRefType, vInters))
+ return FALSE ;
+ // assegno risultati
+ int nDim = int( vInters.size()) ;
+ if ( nDim == 0) {
+ vFlagInters = nullptr ;
+ vParInters = nullptr ;
+ }
+ else {
+ vFlagInters = (int*) malloc( nDim * sizeof( int)) ;
+ if ( vFlagInters == nullptr)
+ return FALSE ;
+ vParInters = (double*) malloc( nDim * sizeof( double)) ;
+ if ( vParInters == nullptr) {
+ free( vFlagInters) ;
+ return FALSE ;
+ }
+ for ( int i = 0 ; i < nDim ; ++ i) {
+ vFlagInters[i] = vInters[i].first ;
+ vParInters[i] = vInters[i].second ;
+ }
+ }
+ *pnCount = nDim ;
+ return TRUE ;
+}
diff --git a/API_GeoSnap.cpp b/API_GeoSnap.cpp
index 3c7ce21..be8e105 100644
--- a/API_GeoSnap.cpp
+++ b/API_GeoSnap.cpp
@@ -335,27 +335,6 @@ __stdcall EgtClosedCurveClassify( int nId1, int nId2)
return ExeClosedCurveClassify( nId1, nId2) ;
}
-//----------------------------------------------------------------------------
-BOOL
-__stdcall EgtGetMinDistPointCurve( const double ptP[3], int nId, double* pdDist, double* pdU)
-{
- return ( ExeGetMinDistPointCurve( ptP, nId, pdDist, pdU) ? TRUE : FALSE) ;
-}
-
-//----------------------------------------------------------------------------
-BOOL
-__stdcall EgtGetMinDistPntSidePointCurve( const double ptP[3], int nId, const double vtN[3],
- double* pdDist, double ptMin[3], int* pnSide)
-{
- if ( pdDist == nullptr || ptMin == nullptr || pnSide == nullptr)
- return FALSE ;
- Point3d ptTmp ;
- if ( ! ExeGetMinDistPntSidePointCurve( ptP, nId, vtN, pdDist, ptTmp, pnSide))
- return FALSE ;
- VEC_FROM_3D( ptMin, ptTmp)
- return TRUE ;
-}
-
//----------------------------------------------------------------------------
BOOL
__stdcall EgtArcRadius( int nId, double* pdRad)
@@ -576,41 +555,6 @@ __stdcall EgtSurfTmFacetsContact( int nId, int nF1, int nF2, int nRefId, bool* p
return TRUE ;
}
-//----------------------------------------------------------------------------
-BOOL
-__stdcall EgtSurfTmLineInters( int nId, const double ptP[3], const double vtDir[3], int nRefType, int*& vFlagInters, double*& vParInters, int* pnCount)
-{
- // verifica parametri
- if ( ptP == nullptr || vtDir == nullptr || &vFlagInters == nullptr || &vParInters == nullptr || pnCount == nullptr)
- return FALSE ;
- // eseguo intersezione
- INTDBLVECTOR vInters ;
- if ( ! ExeSurfTmLineInters( nId, ptP, vtDir, nRefType, vInters))
- return FALSE ;
- // assegno risultati
- int nDim = int( vInters.size()) ;
- if ( nDim == 0) {
- vFlagInters = nullptr ;
- vParInters = nullptr ;
- }
- else {
- vFlagInters = (int*) malloc( nDim * sizeof( int)) ;
- if ( vFlagInters == nullptr)
- return FALSE ;
- vParInters = (double*) malloc( nDim * sizeof( double)) ;
- if ( vParInters == nullptr) {
- free( vFlagInters) ;
- return FALSE ;
- }
- for ( int i = 0 ; i < nDim ; ++ i) {
- vFlagInters[i] = vInters[i].first ;
- vParInters[i] = vInters[i].second ;
- }
- }
- *pnCount = nDim ;
- return TRUE ;
-}
-
//----------------------------------------------------------------------------
BOOL
__stdcall EgtTextNormVersor( int nId, int nRefId, double vtNorm[3])
diff --git a/EgtInterface.rc b/EgtInterface.rc
index 6caac59..baa0b38 100644
Binary files a/EgtInterface.rc and b/EgtInterface.rc differ
diff --git a/EgtInterface.vcxproj b/EgtInterface.vcxproj
index a710b71..e084fe3 100644
--- a/EgtInterface.vcxproj
+++ b/EgtInterface.vcxproj
@@ -227,6 +227,8 @@ copy $(TargetPath) \EgtProg\Dll64
+
+
diff --git a/EgtInterface.vcxproj.filters b/EgtInterface.vcxproj.filters
index 8a0061d..be6ce9a 100644
--- a/EgtInterface.vcxproj.filters
+++ b/EgtInterface.vcxproj.filters
@@ -125,6 +125,12 @@
File di origine\API
+
+ File di origine\API
+
+
+ File di origine\API
+