[Bprocessor-commit] model/src/net/sourceforge/bprocessor/model Surface.java, 1.187, 1.188
Status: Pre-Alpha
Brought to you by:
henryml
From: rimestad <rim...@us...> - 2007-10-05 09:15:58
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv25966/src/net/sourceforge/bprocessor/model Modified Files: Surface.java Log Message: Made changes to direction so that direction can be calc. for not self connecting edgelists Index: Surface.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Surface.java,v retrieving revision 1.187 retrieving revision 1.188 diff -C2 -d -r1.187 -r1.188 *** Surface.java 3 Oct 2007 10:01:19 -0000 1.187 --- Surface.java 5 Oct 2007 09:15:54 -0000 1.188 *************** *** 72,81 **** * @return turn direction of the edges with respect to the given coordinate-system */ ! public static int direction(List edges, CoordinateSystem system) { double y = Double.MAX_VALUE; Edge e1 = null; Edge e2 = null; ! Edge previous = (Edge) edges.get(edges.size() - 1); Iterator iter = edges.iterator(); while (iter.hasNext()) { Edge current = (Edge) iter.next(); --- 72,86 ---- * @return turn direction of the edges with respect to the given coordinate-system */ ! public static int direction(List<Edge> edges, CoordinateSystem system) { ! if (edges.size() < 2) { ! log.error("Could not calculate direction for edge list due to its size"); ! return PARALLEL; ! } double y = Double.MAX_VALUE; Edge e1 = null; Edge e2 = null; ! Edge previous = edges.get(0); Iterator iter = edges.iterator(); + iter.next(); while (iter.hasNext()) { Edge current = (Edge) iter.next(); *************** *** 2140,2145 **** */ public static void mergeSpaceAssign(Surface sur1, Surface sur2, Surface onto) { ! Space front = null; ! Space back = null; Vertex n1 = sur1.normal(); Vertex n2 = sur2.normal(); --- 2145,2150 ---- */ public static void mergeSpaceAssign(Surface sur1, Surface sur2, Surface onto) { ! Space front = onto.frontDomain; ! Space back = onto.backDomain; Vertex n1 = sur1.normal(); Vertex n2 = sur2.normal(); |