EgtInterface 1.5j4 :
- ora si imposta un context corrente anche per le API come per LUA - il context corrente di LUA coincide con quello delle API.
This commit is contained in:
+22
-22
@@ -34,7 +34,7 @@ LuaCreateGroup( lua_State* L)
|
||||
LuaGetParam( L, 2, frFrame) ;
|
||||
LuaClearStack( L) ;
|
||||
// creo il gruppo
|
||||
int nId = EgtCreateGroup( LuaGetGseContext(), nParentId, frFrame.Orig().v,
|
||||
int nId = EgtCreateGroup( nParentId, frFrame.Orig().v,
|
||||
frFrame.VersX().v, frFrame.VersY().v, frFrame.VersZ().v) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
@@ -55,7 +55,7 @@ LuaCreateGeoPoint( lua_State* L)
|
||||
LuaCheckParam( L, 2, ptP)
|
||||
LuaClearStack( L) ;
|
||||
// creo il segmento di retta
|
||||
int nId = EgtCreateGeoPoint( LuaGetGseContext(), nParentId, ptP.v) ;
|
||||
int nId = EgtCreateGeoPoint( nParentId, ptP.v) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -80,7 +80,7 @@ LuaCreateGeoVector( lua_State* L)
|
||||
LuaClearStack( L) ;
|
||||
// creo il segmento di retta
|
||||
vtV *= dScale ;
|
||||
int nId = EgtCreateGeoVector( LuaGetGseContext(), nParentId, vtV.v, ptB.v) ;
|
||||
int nId = EgtCreateGeoVector( nParentId, vtV.v, ptB.v) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -100,7 +100,7 @@ LuaCreateGeoFrame( lua_State* L)
|
||||
LuaCheckParam( L, 2, frFrame) ;
|
||||
LuaClearStack( L) ;
|
||||
// creo il gruppo
|
||||
int nId = EgtCreateGeoFrame( LuaGetGseContext(), nParentId, frFrame.Orig().v,
|
||||
int nId = EgtCreateGeoFrame( nParentId, frFrame.Orig().v,
|
||||
frFrame.VersX().v, frFrame.VersY().v, frFrame.VersZ().v) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
@@ -123,7 +123,7 @@ LuaCreateCurveLine( lua_State* L)
|
||||
LuaCheckParam( L, 3, ptFin)
|
||||
LuaClearStack( L) ;
|
||||
// creo il segmento di retta
|
||||
int nId = EgtCreateCurveLine( LuaGetGseContext(), nParentId, ptIni.v, ptFin.v) ;
|
||||
int nId = EgtCreateCurveLine( nParentId, ptIni.v, ptFin.v) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -147,7 +147,7 @@ LuaCreateCurveLineMinPointCurve( lua_State* L)
|
||||
LuaGetParam( L, 4, dNearPar) ;
|
||||
LuaClearStack( L) ;
|
||||
// creo il segmento di retta
|
||||
int nId = EgtCreateCurveLineMinPointCurve( LuaGetGseContext(), nParentId, ptIni.v, nCrvId, dNearPar) ;
|
||||
int nId = EgtCreateCurveLineMinPointCurve( nParentId, ptIni.v, nCrvId, dNearPar) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -171,7 +171,7 @@ LuaCreateCurveCircle( lua_State* L)
|
||||
LuaCheckParam( L, 4, dRad)
|
||||
LuaClearStack( L) ;
|
||||
// creo l'arco
|
||||
int nId = EgtCreateCurveCircle( LuaGetGseContext(), nParentId, ptCen.v, vtN.v, dRad) ;
|
||||
int nId = EgtCreateCurveCircle( nParentId, ptCen.v, vtN.v, dRad) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -193,7 +193,7 @@ LuaCreateCurveCircleXY( lua_State* L)
|
||||
LuaCheckParam( L, 3, dRad)
|
||||
LuaClearStack( L) ;
|
||||
// creo l'arco
|
||||
int nId = EgtCreateCurveCircleXY( LuaGetGseContext(), nParentId, ptCen.v, dRad) ;
|
||||
int nId = EgtCreateCurveCircleXY( nParentId, ptCen.v, dRad) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -217,7 +217,7 @@ LuaCreateCurveCircle3P( lua_State* L)
|
||||
LuaCheckParam( L, 4, ptP3)
|
||||
LuaClearStack( L) ;
|
||||
// creo l'arco
|
||||
int nId = EgtCreateCurveCircle3P( LuaGetGseContext(), nParentId, ptP1.v, ptP2.v, ptP3.v) ;
|
||||
int nId = EgtCreateCurveCircle3P( nParentId, ptP1.v, ptP2.v, ptP3.v) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -247,7 +247,7 @@ LuaCreateCurveArc( lua_State* L)
|
||||
LuaCheckParam( L, 7, dDeltaN)
|
||||
LuaClearStack( L) ;
|
||||
// creo l'arco
|
||||
int nId = EgtCreateCurveArc( LuaGetGseContext(), nParentId, ptCen.v, vtN.v, dRad, vtS.v, dAngCenDeg, dDeltaN) ;
|
||||
int nId = EgtCreateCurveArc( nParentId, ptCen.v, vtN.v, dRad, vtS.v, dAngCenDeg, dDeltaN) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -275,7 +275,7 @@ LuaCreateCurveArcXY( lua_State* L)
|
||||
LuaCheckParam( L, 6, dDeltaZ)
|
||||
LuaClearStack( L) ;
|
||||
// creo l'arco
|
||||
int nId = EgtCreateCurveArcXY( LuaGetGseContext(), nParentId, ptCen.v, dRad, dAngStartDeg, dAngCenDeg, dDeltaZ) ;
|
||||
int nId = EgtCreateCurveArcXY( nParentId, ptCen.v, dRad, dAngStartDeg, dAngCenDeg, dDeltaZ) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -299,7 +299,7 @@ LuaCreateCurveArc3P( lua_State* L)
|
||||
LuaCheckParam( L, 4, ptP3)
|
||||
LuaClearStack( L) ;
|
||||
// creo l'arco
|
||||
int nId = EgtCreateCurveArc3P( LuaGetGseContext(), nParentId, ptP1.v, ptP2.v, ptP3.v) ;
|
||||
int nId = EgtCreateCurveArc3P( nParentId, ptP1.v, ptP2.v, ptP3.v) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -324,7 +324,7 @@ LuaCreateCurveBezier( lua_State* L)
|
||||
if ( vPnt.size() != nDegree + 1)
|
||||
return luaL_error( L, "Wrong Control Points Number") ;
|
||||
// creo la curva
|
||||
int nId = EgtCreateCurveBezier( LuaGetGseContext(), nParentId, nDegree, vPnt) ;
|
||||
int nId = EgtCreateCurveBezier( nParentId, nDegree, vPnt) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -349,7 +349,7 @@ LuaCreateCurveBezierRational( lua_State* L)
|
||||
if ( vPntW.size() != nDegree + 1)
|
||||
return luaL_error( L, "Wrong Control Points Number") ;
|
||||
// creo la curva
|
||||
int nId = EgtCreateCurveBezierRational( LuaGetGseContext(), nParentId, nDegree, vPntW) ;
|
||||
int nId = EgtCreateCurveBezierRational( nParentId, nDegree, vPntW) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -371,7 +371,7 @@ LuaCreateCurveBezierFromArc( lua_State* L)
|
||||
LuaGetParam( L, 3, bErase) ;
|
||||
LuaClearStack( L) ;
|
||||
// creo la curva
|
||||
int nId = EgtCreateCurveBezierFromArc( LuaGetGseContext(), nParentId, nArcId, bErase) ;
|
||||
int nId = EgtCreateCurveBezierFromArc( nParentId, nArcId, bErase) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -393,7 +393,7 @@ LuaCreateCurveCompo( lua_State* L)
|
||||
LuaGetParam( L, 3, bErase) ;
|
||||
LuaClearStack( L) ;
|
||||
// creo la curva composita
|
||||
int nId = EgtCreateCurveCompo( LuaGetGseContext(), nParentId, vIds, ( bErase ? TRUE : FALSE)) ;
|
||||
int nId = EgtCreateCurveCompo( nParentId, vIds, ( bErase ? TRUE : FALSE)) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -416,7 +416,7 @@ LuaCreateCurveCompoFromPoints( lua_State* L)
|
||||
for ( size_t i = 0 ; i < vPnt.size() ; ++ i)
|
||||
PL.AddUPoint( 0, vPnt[i]) ;
|
||||
// creo la curva composita
|
||||
int nId = EgtCreateCurveCompoFromPoints( LuaGetGseContext(), nParentId, PL) ;
|
||||
int nId = EgtCreateCurveCompoFromPoints( nParentId, PL) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -439,7 +439,7 @@ LuaCreateCurveCompoFromPointBulges( lua_State* L)
|
||||
for ( size_t i = 0 ; i < vPntB.size() ; ++ i)
|
||||
PA.AddUPoint( 0, vPntB[i].first, vPntB[i].second) ;
|
||||
// creo la curva composita
|
||||
int nId = EgtCreateCurveCompoFromPointBulges( LuaGetGseContext(), nParentId, PA) ;
|
||||
int nId = EgtCreateCurveCompoFromPointBulges( nParentId, PA) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -463,7 +463,7 @@ LuaCreateCurveCompoFromPolygonSide( lua_State* L)
|
||||
LuaCheckParam( L, 4, ptFin)
|
||||
LuaClearStack( L) ;
|
||||
// creo il poligono
|
||||
int nId = EgtCreateCurveCompoFromPolygonSide( LuaGetGseContext(), nParentId, nNumSides, ptIni.v, ptFin.v) ;
|
||||
int nId = EgtCreateCurveCompoFromPolygonSide( nParentId, nNumSides, ptIni.v, ptFin.v) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -485,7 +485,7 @@ LuaCreateSurfTriMeshByContour( lua_State* L)
|
||||
LuaGetParam( L, 3, dLinTol) ;
|
||||
LuaClearStack( L) ;
|
||||
// creo STM riempiendo un contorno piano
|
||||
int nId = EgtCreateSurfTriMeshByContour( LuaGetGseContext(), nParentId, nCrvId, dLinTol) ;
|
||||
int nId = EgtCreateSurfTriMeshByContour( nParentId, nCrvId, dLinTol) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -511,7 +511,7 @@ LuaCreateText( lua_State* L)
|
||||
LuaCheckParam( L, 5, dH) ;
|
||||
LuaClearStack( L) ;
|
||||
// creo il testo
|
||||
int nId = EgtCreateText( LuaGetGseContext(), nParentId, sText, ptP, dAngRotDeg, dH) ;
|
||||
int nId = EgtCreateText( nParentId, sText, ptP, dAngRotDeg, dH) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetReturn( L, nId) ;
|
||||
@@ -571,7 +571,7 @@ LuaCreateTextEx( lua_State* L)
|
||||
nInsPos = ETXT_IPBR ;
|
||||
LuaClearStack( L) ;
|
||||
// creo il testo in modo esteso
|
||||
int nId = EgtCreateTextEx( LuaGetGseContext(), nParentId, sText, ptP, dAngRotDeg,
|
||||
int nId = EgtCreateTextEx( nParentId, sText, ptP, dAngRotDeg,
|
||||
sFont, nW, bItalic, dH, dRat, dAddAdv, nInsPos) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
|
||||
Reference in New Issue
Block a user