TestEIn 1.6l5 :

- aggiornamenti.
This commit is contained in:
Dario Sassi
2016-01-05 11:38:44 +00:00
parent 1f80ae7423
commit 715ec1546c
5 changed files with 146 additions and 45 deletions
+1 -1
View File
@@ -319,7 +319,7 @@ Public Class Component
' Ne recupero l'Id
Dim nId2 As Integer = EgtGetLastPart()
' Lo posiziono in ordine
EgtPackPart(nId2, 0, 0, PACK_MAX_X, PACK_MAX_Y, PACK_OFFS, True)
EgtPackBox(nId2, 0, 0, PACK_MAX_X, PACK_MAX_Y, PACK_OFFS, True)
Next
' disabilito registrazione
EgtDisableCommandLogger()
+124 -39
View File
@@ -5013,47 +5013,47 @@ Public Function EgtCreateFlatParts(ByVal nType As Integer) As Boolean
End If
End Function
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtPackPart")>
Private Function EgtPackPart_32(ByVal nId As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtPackBox")>
Private Function EgtPackBox_32(ByVal nId As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
End Function
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtPackPart")>
Private Function EgtPackPart_64(ByVal nId As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtPackBox")>
Private Function EgtPackBox_64(ByVal nId As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
End Function
Public Function EgtPackPart(ByVal nId As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
Public Function EgtPackBox(ByVal nId As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
If IntPtr.Size = 4 Then
Return EgtPackPart_32(nId, dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Return EgtPackBox_32(nId, dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Else
Return EgtPackPart_64(nId, dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Return EgtPackBox_64(nId, dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
End If
End Function
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtPackCluster")>
Private Function EgtPackCluster_32(ByVal vId As Integer(), ByVal nCount As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtPackBoxCluster")>
Private Function EgtPackBoxCluster_32(ByVal vId As Integer(), ByVal nCount As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
End Function
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtPackCluster")>
Private Function EgtPackCluster_64(ByVal vId As Integer(), ByVal nCount As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtPackBoxCluster")>
Private Function EgtPackBoxCluster_64(ByVal vId As Integer(), ByVal nCount As Integer, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
End Function
Public Function EgtPackCluster(ByVal vId As Integer(), ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
Public Function EgtPackBoxCluster(ByVal vId As Integer(), ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
If IntPtr.Size = 4 Then
Return EgtPackCluster_32(vId, vId.Count(), dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Return EgtPackBoxCluster_32(vId, vId.Count(), dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Else
Return EgtPackCluster_64(vId, vId.Count(), dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Return EgtPackBoxCluster_64(vId, vId.Count(), dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
End If
End Function
Public Function EgtPackSelectedCluster(ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
Public Function EgtPackSelectedBoxCluster(ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double, ByVal bBottomUp As Boolean) As Boolean
Dim vId(1) As Integer
vId(0) = GDB_ID.SEL
If IntPtr.Size = 4 Then
Return EgtPackCluster_32(vId, 1, dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Return EgtPackBoxCluster_32(vId, 1, dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Else
Return EgtPackCluster_64(vId, 1, dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
Return EgtPackBoxCluster_64(vId, 1, dXmin, dYmin, dXmax, dYmax, dOffs, bBottomUp)
End If
End Function
@@ -5083,33 +5083,117 @@ Public Function EgtGetSelectedClusterBBoxGlob(ByRef PtMin As Point3d, ByRef PtMa
End If
End Function
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtMoveCluster")>
Private Function EgtMoveCluster_32(ByVal vId As Integer(), ByVal nCount As Integer, ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double) As Boolean
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtMoveBoxCluster")>
Private Function EgtMoveBoxCluster_32(ByVal vId As Integer(), ByVal nCount As Integer, ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double) As Boolean
End Function
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtMoveCluster")>
Private Function EgtMoveCluster_64(ByVal vId As Integer(), ByVal nCount As Integer, ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double) As Boolean
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtMoveBoxCluster")>
Private Function EgtMoveBoxCluster_64(ByVal vId As Integer(), ByVal nCount As Integer, ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double) As Boolean
End Function
Public Function EgtMoveCluster(ByVal vId As Integer(), ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double) As Boolean
Public Function EgtMoveBoxCluster(ByVal vId As Integer(), ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double) As Boolean
If IntPtr.Size = 4 Then
Return EgtMoveCluster_32(vId, vId.Count(), vtMove, dXmin, dYmin, dXmax, dYmax, dOffs)
Return EgtMoveBoxCluster_32(vId, vId.Count(), vtMove, dXmin, dYmin, dXmax, dYmax, dOffs)
Else
Return EgtMoveCluster_64(vId, vId.Count(), vtMove, dXmin, dYmin, dXmax, dYmax, dOffs)
Return EgtMoveBoxCluster_64(vId, vId.Count(), vtMove, dXmin, dYmin, dXmax, dYmax, dOffs)
End If
End Function
Public Function EgtMoveSelectedCluster(ByRef vtMove As Vector3d, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double) As Boolean
Public Function EgtMoveSelectedBoxCluster(ByRef vtMove As Vector3d, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double, ByVal dOffs As Double) As Boolean
Dim vId(1) As Integer
vId(0) = GDB_ID.SEL
If IntPtr.Size = 4 Then
Return EgtMoveCluster_32(vId, 1, vtMove, dXmin, dYmin, dXmax, dYmax, dOffs)
Return EgtMoveBoxCluster_32(vId, 1, vtMove, dXmin, dYmin, dXmax, dYmax, dOffs)
Else
Return EgtMoveCluster_64(vId, 1, vtMove, dXmin, dYmin, dXmax, dYmax, dOffs)
Return EgtMoveBoxCluster_64(vId, 1, vtMove, dXmin, dYmin, dXmax, dYmax, dOffs)
End If
End Function
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtMovePartCluster")>
Private Function EgtMovePartCluster_32(ByVal vId As Integer(), ByVal nCount As Integer, ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double) As Boolean
End Function
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtMovePartCluster")>
Private Function EgtMovePartCluster_64(ByVal vId As Integer(), ByVal nCount As Integer, ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double) As Boolean
End Function
Public Function EgtMovePartCluster(ByVal vId As Integer(), ByRef vtMove As Vector3d,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double) As Boolean
If IntPtr.Size = 4 Then
Return EgtMovePartCluster_32(vId, vId.Count(), vtMove, dXmin, dYmin, dXmax, dYmax)
Else
Return EgtMovePartCluster_64(vId, vId.Count(), vtMove, dXmin, dYmin, dXmax, dYmax)
End If
End Function
Public Function EgtMoveSelectedPartCluster(ByRef vtMove As Vector3d, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double) As Boolean
Dim vId(1) As Integer
vId(0) = GDB_ID.SEL
If IntPtr.Size = 4 Then
Return EgtMovePartCluster_32(vId, 1, vtMove, dXmin, dYmin, dXmax, dYmax)
Else
Return EgtMovePartCluster_64(vId, 1, vtMove, dXmin, dYmin, dXmax, dYmax)
End If
End Function
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtRotatePartCluster")>
Private Function EgtRotatePartCluster_32(ByVal vId As Integer(), ByVal nCount As Integer, ByRef ptCen As Point3d,
ByRef dRotAngDeg As Double, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double) As Boolean
End Function
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtRotatePartCluster")>
Private Function EgtRotatePartCluster_64(ByVal vId As Integer(), ByVal nCount As Integer, ByRef ptCen As Point3d,
ByRef dRotAngDeg As Double, ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double) As Boolean
End Function
Public Function EgtRotatePartCluster(ByVal vId As Integer(), ByVal ptCen As Point3d, ByRef dRotAngDeg As Double,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double) As Boolean
If IntPtr.Size = 4 Then
Return EgtRotatePartCluster_32(vId, vId.Count(), ptCen, dRotAngDeg, dXmin, dYmin, dXmax, dYmax)
Else
Return EgtRotatePartCluster_64(vId, vId.Count(), ptCen, dRotAngDeg, dXmin, dYmin, dXmax, dYmax)
End If
End Function
Public Function EgtRotateSelectedPartCluster(ByVal ptCen As Point3d, ByRef dRotAngDeg As Double,
ByVal dXmin As Double, ByVal dYmin As Double,
ByVal dXmax As Double, ByVal dYmax As Double) As Boolean
Dim vId(1) As Integer
vId(0) = GDB_ID.SEL
If IntPtr.Size = 4 Then
Return EgtRotatePartCluster_32(vId, 1, ptCen, dRotAngDeg, dXmin, dYmin, dXmax, dYmax)
Else
Return EgtRotatePartCluster_64(vId, 1, ptCen, dRotAngDeg, dXmin, dYmin, dXmax, dYmax)
End If
End Function
<DllImport(EgtIntDll32, CharSet:=CharSet.Unicode, EntryPoint:="EgtGetPartClusterCenterGlob")>
Private Function EgtGetPartClusterCenterGlob_32(ByVal vId As Integer(), ByVal nCount As Integer, ByRef ptCen As Point3d) As Boolean
End Function
<DllImport(EgtIntDll64, CharSet:=CharSet.Unicode, EntryPoint:="EgtGetPartClusterCenterGlob")>
Private Function EgtGetPartClusterCenterGlob_64(ByVal vId As Integer(), ByVal nCount As Integer, ByRef ptCen As Point3d) As Boolean
End Function
Public Function EgtGetPartClusterCenterGlob(ByVal vId As Integer(), ByVal ptCen As Point3d, ByRef dRotAngDeg As Double) As Boolean
If IntPtr.Size = 4 Then
Return EgtGetPartClusterCenterGlob_32(vId, vId.Count(), ptCen)
Else
Return EgtGetPartClusterCenterGlob_64(vId, vId.Count(), ptCen)
End If
End Function
Public Function EgtGetSelectedPartClusterCenterGlob(ByRef ptCen As Point3d) As Boolean
Dim vId(1) As Integer
vId(0) = GDB_ID.SEL
If IntPtr.Size = 4 Then
Return EgtGetPartClusterCenterGlob_32(vId, 1, ptCen)
Else
Return EgtGetPartClusterCenterGlob_64(vId, 1, ptCen)
End If
End Function
@@ -7830,6 +7914,7 @@ Public Const ONEMM As Double = 1.0
Public Const ONEINCH As Double = 25.4
Public Const EPS_SMALL As Double = 0.001
Public Const EPS_ZERO As Double = 0.0000001
Public Const EPS_ANG_SMALL As Double = 0.001
Public Const INFINITO As Double = 10000000000.0
Public Const EPS_STM As Double = 0.05
Public Const EPS_STM_DRAG As Double = 0.5
+1 -1
View File
@@ -301,7 +301,7 @@ Public Class FlatParts
' Ne recupero l'Id
Dim nId2 As Integer = EgtGetLastPart()
' Lo posiziono in ordine
EgtPackPart(nId2, 0, 0, PACK_MAX_X, PACK_MAX_Y, PACK_OFFS, True)
EgtPackBox(nId2, 0, 0, PACK_MAX_X, PACK_MAX_Y, PACK_OFFS, True)
' Cancello il file
My.Computer.FileSystem.DeleteFile(sTmpfile)
End If
+17 -1
View File
@@ -1,6 +1,6 @@
Imports System.Runtime.InteropServices
Imports System.Text
Imports TestEIn.EgtInterface
Imports EgtUILib.EgtInterface
Public Module GenInterface
@@ -155,5 +155,21 @@ Public Enum SW As Integer
RESTORE = 9
End Enum
'-------------------------------- File Path ------------------------------------------------------
' Truncates a path to fit within a certain number of characters by replacing path components with ellipses.
' pszOut = The address of the string that has been altered.
' pszSrc = A pointer to a null-terminated string of length MAX_PATH that contains the path to be altered.
' cchMax = The maximum number of characters to be contained in the new string, including the terminating null.
' reserved = Reserved
' Returns TRUE if successful, or FALSE otherwise.
<DllImport("shlwapi.dll", EntryPoint:="PathCompactPathExW", SetLastError:=True, CharSet:=CharSet.Unicode)>
Public Function PathCompactPathEx(
<MarshalAs(UnmanagedType.LPTStr)> pszOut As System.Text.StringBuilder,
<MarshalAs(UnmanagedType.LPTStr)> pszSrc As String,
cchMax As UInteger,
reserved As Integer
) As <MarshalAs(UnmanagedType.Bool)> Boolean
End Function
End Module
+3 -3
View File
@@ -27,7 +27,7 @@ Imports System.Runtime.InteropServices
#End If
<Assembly: AssemblyCompany("EgalTech s.r.l.")>
<Assembly: AssemblyProduct("TestEIn")>
<Assembly: AssemblyCopyright("Copyright © 2014-2015 by EgalTech s.r.l.")>
<Assembly: AssemblyCopyright("Copyright © 2014-2016 by EgalTech s.r.l.")>
<Assembly: AssemblyTrademark("")>
<Assembly: ComVisible(False)>
@@ -46,5 +46,5 @@ Imports System.Runtime.InteropServices
' utilizzando l'asterisco (*) come descritto di seguito:
' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("1.6.12.4")>
<Assembly: AssemblyFileVersion("1.6.12.4")>
<Assembly: AssemblyVersion("1.6.12.5")>
<Assembly: AssemblyFileVersion("1.6.12.5")>