[Bprocessor-commit] gl/src/net/sourceforge/bprocessor/gl/view View.java, 1.186, 1.187
Status: Pre-Alpha
Brought to you by:
henryml
|
From: Michael L. <he...@us...> - 2007-02-15 15:12:18
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10428/src/net/sourceforge/bprocessor/gl/view Modified Files: View.java Log Message: More refactoring Index: View.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view/View.java,v retrieving revision 1.186 retrieving revision 1.187 diff -C2 -d -r1.186 -r1.187 *** View.java 15 Feb 2007 14:57:37 -0000 1.186 --- View.java 15 Feb 2007 15:12:13 -0000 1.187 *************** *** 1187,1190 **** --- 1187,1203 ---- } + + private void drawConstructors(Collection<Constructor> constructors) { + Camera camera = Project.getInstance().getCurrentCamera(); + for (Constructor constructor : constructors) { + double dist = camera.distance(constructor.getOrigin()); + if (target != constructor && !highligts.contains(constructor)) { + if (constructor != Project.getInstance().getActiveCoordinateSystem()) { + drawGeneralConstructor(constructor, dist, true, OBJECTS); + } + } + } + } + /** * Draw all constructors in this level and all above *************** *** 1209,1220 **** transformTo(active); Collection<Constructor> constructors = active.getConstructors(); ! for (Constructor constructor : constructors) { ! double dist = camera.distance(constructor.getOrigin()); ! if (target != constructor && !highligts.contains(constructor)) { ! if (constructor != Project.getInstance().getActiveCoordinateSystem()) { ! drawGeneralConstructor(constructor, dist, true, OBJECTS); ! } ! } ! } gl.glPopMatrix(); } else { --- 1222,1226 ---- transformTo(active); Collection<Constructor> constructors = active.getConstructors(); ! drawConstructors(constructors); gl.glPopMatrix(); } else { *************** *** 1223,1235 **** active = active.getOwner(); } ! Iterator iter = tempConstructors.iterator(); ! while (iter.hasNext()) { ! Constructor constructor = (Constructor)iter.next(); ! double dist = camera.distance(constructor.getOrigin()); ! drawGeneralConstructor(constructor, dist, true, OBJECTS); ! } enableClipplanes(); } ! /** * FIXME edge-drawing --- 1229,1236 ---- active = active.getOwner(); } ! drawConstructors(tempConstructors); enableClipplanes(); } ! /** * FIXME edge-drawing |