EgtNesting :
- aggiunta funzione AddAnotherOutlineToPart.
This commit is contained in:
+22
-1
@@ -1,7 +1,7 @@
|
||||
//----------------------------------------------------------------------------
|
||||
// EgalTech 2019-2019
|
||||
//----------------------------------------------------------------------------
|
||||
// File : AutoNester.cpp Data : 28.11.19 Versione : 2.1k6
|
||||
// File : AutoNester.cpp Data : 05.12.19 Versione : 2.1l2
|
||||
// Contenuto : Implementazione della classe AutoNester.
|
||||
//
|
||||
//
|
||||
@@ -165,6 +165,27 @@ AutoNester::AddPart( int nPartId, const PolyArc& Outline, bool bCanFlip, bool bC
|
||||
return true ;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool
|
||||
AutoNester::AddAnotherOutlineToPart( int nPartId, const PolyArc& AnotherOutline)
|
||||
{
|
||||
if ( m_pOrder == nullptr)
|
||||
return false ;
|
||||
// verifico outline
|
||||
if ( AnotherOutline.GetArcNbr() == 0 || ! AnotherOutline.IsClosed())
|
||||
return false ;
|
||||
// cerco il pezzo
|
||||
const auto Iter = m_IdPartPtr.find( nPartId) ;
|
||||
if ( Iter == m_IdPartPtr.end())
|
||||
return false ;
|
||||
CNS_PartPtr pPart = Iter->second ;
|
||||
// aggiungo contorno aggiuntivo al pezzo
|
||||
vector<CNS_Element> vElem ;
|
||||
GetCNSPath( AnotherOutline, vElem) ;
|
||||
CNS_AddExternalBoundaryToPart( pPart, int( vElem.size()), vElem.data()) ;
|
||||
return true ;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool
|
||||
AutoNester::AddToolOutlineToPart( int nPartId, const PolyArc& ToolOutline)
|
||||
|
||||
Reference in New Issue
Block a user