public BoundaryConverter(VoronoiBoundary boundary, PeriodicMap periodicMap = null) { if (periodicMap != null) { this.periodicBoundaryConverter = new PeriodicBoundaryConverter(boundary, periodicMap); } this.boundary = boundary; }
static byte[] ExtractEdgeTags(VoronoiBoundary boundary, PeriodicMap map) { byte[] voronoiEdgeTags = boundary.EdgeTags; byte[] periodicCornerEdgeTags = GetPeriodicCornerEdgeTags( map.PeriodicCornerCorrelation, map.PeriodicBoundaryCorrelation); byte[] edgeTags = Concat(voronoiEdgeTags, periodicCornerEdgeTags); return(edgeTags); }
public PeriodicBoundaryConverter( VoronoiBoundary boundary, PeriodicMap map) { edgePairer = new EdgePairer(); edgeTags = ExtractEdgeTags(boundary, map); this.boundaryMap = CreatePeriodicBoundaryMap <SortedList <byte, AffineTrafo>, LinkedListDictionary <int, bool> >( edgeTags, map); }
public PeriodicBoundaryHandler( PeriodicMap map = null) { if (map != null) { ContainsPeriodicBoundaries = true; periodicTrafoMap = map.PeriodicBoundaryTransformations; nodeCloner = new BoundaryNodeMirrorer <T>(map); recomposer = new BoundaryRecomposer <T>(map); } else { ContainsPeriodicBoundaries = false; } }
static PeriodicBoundaryConverterMap CreatePeriodicBoundaryMap <TtrafoDictionary, TinverseDictionary>( byte[] edgeTags, PeriodicMap map) where TtrafoDictionary : IDictionary <byte, AffineTrafo>, new() where TinverseDictionary : IDictionary <int, bool>, new() { var periodicInverseMap = ExtractPeriodicInverseMap <TinverseDictionary>(map.PeriodicBoundaryCorrelation); var periodicTrafos = ExtractPeriodicTrafos <TtrafoDictionary>( edgeTags, periodicInverseMap, map.PeriodicBoundaryTransformations); var boundaryMap = new PeriodicBoundaryConverterMap() { PeriodicInverseMap = periodicInverseMap, PeriodicTrafos = periodicTrafos }; return(boundaryMap); }
public CellPairCollecter(PeriodicMap map) { this.map = map; }
public BoundaryRecomposer(PeriodicMap map) { this.map = map; }
public GridConverter(VoronoiBoundary boundary, PeriodicMap periodicMap = null) { this.boundary = boundary; boundaryConverter = new BoundaryConverter(boundary, periodicMap); }
public PeriodicCornerBoundaryIdentifier(PeriodicMap map) { CrossingFinder.map = map; }
public PeriodicCornerBoundaryAssigner(PeriodicMap map) { this.map = map; }
public BoundaryNodeMirrorer( PeriodicMap map) { this.map = map; }