EgtExecutor :

- in Trimming piccole migliorie/correzioni.
This commit is contained in:
Riccardo Elitropi
2026-01-26 18:04:19 +01:00
parent e68153fb70
commit 7cf368e518
2 changed files with 31 additions and 16 deletions
+18 -10
View File
@@ -125,20 +125,24 @@ LuaTrimmingGetAdjSurfs( lua_State* L)
static int
LuaTrimmingGetBorders( lua_State* L)
{
// 4 parametri : nParentId, vIds, dLinTol, dAngTol
// 6 parametri : nParentId, vIds, dSurfLinTol, dSurfAngTol, dLinTol, dAngTol
int nParentId ;
LuaCheckParam( L, 1, nParentId)
SELVECTOR vIds ;
LuaCheckParam( L, 2, vIds)
double dSurfLinTol ;
LuaCheckParam( L, 3, dSurfLinTol) ;
double dSurfAngTol ;
LuaCheckParam( L, 4, dSurfAngTol) ;
double dLinTol ;
LuaCheckParam( L, 3, dLinTol)
LuaCheckParam( L, 5, dLinTol)
double dAngTol ;
LuaCheckParam( L, 4, dAngTol)
LuaCheckParam( L, 6, dAngTol)
LuaClearStack( L) ;
// Creo le curve di Edge grezze
int nFirstId = GDB_ID_NULL ;
int nCount = 0 ;
bool bOk = ExeTrimmingGetBorders( nParentId, vIds, dLinTol, dAngTol, nFirstId, nCount) ;
bool bOk = ExeTrimmingGetBorders( nParentId, vIds, dSurfLinTol, dSurfAngTol, dLinTol, dAngTol, nFirstId, nCount) ;
LuaSetParam( L, bOk) ;
LuaSetParam( L, nFirstId) ;
LuaSetParam( L, nCount) ;
@@ -149,24 +153,28 @@ LuaTrimmingGetBorders( lua_State* L)
static int
LuaTrimmingGetBordersByNormals( lua_State* L)
{
// 5 o 6 parametri : nParentId, vIds, dLinTol, dAngTol, dThickness [, ptNear]
// 7 o 8 parametri : nParentId, vIds, dLinTol, dAngTol, dThickness [, ptNear]
int nParentId ;
LuaCheckParam( L, 1, nParentId)
SELVECTOR vIds ;
LuaCheckParam( L, 2, vIds)
double dSurfLinTol ;
LuaCheckParam( L, 3, dSurfLinTol) ;
double dSurfAngTol ;
LuaCheckParam( L, 4, dSurfAngTol) ;
double dLinTol ;
LuaCheckParam( L, 3, dLinTol)
LuaCheckParam( L, 5, dLinTol)
double dAngTol ;
LuaCheckParam( L, 4, dAngTol)
LuaCheckParam( L, 6, dAngTol)
double dThickness ;
LuaCheckParam( L, 5, dThickness)
LuaCheckParam( L, 7, dThickness)
Point3d ptNear = P_INVALID ;
LuaGetParam( L, 6, ptNear) ;
LuaGetParam( L, 8, ptNear) ;
LuaClearStack( L) ;
// Creo le curve di Edge grezze
int nFirstId = GDB_ID_NULL ;
int nCount = 0 ;
bool bOk = ExeTrimmingGetBordersByNormals( nParentId, vIds, dLinTol, dAngTol, dThickness, ptNear, nFirstId, nCount) ;
bool bOk = ExeTrimmingGetBordersByNormals( nParentId, vIds, dSurfLinTol, dSurfAngTol, dLinTol, dAngTol, dThickness, ptNear, nFirstId, nCount) ;
LuaSetParam( L, bOk) ;
LuaSetParam( L, nFirstId) ;
LuaSetParam( L, nCount) ;