[Bprocessor-commit] model/src/net/sourceforge/bprocessor/model Project.java, 1.164, 1.165
Status: Pre-Alpha
Brought to you by:
henryml
From: Michael L. <he...@us...> - 2009-04-30 11:55:22
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv1005/src/net/sourceforge/bprocessor/model Modified Files: Project.java Log Message: Index: Project.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Project.java,v retrieving revision 1.164 retrieving revision 1.165 diff -C2 -d -r1.164 -r1.165 *** Project.java 23 Apr 2009 08:17:46 -0000 1.164 --- Project.java 30 Apr 2009 11:55:08 -0000 1.165 *************** *** 1309,1316 **** } private Segment find(Location location, Segment segment) { ! Boundary boundary = location.getExternalBoundary(); ! for (Segment current : boundary.getSegments()) { ! if (eq(current, segment)) { ! return current; } } --- 1309,1320 ---- } private Segment find(Location location, Segment segment) { ! List<Boundary> all = new LinkedList(); ! all.add(location.getExternalBoundary()); ! all.addAll(location.getInternalBoundaries()); ! for (Boundary boundary : all) { ! for (Segment current : boundary.getSegments()) { ! if (eq(current, segment)) { ! return current; ! } } } *************** *** 1357,1362 **** --- 1361,1368 ---- { Set<Surface> envelope = space.getEnvelope(); + if (envelope.size() == 1) { Surface surface = envelope.iterator().next(); + List<Edge> all = new LinkedList(surface.getEdges()); List<Vertex> vertices = surface.getVertices(); Boundary boundary = new Boundary(convert(vertices)); *************** *** 1376,1379 **** --- 1382,1387 ---- } + all.addAll(loners); + List<List<Edge>> internals = new LinkedList(); Set<Edge> bag = new HashSet(loners); *************** *** 1414,1418 **** locations.put(surface, location); int count = 1; ! for (Edge edge : surface.getEdges()) { if (edge.isSmooth()) { Segment segment = convert(edge); --- 1422,1426 ---- locations.put(surface, location); int count = 1; ! for (Edge edge : all) { if (edge.isSmooth()) { Segment segment = convert(edge); *************** *** 1448,1452 **** --- 1456,1464 ---- } for (Edge edge : smoothies) { + System.out.println(edge + " is smooth"); List<Opening> lst = e2o.get(edge); + for (Opening opening : lst) { + System.out.println(" " + opening); + } if (lst.size() == 2) { Opening from = lst.get(0); |