bprocessor-commit Mailing List for B-processor (Page 18)
Status: Pre-Alpha
Brought to you by:
henryml
You can subscribe to this list here.
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(12) |
Jul
(117) |
Aug
(151) |
Sep
(157) |
Oct
(81) |
Nov
(117) |
Dec
(119) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(183) |
Feb
(130) |
Mar
(117) |
Apr
(61) |
May
(82) |
Jun
(45) |
Jul
(149) |
Aug
(173) |
Sep
(199) |
Oct
(165) |
Nov
(107) |
Dec
(137) |
2007 |
Jan
(124) |
Feb
(58) |
Mar
(123) |
Apr
(80) |
May
(130) |
Jun
(64) |
Jul
(31) |
Aug
(42) |
Sep
(114) |
Oct
(167) |
Nov
(239) |
Dec
(200) |
2008 |
Jan
(43) |
Feb
(43) |
Mar
(4) |
Apr
(9) |
May
(5) |
Jun
(1) |
Jul
(3) |
Aug
(3) |
Sep
(13) |
Oct
(9) |
Nov
(12) |
Dec
|
2009 |
Jan
|
Feb
(20) |
Mar
(7) |
Apr
(12) |
May
(34) |
Jun
(72) |
Jul
|
Aug
(3) |
Sep
(31) |
Oct
(2) |
Nov
(8) |
Dec
(4) |
2010 |
Jan
(5) |
Feb
(32) |
Mar
(8) |
Apr
(7) |
May
(36) |
Jun
|
Jul
(11) |
Aug
(15) |
Sep
(7) |
Oct
(2) |
Nov
(13) |
Dec
(80) |
2011 |
Jan
|
Feb
|
Mar
(8) |
Apr
(12) |
May
(32) |
Jun
(9) |
Jul
(5) |
Aug
|
Sep
(2) |
Oct
|
Nov
|
Dec
(8) |
2012 |
Jan
|
Feb
|
Mar
(3) |
Apr
(5) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(22) |
Jun
(5) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Michael L. <he...@us...> - 2009-06-25 20:29:41
|
Update of /cvsroot/bprocessor/bscript/src/net/sourceforge/bprocessor/model/evaluator In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16557/src/net/sourceforge/bprocessor/model/evaluator Modified Files: Function.java Log Message: New files Index: Function.java =================================================================== RCS file: /cvsroot/bprocessor/bscript/src/net/sourceforge/bprocessor/model/evaluator/Function.java,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** Function.java 11 Oct 2006 11:23:26 -0000 1.7 --- Function.java 25 Jun 2009 20:29:38 -0000 1.8 *************** *** 8,19 **** package net.sourceforge.bprocessor.model.evaluator; - import java.util.Iterator; - import java.util.LinkedList; import java.util.List; import java.util.Stack; import java.util.Vector; - import antlr.CharScanner; - /** * Function --- 8,15 ---- |
From: Michael L. <he...@us...> - 2009-06-25 20:29:41
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/bridge In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16490/src/net/sourceforge/bprocessor/model/bridge Modified Files: DataItem.java Log Message: New files Index: DataItem.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/bridge/DataItem.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** DataItem.java 4 Feb 2009 15:09:52 -0000 1.2 --- DataItem.java 25 Jun 2009 20:29:33 -0000 1.3 *************** *** 20,25 **** --- 20,27 ---- */ public class DataItem extends Entity implements Parametric { + @SuppressWarnings("unused") private int id; private long timestamp; + @SuppressWarnings("unused") private short datatype; private long data; |
From: Michael L. <he...@us...> - 2009-06-25 20:29:41
|
Update of /cvsroot/bprocessor/bprocessor/src/net/sourceforge/bprocessor In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16380/src/net/sourceforge/bprocessor Modified Files: Application.java Log Message: New files Index: Application.java =================================================================== RCS file: /cvsroot/bprocessor/bprocessor/src/net/sourceforge/bprocessor/Application.java,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** Application.java 22 Sep 2008 15:58:14 -0000 1.9 --- Application.java 25 Jun 2009 20:29:20 -0000 1.10 *************** *** 1,24 **** package net.sourceforge.bprocessor; - import java.io.ByteArrayInputStream; - import java.io.ByteArrayOutputStream; - import java.io.IOException; - import java.net.InetAddress; - import java.net.InetSocketAddress; - import java.net.Socket; - import java.net.SocketAddress; - import java.net.UnknownHostException; - import java.util.Calendar; - import java.util.Date; - import java.util.LinkedList; - import java.util.List; - import net.sourceforge.bprocessor.facade.FacadeMain; import net.sourceforge.bprocessor.gl.Editor; import net.sourceforge.bprocessor.gui.GUI; - import net.sourceforge.bprocessor.model.bridge.Connection; - import net.sourceforge.bprocessor.model.bridge.DataItem; - import net.sourceforge.bprocessor.model.bridge.DeSerializer; - import net.sourceforge.bprocessor.model.bridge.Serializer; import org.apache.log4j.PropertyConfigurator; --- 1,7 ---- |
From: Michael L. <he...@us...> - 2009-06-25 20:29:36
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/modellor In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16490/src/net/sourceforge/bprocessor/model/modellor Modified Files: InnerWallModellor.java ModelBathModellor2.java TileModellor.java WallPartingModellor.java Log Message: New files Index: TileModellor.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/modellor/TileModellor.java,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** TileModellor.java 3 Nov 2008 13:14:09 -0000 1.30 --- TileModellor.java 25 Jun 2009 20:29:33 -0000 1.31 *************** *** 171,175 **** Surface outer = surface.copyall(space); Collection<Surface> surs = net.getSurfaces(); - int lvl = space.getLevel() + 1; double offset = -(double)jointSize / 2000; for (Surface s : surs) { --- 171,174 ---- Index: WallPartingModellor.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/modellor/WallPartingModellor.java,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** WallPartingModellor.java 3 Nov 2008 13:14:09 -0000 1.9 --- WallPartingModellor.java 25 Jun 2009 20:29:33 -0000 1.10 *************** *** 58,66 **** } - private Map<Vertex, Vertex> findDirection() { - - return null; - } - /** * {@inheritDoc} --- 58,61 ---- Index: InnerWallModellor.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/modellor/InnerWallModellor.java,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** InnerWallModellor.java 3 Nov 2008 13:14:09 -0000 1.18 --- InnerWallModellor.java 25 Jun 2009 20:29:33 -0000 1.19 *************** *** 21,25 **** import net.sourceforge.bprocessor.model.Edge; import net.sourceforge.bprocessor.model.Geometry; - import net.sourceforge.bprocessor.model.Plane; import net.sourceforge.bprocessor.model.Project; import net.sourceforge.bprocessor.model.Surface; --- 21,24 ---- *************** *** 619,637 **** /** - * Checks if all of a net is in a given plane. - * @param net the net - * @param p the plane - * @return true if all geometry in the net is in the plane, false otherwise - */ - private boolean getPlaneCheck(Container net, Plane p) { - for (Edge e : net.getEdges()) { - if (!p.contains(e)) { - return false; - } - } - return true; - } - - /** * For setting attributes. If the candidate is different from the current * the space is cleared, the build flag is set and the candidate is returned. Otherwise --- 618,621 ---- Index: ModelBathModellor2.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/modellor/ModelBathModellor2.java,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** ModelBathModellor2.java 3 Nov 2008 14:26:18 -0000 1.18 --- ModelBathModellor2.java 25 Jun 2009 20:29:33 -0000 1.19 *************** *** 175,197 **** } - private void addTileModellors() { - for (Space elem : walls.getElements()) { - if (elem.getType() == Container.CONSTRUCTION && - elem.isContainer() && - elem.getName().equals("Tile")) { - TileModellor tm = new TileModellor((Container) elem); - insideModellors .add(tm); - elem.setModellor(tm); - } - } - } - - private void elementWalls2() { - WallPartingModellor wpm = new WallPartingModellor(walls, net); - - walls.setModellor(wpm); - wpm.update(walls); - } - /** * Part the walls space into elements --- 175,178 ---- *************** *** 365,369 **** // copy doors and windows in for (Container spc : doorAndWindows) { - double maxDist = 0; Surface inner = null; for (Surface s : spc.getEnvelope()) { --- 346,349 ---- *************** *** 518,522 **** bathcabin.setBackDomain(bath); - Vertex center = s.center(); Collection<Edge> remain = new ArrayList<Edge>(net.getEdges()); remain.removeAll(s.getEdges()); --- 498,501 ---- |
From: Michael L. <he...@us...> - 2009-06-25 20:29:36
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16490/src/net/sourceforge/bprocessor/model Modified Files: Command.java Selector.java Project.java Persistence.java Entity.java Surface.java Camera.java SurfaceSorter.java Constructor.java Selection.java Log Message: New files Index: Constructor.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Constructor.java,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** Constructor.java 12 Nov 2007 08:05:25 -0000 1.24 --- Constructor.java 25 Jun 2009 20:29:33 -0000 1.25 *************** *** 14,18 **** import java.util.Set; - import org.apache.log4j.Logger; /** --- 14,17 ---- *************** *** 21,28 **** */ public abstract class Constructor extends Geometric implements Parametric { - - /** The logger */ - private static Logger log = Logger.getLogger(Constructor.class); - /** The origin of the constructor */ protected Vertex origin; --- 20,23 ---- Index: Command.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Command.java,v retrieving revision 1.77 retrieving revision 1.78 diff -C2 -d -r1.77 -r1.78 *** Command.java 19 Jun 2009 13:32:25 -0000 1.77 --- Command.java 25 Jun 2009 20:29:33 -0000 1.78 *************** *** 999,1003 **** Surface bottom = new Surface(edges); Container space = Project.getInstance().getActiveSpace(); ! Container inside = space.createConstructionSpace("Cylinder"); bottom.setFrontDomain(inside); Set<Surface> sides = new HashSet<Surface>(); --- 999,1003 ---- Surface bottom = new Surface(edges); Container space = Project.getInstance().getActiveSpace(); ! Container inside = Space.createConstructionSpace("Cylinder"); bottom.setFrontDomain(inside); Set<Surface> sides = new HashSet<Surface>(); *************** *** 1175,1179 **** public void evaluate() { double radius = parameters.getDouble("radius"); - CoordinateSystem system = Project.getInstance().getActiveCoordinateSystem(); int stacks = 8; int slices = 6; --- 1175,1178 ---- *************** *** 2495,2501 **** double width = xmax - xmin; - double height = ymax - ymin; int n; - int m; --- 2494,2498 ---- Index: Surface.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Surface.java,v retrieving revision 1.224 retrieving revision 1.225 diff -C2 -d -r1.224 -r1.225 *** Surface.java 21 Apr 2009 10:21:21 -0000 1.224 --- Surface.java 25 Jun 2009 20:29:33 -0000 1.225 *************** *** 1544,1557 **** } - - private static boolean check(double[] values) { - for (int i = 0; i < values.length; i++) { - if (String.valueOf(values[i]).equals("NaN")) { - return false; - } - } - return true; - } - /** * @param edges edges --- 1544,1547 ---- Index: Entity.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Entity.java,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** Entity.java 20 Dec 2007 14:19:55 -0000 1.23 --- Entity.java 25 Jun 2009 20:29:33 -0000 1.24 *************** *** 16,27 **** import java.util.Map; - import org.apache.log4j.Logger; /** * The entity class */ public abstract class Entity implements Serializable { - /** The Logger */ - private static Logger log = Logger.getLogger(Entity.class); - /** The id */ protected Long id; --- 16,23 ---- Index: Project.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Project.java,v retrieving revision 1.177 retrieving revision 1.178 diff -C2 -d -r1.177 -r1.178 *** Project.java 23 Jun 2009 12:08:45 -0000 1.177 --- Project.java 25 Jun 2009 20:29:33 -0000 1.178 *************** *** 52,58 **** import dk.au.perpos.spatialsupport.routefinding.Boundary; ! import dk.au.perpos.spatialsupport.routefinding.Location; import dk.au.perpos.spatialsupport.routefinding.LocationModel; import dk.au.perpos.spatialsupport.routefinding.Opening; import dk.au.perpos.spatialsupport.routefinding.Segment; import dk.au.perpos.spatialsupport.routefinding.io.PPLMPrinter; --- 52,60 ---- import dk.au.perpos.spatialsupport.routefinding.Boundary; ! import dk.au.perpos.spatialsupport.locationmodel.Location; ! import dk.au.perpos.spatialsupport.routefinding.Area; import dk.au.perpos.spatialsupport.routefinding.LocationModel; import dk.au.perpos.spatialsupport.routefinding.Opening; + import dk.au.perpos.spatialsupport.routefinding.Point2d; import dk.au.perpos.spatialsupport.routefinding.Segment; import dk.au.perpos.spatialsupport.routefinding.io.PPLMPrinter; *************** *** 1268,1273 **** ! private boolean eq(dk.au.perpos.spatialsupport.routefinding.Point p1, ! dk.au.perpos.spatialsupport.routefinding.Point p2) { if (p1.getX() != p2.getX()) { return false; --- 1270,1275 ---- ! private boolean eq(Point2d p1, ! Point2d p2) { if (p1.getX() != p2.getX()) { return false; *************** *** 1287,1291 **** return false; } ! private Segment find(Location location, Segment segment) { List<Boundary> all = new LinkedList(); all.add(location.getExternalBoundary()); --- 1289,1293 ---- return false; } ! private Segment find(Area location, Segment segment) { List<Boundary> all = new LinkedList(); all.add(location.getExternalBoundary()); *************** *** 1301,1306 **** } ! private List<dk.au.perpos.spatialsupport.routefinding.Point> convert(List<Vertex> vertices) { ! List<dk.au.perpos.spatialsupport.routefinding.Point> points = new LinkedList(); for (Vertex current : vertices) { points.add(convert(current)); --- 1303,1308 ---- } ! private List<Point2d> convert(List<Vertex> vertices) { ! List<Point2d> points = new LinkedList(); for (Vertex current : vertices) { points.add(convert(current)); *************** *** 1309,1315 **** } ! private dk.au.perpos.spatialsupport.routefinding.Point convert(Vertex vertex) { ! dk.au.perpos.spatialsupport.routefinding.Point point ! = new dk.au.perpos.spatialsupport.routefinding.Point(); point.setX(vertex.getX()); point.setY(vertex.getY()); --- 1311,1317 ---- } ! private Point2d convert(Vertex vertex) { ! Point2d point ! = new Point2d(); point.setX(vertex.getX()); point.setY(vertex.getY()); *************** *** 1338,1344 **** } ! private List<Location> createLocationModel(Container space, int level, ! Map<Surface, Location> locations, Map<Edge, List<Opening>> openings) { ! List<Location> locs = new LinkedList(); List<Surface> envelope = new LinkedList(space.getEnvelope()); int no = 0; --- 1340,1346 ---- } ! private List<Area> createLocationModel(Container space, int level, ! Map<Surface, Area> locations, Map<Edge, List<Opening>> openings) { ! List<Area> locs = new LinkedList(); List<Surface> envelope = new LinkedList(space.getEnvelope()); int no = 0; *************** *** 1354,1361 **** } ! private Location createLocationModel(Container space, int level, ! Map<Surface, Location> locations, Map<Edge, List<Opening>> openings, Surface surface, int no) { ! Location location = new Location(); if (no > 0) { location.setId(space.getName() + "-" + no); --- 1356,1363 ---- } ! private Area createLocationModel(Container space, int level, ! Map<Surface, Area> locations, Map<Edge, List<Opening>> openings, Surface surface, int no) { ! Area location = new Area(); if (no > 0) { location.setId(space.getName() + "-" + no); *************** *** 1457,1461 **** } ! Map<Surface, Location> s2l = new HashMap(); Map<Edge, List<Opening>> e2o = new HashMap(); List<Edge> smoothies = new LinkedList(); --- 1459,1463 ---- } ! Map<Surface, Area> s2l = new HashMap(); Map<Edge, List<Opening>> e2o = new HashMap(); List<Edge> smoothies = new LinkedList(); *************** *** 1469,1474 **** for (Space element : space.getElements()) { if (!element.isVoid()) { ! List<Location> children = createLocationModel((Container) element, level + 1, s2l, e2o); ! for (Location child : children) { location.addChild(child); } --- 1471,1476 ---- for (Space element : space.getElements()) { if (!element.isVoid()) { ! List<Area> children = createLocationModel((Container) element, level + 1, s2l, e2o); ! for (Area child : children) { location.addChild(child); } *************** *** 1494,1502 **** } ! private Location createFlatLocationModel() { ! Location root = new Location(); root.setId("building"); root.setDescription("none"); ! Map<Surface, Location> map = new HashMap(); Map<Edge, List<Surface>> e2s = new HashMap(); int openingId = 0; --- 1496,1504 ---- } ! private Area createFlatLocationModel() { ! Area root = new Area(); root.setId("building"); root.setDescription("none"); ! Map<Surface, Area> map = new HashMap(); Map<Edge, List<Surface>> e2s = new HashMap(); int openingId = 0; *************** *** 1511,1521 **** surfaces.add(surface); } ! Location node = new Location(); map.put(surface, node); node.setHeight(3); ! List<dk.au.perpos.spatialsupport.routefinding.Point> points = new LinkedList(); for (Vertex vertex : surface.getVertices()) { ! dk.au.perpos.spatialsupport.routefinding.Point point ! = new dk.au.perpos.spatialsupport.routefinding.Point(); point.setX(vertex.getX()); point.setY(vertex.getY()); --- 1513,1523 ---- surfaces.add(surface); } ! Area node = new Area(); map.put(surface, node); node.setHeight(3); ! List<Point2d> points = new LinkedList(); for (Vertex vertex : surface.getVertices()) { ! Point2d point ! = new Point2d(); point.setX(vertex.getX()); point.setY(vertex.getY()); *************** *** 1524,1529 **** Boundary area = new Boundary(); { ! dk.au.perpos.spatialsupport.routefinding.Point previous = points.get(points.size() - 1); ! for (dk.au.perpos.spatialsupport.routefinding.Point current : points) { Segment segment = new Segment(); segment.setFrom(previous); --- 1526,1531 ---- Boundary area = new Boundary(); { ! Point2d previous = points.get(points.size() - 1); ! for (Point2d current : points) { Segment segment = new Segment(); segment.setFrom(previous); *************** *** 1553,1558 **** Surface s1 = surfaces.get(0); Surface s2 = surfaces.get(1); ! Location n1 = map.get(s1); ! Location n2 = map.get(s2); Opening o1 = new Opening(); openingId++; --- 1555,1560 ---- Surface s1 = surfaces.get(0); Surface s2 = surfaces.get(1); ! Area n1 = map.get(s1); ! Area n2 = map.get(s2); Opening o1 = new Opening(); openingId++; *************** *** 1583,1586 **** --- 1585,1639 ---- } + + private void processBoundary(Area location) { + if (location.getChildren().isEmpty()) { + // + } else { + double xmin = Double.POSITIVE_INFINITY; + double xmax = Double.NEGATIVE_INFINITY; + double ymin = Double.POSITIVE_INFINITY; + double ymax = Double.NEGATIVE_INFINITY; + + LinkedList<Boundary> internals = new LinkedList(); + for (Area current : location.getChildren()) { + processBoundary(current); + internals.add(current.getExternalBoundary()); + } + LinkedList<Point2d> points = new LinkedList(); + for (Boundary boundary : internals) { + points.addAll(boundary.getPoints()); + } + for (Point2d current : points) { + if (current.getX() < xmin) { + xmin = current.getX(); + } + if (current.getX() > xmax) { + xmax = current.getX(); + } + if (current.getY() < ymin) { + ymin = current.getY(); + } + if (current.getY() > ymax) { + ymax = current.getY(); + } + } + Point2d p1 = new Point2d(xmin, ymin); + Point2d p2 = new Point2d(xmin, ymax); + Point2d p3 = new Point2d(xmax, ymax); + Point2d p4 = new Point2d(xmax, ymin); + Segment s1 = new Segment(p1, p2); + Segment s2 = new Segment(p2, p3); + Segment s3 = new Segment(p3, p4); + Segment s4 = new Segment(p4, p1); + Boundary external = new Boundary(); + external.add(s1); + external.add(s2); + external.add(s3); + external.add(s4); + location.setExternalBoundary(external); + + } + } + /** * *************** *** 1589,1594 **** public void exportPPLM(OutputStream out) { world().setName(getName()); ! List<Location> roots = createLocationModel(world(), 1, new HashMap(), new HashMap()); ! Location root = roots.get(0); LocationModel model = new LocationModel(); model.setLocation(root); --- 1642,1651 ---- public void exportPPLM(OutputStream out) { world().setName(getName()); ! List<Area> roots = createLocationModel(world(), 1, new HashMap(), new HashMap()); ! Area root = roots.get(0); ! ! processBoundary(root); ! ! LocationModel model = new LocationModel(); model.setLocation(root); *************** *** 1658,1670 **** */ public void exportJLMA() { ! Location root = createFlatLocationModel(); PrintStream out = System.out; out.println("<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>"); out.println("<GST>"); out.println("<GSTNode name=\"bygning\">"); ! for (Location node : root.getChildren()) { out.println("<GSTNode name =\"" + node.getId() + "\">"); out.println("<Area>"); ! for (dk.au.perpos.spatialsupport.routefinding.Point point : node.getExternalBoundary().getPoints()) { out.println("<Point2D x=\"" + point.getX() + "\" y=\"" + point.getY() + "\" />"); --- 1715,1727 ---- */ public void exportJLMA() { ! Area root = createFlatLocationModel(); PrintStream out = System.out; out.println("<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>"); out.println("<GST>"); out.println("<GSTNode name=\"bygning\">"); ! for (Area node : root.getChildren()) { out.println("<GSTNode name =\"" + node.getId() + "\">"); out.println("<Area>"); ! for (Point2d point : node.getExternalBoundary().getPoints()) { out.println("<Point2D x=\"" + point.getX() + "\" y=\"" + point.getY() + "\" />"); Index: Camera.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Camera.java,v retrieving revision 1.58 retrieving revision 1.59 diff -C2 -d -r1.58 -r1.59 *** Camera.java 5 Feb 2008 14:21:08 -0000 1.58 --- Camera.java 25 Jun 2009 20:29:33 -0000 1.59 *************** *** 69,73 **** /** The ralation between cm and inches */ ! private static final double RELATION = 2.54; /** Hidden geometrics */ --- 69,73 ---- /** The ralation between cm and inches */ ! public static final double RELATION = 2.54; /** Hidden geometrics */ Index: Selector.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Selector.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** Selector.java 31 Aug 2007 09:09:09 -0000 1.4 --- Selector.java 25 Jun 2009 20:29:33 -0000 1.5 *************** *** 10,15 **** import java.util.List; - import org.apache.log4j.Logger; - /** * A list of possible values for an attribute. --- 10,13 ---- *************** *** 18,24 **** public class Selector<Type> { - /** The logger */ - private static Logger log = Logger.getLogger(Selector.class); - /** The options to choose from */ private List<Type> options; --- 16,19 ---- Index: Persistence.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Persistence.java,v retrieving revision 1.78 retrieving revision 1.79 diff -C2 -d -r1.78 -r1.79 *** Persistence.java 22 Jun 2009 12:39:16 -0000 1.78 --- Persistence.java 25 Jun 2009 20:29:33 -0000 1.79 *************** *** 442,445 **** --- 442,446 ---- * @return the new model object */ + @SuppressWarnings("unused") private static Transform internalizeTransformation(TransformType current, Collection xmls) { if (current instanceof RotateType) { *************** *** 1131,1134 **** --- 1132,1136 ---- * @return the xml object */ + @SuppressWarnings("unused") private static Object externalizeTransformation(Transform current, Map map) { if (current instanceof Rotate) { Index: SurfaceSorter.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/SurfaceSorter.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** SurfaceSorter.java 7 May 2007 09:48:44 -0000 1.2 --- SurfaceSorter.java 25 Jun 2009 20:29:33 -0000 1.3 *************** *** 13,17 **** */ public class SurfaceSorter<T extends Surface> extends Sorter<T> { - private Edge edge; /** --- 13,16 ---- *************** *** 19,23 **** */ public SurfaceSorter(Edge edge) { ! this.edge = edge; } --- 18,22 ---- */ public SurfaceSorter(Edge edge) { ! } *************** *** 25,30 **** @Override public Entry entryFor(T surface) { - Vertex normal = surface.normal(); - Vertex direction = edge.getDirection(); return new Entry(surface, 0 , 1); } --- 24,27 ---- Index: Selection.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Selection.java,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** Selection.java 29 Aug 2008 12:27:32 -0000 1.19 --- Selection.java 25 Jun 2009 20:29:33 -0000 1.20 *************** *** 14,18 **** import java.util.List; import java.util.Set; - import org.apache.log4j.Logger; /** --- 14,17 ---- *************** *** 22,27 **** */ public class Selection implements Collection<Geometric> { - /** The logger */ - private static Logger log = Logger.getLogger(Selection.class); private static final boolean VERIFY = false; --- 21,24 ---- |
From: Michael L. <he...@us...> - 2009-06-25 20:29:32
|
Update of /cvsroot/bprocessor/tools/perpos In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16411/perpos Modified Files: routefinding.jar Log Message: New files Index: routefinding.jar =================================================================== RCS file: /cvsroot/bprocessor/tools/perpos/routefinding.jar,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 Binary files /tmp/cvsnYsxF4 and /tmp/cvslskPtk differ |
From: Michael L. <he...@us...> - 2009-06-25 20:29:32
|
Update of /cvsroot/bprocessor/bprocessor/src/etc/obj In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16349/src/etc/obj Log Message: Directory /cvsroot/bprocessor/bprocessor/src/etc/obj added to the repository |
From: Michael L. <he...@us...> - 2009-06-25 20:29:25
|
Update of /cvsroot/bprocessor/bprocessor/src/etc/obj/kirkland In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16349/src/etc/obj/kirkland Log Message: Directory /cvsroot/bprocessor/bprocessor/src/etc/obj/kirkland added to the repository |
From: Michael L. <he...@us...> - 2009-06-25 20:29:22
|
Update of /cvsroot/bprocessor/bprocessor/src/etc/obj/kohler In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv16349/src/etc/obj/kohler Log Message: Directory /cvsroot/bprocessor/bprocessor/src/etc/obj/kohler added to the repository |
From: Michael L. <he...@us...> - 2009-06-25 13:11:28
|
Update of /cvsroot/bprocessor/bprocessor/components In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv31323/components Modified Files: lib.bpl Log Message: Empty content Index: lib.bpl =================================================================== RCS file: /cvsroot/bprocessor/bprocessor/components/lib.bpl,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** lib.bpl 19 Jun 2009 13:33:07 -0000 1.4 --- lib.bpl 25 Jun 2009 13:10:27 -0000 1.5 *************** *** 1,309513 **** <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <Library> ! <libObj locked="false" author="n/a" version="n/a" name="box.obj" useableLevels="0" progid="0" id="1"> ! <space transparent="false" net="false" union="true" voidref="3" type="0" name="box.obj" progid="0" id="2"> ! <description/> ! <Classification>unassigned</Classification> ! <space transparent="true" net="false" union="false" type="1" name="Void" progid="1" id="3"> ! <description/> ! <Classification>unassigned</Classification> ! <boundary>6</boundary> [...309489 lines suppressed...] ! <vertex z="0.6044" x="0.1382248649" y="1.1778972973" progid="2407" id="51297"/> ! <vertex z="0.6044" x="0.1259848649" y="1.1728378378" progid="2408" id="51298"/> ! <vertex z="0.6044" x="0.1141543243" y="1.1670216216" progid="2409" id="51299"/> ! <vertex z="0.6044" x="0.1027894595" y="1.1604675676" progid="2410" id="51300"/> ! <vertex z="0.6044" x="0.2660256757" y="1.1670216216" progid="2411" id="51301"/> ! <vertex z="0.6044" x="0.2541951351" y="1.1728378378" progid="2412" id="51302"/> ! <vertex z="0.6044" x="0.2419551351" y="1.1778972973" progid="2413" id="51303"/> ! <vertex z="0.6044" x="0.2293640541" y="1.1821675676" progid="2414" id="51304"/> ! <vertex z="0.6044" x="0.2200151351" y="1.1846837838" progid="2415" id="51305"/> ! <vertex z="0.6044" x="0.2164818919" y="1.1856324324" progid="2416" id="51306"/> ! </space> ! </libObj> </Library> --- 1,5 ---- <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <Library> ! </Library> |
From: Michael L. <he...@us...> - 2009-06-23 12:08:48
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv32757/src/net/sourceforge/bprocessor/model Modified Files: Material.java Project.java Container.java Log Message: Saves materials when exporting to obj Index: Material.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Material.java,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** Material.java 19 Dec 2007 09:03:41 -0000 1.15 --- Material.java 23 Jun 2009 12:08:45 -0000 1.16 *************** *** 7,10 **** --- 7,12 ---- package net.sourceforge.bprocessor.model; + import java.io.OutputStream; + import java.io.PrintStream; import java.util.LinkedList; import java.util.List; *************** *** 283,285 **** --- 285,313 ---- return "[Material " + name + "]"; } + + + + /** + * + * @param out Stream + */ + public void export(OutputStream out) { + PrintStream printer = new PrintStream(out); + printer.println("newmtl " + name); + printer.println("Ka " + + ambientColor[0] + " " + + ambientColor[1] + " " + + ambientColor[2]); + printer.println("Kd " + + diffuseColor[0] + " " + + diffuseColor[1] + " " + + diffuseColor[2]); + printer.println("Ks " + + specularColor[0] + " " + + specularColor[1] + " " + + specularColor[2]); + printer.println("d " + opacity); + printer.println("Ns " + shininess); + printer.println("illum " + (int) illumination); + } } Index: Container.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Container.java,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** Container.java 29 May 2009 11:57:59 -0000 1.26 --- Container.java 23 Jun 2009 12:08:45 -0000 1.27 *************** *** 54,61 **** /** * ! * @param surfaces list of surfaces to export * @param out PrintStream to export to */ ! public static void export(List<Surface> surfaces, PrintStream out) { List<Edge> edges = new LinkedList(Surface.edges(surfaces)); List<Vertex> vertices = new LinkedList(Edge.vertices(edges)); --- 54,65 ---- /** * ! * @param containers list of surfaces to export * @param out PrintStream to export to */ ! public static void export(List<Container> containers, PrintStream out) { ! List<Surface> surfaces = new LinkedList(); ! for (Container container : containers) { ! surfaces.addAll(container.getSurfaces()); ! } List<Edge> edges = new LinkedList(Surface.edges(surfaces)); List<Vertex> vertices = new LinkedList(Edge.vertices(edges)); *************** *** 68,79 **** " " + current.getY() + " " + current.getZ()); } ! for (Surface current : surfaces) { ! List<Vertex> verts = current.getVertices(); ! out.print("f"); ! for (Vertex v : verts) { ! int i = vmap.get(v); ! out.print(" " + i); } - out.println(); } } --- 72,88 ---- " " + current.getY() + " " + current.getZ()); } ! for (Container container : containers) { ! if (container.getMaterial() != null) { ! out.println("usemtl " + container.getMaterial().getName()); ! } ! for (Surface current : container.getSurfaces()) { ! List<Vertex> verts = current.getVertices(); ! out.print("f"); ! for (Vertex v : verts) { ! int i = vmap.get(v); ! out.print(" " + i); ! } ! out.println(); } } } *************** *** 1649,1654 **** */ public void export(PrintStream out) { ! List<Surface> surfaces = new LinkedList(getSurfaces()); ! export(surfaces, out); } } --- 1658,1664 ---- */ public void export(PrintStream out) { ! List<Container> containers = new LinkedList(); ! containers.add(this); ! export(containers, out); } } Index: Project.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Project.java,v retrieving revision 1.176 retrieving revision 1.177 diff -C2 -d -r1.176 -r1.177 *** Project.java 19 May 2009 10:33:45 -0000 1.176 --- Project.java 23 Jun 2009 12:08:45 -0000 1.177 *************** *** 1612,1622 **** } } ! List<Surface> surfaces = new LinkedList(); for (Container current : constructs) { System.out.println("-- " + current.getName() + " --"); Container tesselation = current.tesselate(); ! surfaces.addAll(tesselation.getSurfaces()); } ! Container.export(surfaces, printer); } --- 1612,1623 ---- } } ! List<Container> containers = new LinkedList(); for (Container current : constructs) { System.out.println("-- " + current.getName() + " --"); Container tesselation = current.tesselate(); ! tesselation.setMaterial(current.getMaterial()); ! containers.add(tesselation); } ! Container.export(containers, printer); } *************** *** 1625,1639 **** */ public void export() { ! System.out.println("export to " + getExportPath()); try { ! OutputStream out = new FileOutputStream(new File(getExportPath())); ! exportOBJ(out); ! out.close(); } catch (FileNotFoundException e) { // TODO Auto-generated catch block ! System.out.println("cannot export to " + getExportPath()); } catch (IOException e) { // TODO Auto-generated catch block ! System.out.println("cannot export to " + getExportPath()); } isExporting = false; --- 1626,1653 ---- */ public void export() { ! System.out.println("export to " + getExportPath() + ".obj"); ! String objname = getExportPath() + ".obj"; ! String mtlname = getExportPath() + ".mtl"; try { ! { ! OutputStream out = new FileOutputStream(new File(mtlname)); ! for (Material current : getMaterials()) { ! current.export(out); ! } ! out.close(); ! } ! { ! OutputStream out = new FileOutputStream(new File(objname)); ! PrintStream printer = new PrintStream(out); ! printer.println("mtllib " + mtlname); ! exportOBJ(out); ! out.close(); ! } } catch (FileNotFoundException e) { // TODO Auto-generated catch block ! System.out.println("cannot export to " + objname); } catch (IOException e) { // TODO Auto-generated catch block ! System.out.println("cannot export to " + objname); } isExporting = false; |
From: Michael L. <he...@us...> - 2009-06-22 14:08:41
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv15328/src/net/sourceforge/bprocessor/gl/view Modified Files: Display.java Log Message: Material fixes Index: Display.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view/Display.java,v retrieving revision 1.92 retrieving revision 1.93 diff -C2 -d -r1.92 -r1.93 *** Display.java 29 May 2009 11:57:18 -0000 1.92 --- Display.java 22 Jun 2009 13:30:19 -0000 1.93 *************** *** 525,529 **** Vertex n = current.normal(); gl.glNormal3d(n.getX(), n.getY(), n.getZ()); ! float[] color = frontColor(current); if (!transparent(current)) { paint(current, color, 1.0f, false); --- 525,529 ---- Vertex n = current.normal(); gl.glNormal3d(n.getX(), n.getY(), n.getZ()); ! float[] color = backColor(current); if (!transparent(current)) { paint(current, color, 1.0f, false); *************** *** 535,539 **** Vertex n = current.normal(); gl.glNormal3d(-n.getX(), -n.getY(), -n.getZ()); ! float[] color = backColor(current); if (!transparent(current)) { paint(current, color, 1.0f, true); --- 535,539 ---- Vertex n = current.normal(); gl.glNormal3d(-n.getX(), -n.getY(), -n.getZ()); ! float[] color = frontColor(current); if (!transparent(current)) { paint(current, color, 1.0f, true); |
From: Michael L. <he...@us...> - 2009-06-22 14:08:35
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv5822/src/net/sourceforge/bprocessor/model Modified Files: Plane.java Persistence.java Log Message: Saving material for spaces Index: Persistence.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Persistence.java,v retrieving revision 1.77 retrieving revision 1.78 diff -C2 -d -r1.77 -r1.78 *** Persistence.java 11 Jun 2009 12:42:15 -0000 1.77 --- Persistence.java 22 Jun 2009 12:39:16 -0000 1.78 *************** *** 792,795 **** --- 792,796 ---- private static void internalizeReferences(Container object, SpaceType xml, Map map) { object.setEnvelope(asSet(xml.getBoundary(), map)); + object.setMaterial((Material) get(xml.getInsideMaterial(), map)); { Modellor m = internalizeModellor(xml.getModellor(), map); *************** *** 1436,1439 **** --- 1437,1443 ---- xml.setVoidref(id(map, object.getEmpty())); } + if (object.getMaterial() != null) { + xml.setInsideMaterial(id(map, object.getMaterial())); + } xml.getBoundary().addAll(ids(map, sorted(object.getEnvelope()))); } Index: Plane.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Plane.java,v retrieving revision 1.41 retrieving revision 1.42 diff -C2 -d -r1.41 -r1.42 *** Plane.java 3 Nov 2008 14:26:18 -0000 1.41 --- Plane.java 22 Jun 2009 12:39:16 -0000 1.42 *************** *** 266,269 **** --- 266,272 ---- private void copyPlanarEdges() { for (Edge current : input.edges()) { + if (current == null) { + System.out.println("BANG!"); + } if (contains(current)) { Edge edge = (Edge) current.copy(map); |
From: Michael L. <he...@us...> - 2009-06-22 14:07:35
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv15352/src/net/sourceforge/bprocessor/model Modified Files: Defaults.java Log Message: Material fixes Index: Defaults.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Defaults.java,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Defaults.java 23 Oct 2008 05:35:36 -0000 1.5 --- Defaults.java 22 Jun 2009 13:30:23 -0000 1.6 *************** *** 14,22 **** private static Material functionalMaterial ! = new Material("Functional", new float[] {0.96f, 0.87f, 0.70f}); private static Material voidMaterial = new Material("Void", new float[] {255f / 280, 228f / 280, 225f / 280}); private static Material constructionMaterial ! = new Material("Construction", new float[] {0.90f, 0.90f, 0.90f}); --- 14,22 ---- private static Material functionalMaterial ! = new Material("Functional", new float[] {0.90f, 0.90f, 0.90f}); private static Material voidMaterial = new Material("Void", new float[] {255f / 280, 228f / 280, 225f / 280}); private static Material constructionMaterial ! = new Material("Construction", new float[] {0.96f, 0.87f, 0.70f}); |
From: Michael L. <he...@us...> - 2009-06-22 14:07:33
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv5810/src/net/sourceforge/bprocessor/gl/tool Modified Files: SpaceSelectTool.java Log Message: Saving material for spaces Index: SpaceSelectTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/SpaceSelectTool.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** SpaceSelectTool.java 19 Jun 2009 13:32:29 -0000 1.1 --- SpaceSelectTool.java 22 Jun 2009 12:39:12 -0000 1.2 *************** *** 41,44 **** --- 41,50 ---- } + /** + * {@inheritDoc} + */ + public void prepare() { + Selection.primary().clear(); + } /** *************** *** 59,62 **** --- 65,70 ---- Selection.primary().set(back); } + } else { + Selection.primary().clear(); } } |
From: Michael L. <he...@us...> - 2009-06-22 14:07:30
|
Update of /cvsroot/bprocessor/model/src/etc In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv5822/src/etc Modified Files: bprocessor.xsd Log Message: Saving material for spaces Index: bprocessor.xsd =================================================================== RCS file: /cvsroot/bprocessor/model/src/etc/bprocessor.xsd,v retrieving revision 1.43 retrieving revision 1.44 diff -C2 -d -r1.43 -r1.44 *** bprocessor.xsd 19 May 2009 10:33:45 -0000 1.43 --- bprocessor.xsd 22 Jun 2009 12:39:16 -0000 1.44 *************** *** 103,106 **** --- 103,107 ---- <xsd:attribute name="union" type="xsd:boolean" use="optional"/> <xsd:attribute name="net" type="xsd:boolean" use="optional"/> + <xsd:attribute name="insideMaterial" type="xsd:long" use="optional"/> </xsd:extension> </xsd:complexContent> |
From: Michael L. <he...@us...> - 2009-06-22 09:22:25
|
Update of /cvsroot/bprocessor/bprocessor In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv9996 Added Files: b-processor.launch Log Message: launch config --- NEW FILE: b-processor.launch --- <?xml version="1.0" encoding="UTF-8"?> <launchConfiguration type="org.eclipse.jdt.launching.localJavaApplication"> <stringAttribute key="bad_container_name" value="/bprocessor/s"/> <listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS"> <listEntry value="/bprocessor/src/net/sourceforge/bprocessor/Application.java"/> </listAttribute> <listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES"> <listEntry value="1"/> </listAttribute> <stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="net.sourceforge.bprocessor.Application"/> <stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="${workspace_loc:kernel}/src/etc/log4j.properties"/> <stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="bprocessor"/> <stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-Djava.library.path="${workspace_loc:tools}/jogl/macosx" -Dapple.laf.useScreenMenuBar=true -Dcom.apple.mrj.application.apple.menu.about.name=B-Processor"/> </launchConfiguration> |
From: Michael L. <he...@us...> - 2009-06-19 14:53:54
|
Update of /cvsroot/bprocessor/bprocessor/components In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv4468/components Modified Files: lib.bpl Log Message: new space-select tool Index: lib.bpl =================================================================== RCS file: /cvsroot/bprocessor/bprocessor/components/lib.bpl,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** lib.bpl 16 Apr 2009 11:11:59 -0000 1.3 --- lib.bpl 19 Jun 2009 13:33:07 -0000 1.4 *************** *** 1,9 **** <?xml version="1.0" encoding="UTF-8" standalone="yes"?> <Library> ! <libObj useableLevels="0" author="n/a" locked="false" version="n/a" name="box.obj" progid="0" id="1"> ! <space net="false" type="0" name="box.obj" union="true" transparent="false" voidref="3" progid="0" id="2"> <description/> <Classification>unassigned</Classification> ! <space net="false" type="1" name="Void" union="false" transparent="true" progid="1" id="3"> <description/> <Classification>unassigned</Classification> --- 1,9 ---- [...261201 lines suppressed...] ! <vertex z="0.6010216216" x="0.19009" y="1.198427027" progid="2399" id="51289"/> ! <vertex z="0.6044" x="0.19009" y="1.1900837838" progid="2400" id="51290"/> ! <vertex z="0.6044" x="0.2033697297" y="1.1882756757" progid="2401" id="51291"/> ! <vertex z="0.5875081081" x="0.19009" y="1.198427027" progid="2402" id="51292"/> ! <vertex z="0.6044" x="0.1768102703" y="1.1882756757" progid="2403" id="51293"/> ! <vertex z="0.6044" x="0.1636981081" y="1.1856324324" progid="2404" id="51294"/> ! <vertex z="0.6044" x="0.1601645946" y="1.1846837838" progid="2405" id="51295"/> ! <vertex z="0.6044" x="0.1508159459" y="1.1821675676" progid="2406" id="51296"/> ! <vertex z="0.6044" x="0.1382248649" y="1.1778972973" progid="2407" id="51297"/> ! <vertex z="0.6044" x="0.1259848649" y="1.1728378378" progid="2408" id="51298"/> ! <vertex z="0.6044" x="0.1141543243" y="1.1670216216" progid="2409" id="51299"/> ! <vertex z="0.6044" x="0.1027894595" y="1.1604675676" progid="2410" id="51300"/> ! <vertex z="0.6044" x="0.2660256757" y="1.1670216216" progid="2411" id="51301"/> ! <vertex z="0.6044" x="0.2541951351" y="1.1728378378" progid="2412" id="51302"/> ! <vertex z="0.6044" x="0.2419551351" y="1.1778972973" progid="2413" id="51303"/> ! <vertex z="0.6044" x="0.2293640541" y="1.1821675676" progid="2414" id="51304"/> ! <vertex z="0.6044" x="0.2200151351" y="1.1846837838" progid="2415" id="51305"/> ! <vertex z="0.6044" x="0.2164818919" y="1.1856324324" progid="2416" id="51306"/> </space> </libObj> |
From: Michael L. <he...@us...> - 2009-06-19 14:53:38
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv4407/src/net/sourceforge/bprocessor/gl/view Modified Files: View.java PopupMenu.java Log Message: new space-select tool Index: PopupMenu.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view/PopupMenu.java,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** PopupMenu.java 21 Apr 2009 10:21:18 -0000 1.29 --- PopupMenu.java 19 Jun 2009 13:32:29 -0000 1.30 *************** *** 836,839 **** --- 836,848 ---- } { + AbstractAction action = new AbstractAction("Mark...") { + public void actionPerformed(ActionEvent event) { + Command command = new Command.Mark(); + AttributeView.instance().display(command); + } + }; + menu.add(action); + } + { AbstractAction action = new AbstractAction("Bounding Sphere") { private Container circle(Vertex i, Vertex j, Vertex origin, double radius) { Index: View.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view/View.java,v retrieving revision 1.288 retrieving revision 1.289 diff -C2 -d -r1.288 -r1.289 *** View.java 25 May 2009 12:00:40 -0000 1.288 --- View.java 19 Jun 2009 13:32:29 -0000 1.289 *************** *** 9,12 **** --- 9,13 ---- import net.sourceforge.bprocessor.gl.Editor; import net.sourceforge.bprocessor.gl.tool.SelectTool; + import net.sourceforge.bprocessor.gl.tool.SpaceSelectTool; import net.sourceforge.bprocessor.gl.tool.SpaceTool; import net.sourceforge.bprocessor.gl.model.EdgeAttributes; *************** *** 29,32 **** --- 30,34 ---- import net.sourceforge.bprocessor.model.Selection; import net.sourceforge.bprocessor.model.Container; + import net.sourceforge.bprocessor.model.Space; import net.sourceforge.bprocessor.model.Vertex; import net.sourceforge.bprocessor.model.Surface; *************** *** 43,46 **** --- 45,51 ---- import java.awt.Toolkit; + import java.io.BufferedReader; + import java.io.IOException; + import java.io.StringReader; import java.nio.IntBuffer; *************** *** 750,753 **** --- 755,762 ---- drawSelectionWidget((Surface) candidate, hitdetection); } + } else if (candidate instanceof Space) { + if (editor.getTool() instanceof SpaceSelectTool) { + drawSpeechBubble((Space) candidate, hitdetection); + } } } *************** *** 1129,1133 **** Display.paint(mid, new float[]{0, 0, 0}, 5); ! if (clickable) { --- 1138,1142 ---- Display.paint(mid, new float[]{0, 0, 0}, 5); ! if (clickable) { *************** *** 1170,1177 **** drawString(backTextAnchor.getX(), backTextAnchor.getY(), ! backTextAnchor.getZ(), backName); } } /** * Put labels on a Surface --- 1179,1252 ---- drawString(backTextAnchor.getX(), backTextAnchor.getY(), ! backTextAnchor.getZ(), backName); } } + private void drawSpeechBubble(Space space, boolean clickable) { + Transformation transformation = transformation(); + double width = 240; + double height = 180; + double delta = 10; + + Vertex from = space.center(); + Vertex front = transformation.project(from); + Vertex a = front.add(new Vertex(delta, 2 * delta, 0)); + Vertex b = front.add(new Vertex(3 * delta, 2 * delta, 0)); + Vertex c = a.add(new Vertex(0, height, 0)); + Vertex d = c.add(new Vertex(width, 0, 0)); + Vertex e = a.add(new Vertex(width, 0, 0)); + + front.setZ(1); + gl.glColor4d(0.94f, 0.97f, 1, 0.9); + + gl.glBegin(GL.GL_POLYGON); + gl.glVertex3d(a.getX(), a.getY(), a.getZ()); + gl.glVertex3d(front.getX(), front.getY(), front.getZ()); + gl.glVertex3d(b.getX(), b.getY(), b.getZ()); + gl.glEnd(); + + gl.glBegin(GL.GL_POLYGON); + gl.glVertex3d(a.getX(), a.getY(), a.getZ()); + gl.glVertex3d(c.getX(), c.getY(), c.getZ()); + gl.glVertex3d(d.getX(), d.getY(), d.getZ()); + gl.glVertex3d(e.getX(), e.getY(), e.getZ()); + gl.glEnd(); + + gl.glColor3d(0.1, 0.1, 0.1); + gl.glLineWidth(0.5f); + gl.glBegin(GL.GL_LINES); + gl.glVertex3d(a.getX(), a.getY(), a.getZ()); + gl.glVertex3d(front.getX(), front.getY(), front.getZ()); + gl.glVertex3d(front.getX(), front.getY(), front.getZ()); + gl.glVertex3d(b.getX(), b.getY(), b.getZ()); + gl.glVertex3d(b.getX(), b.getY(), b.getZ()); + gl.glVertex3d(e.getX(), e.getY(), e.getZ()); + gl.glVertex3d(e.getX(), e.getY(), e.getZ()); + gl.glVertex3d(d.getX(), d.getY(), d.getZ()); + gl.glVertex3d(d.getX(), d.getY(), d.getZ()); + gl.glVertex3d(c.getX(), c.getY(), c.getZ()); + gl.glVertex3d(c.getX(), c.getY(), c.getZ()); + gl.glVertex3d(a.getX(), a.getY(), a.getZ()); + gl.glEnd(); + + String text = space.getDescription().toString(); + BufferedReader reader = new BufferedReader(new StringReader(text)); + String line; + try { + line = reader.readLine(); + double x = c.getX() + 5; + double y = c.getY() - 5 - 14; + double z = c.getZ(); + while (line != null) { + drawString(x, y, z, line); + line = reader.readLine(); + y -= 14; + } + } catch (IOException e1) { + // empty + } + + } + /** * Put labels on a Surface *************** *** 1209,1220 **** if (!facingFront(surface)) { frontTextAnchor = new Vertex(front.getX() - (frontWidth / 2), ! front.getY() - 17, front.getZ()); backTextAnchor = new Vertex(front.getX() - (backWidth / 2), ! front.getY() + 7, front.getZ()); } else { frontTextAnchor = new Vertex(front.getX() - (frontWidth / 2), ! front.getY() + 7, front.getZ()); backTextAnchor = new Vertex(front.getX() - (backWidth / 2), ! front.getY() - 17, front.getZ()); } --- 1284,1295 ---- if (!facingFront(surface)) { frontTextAnchor = new Vertex(front.getX() - (frontWidth / 2), ! front.getY() - 17, front.getZ()); backTextAnchor = new Vertex(front.getX() - (backWidth / 2), ! front.getY() + 7, front.getZ()); } else { frontTextAnchor = new Vertex(front.getX() - (frontWidth / 2), ! front.getY() + 7, front.getZ()); backTextAnchor = new Vertex(front.getX() - (backWidth / 2), ! front.getY() - 17, front.getZ()); } *************** *** 1222,1229 **** //Name must be "front" drawClickBox(frontTextAnchor.getX(), frontTextAnchor.getY(), ! frontTextAnchor.getZ(), frontWidth, 10, "front"); //Name must be "back" drawClickBox(backTextAnchor.getX(), backTextAnchor.getY(), ! backTextAnchor.getZ(), backWidth, 10, "back"); //Name must be "bar" pushName(gl, "bar"); --- 1297,1304 ---- //Name must be "front" drawClickBox(frontTextAnchor.getX(), frontTextAnchor.getY(), ! frontTextAnchor.getZ(), frontWidth, 10, "front"); //Name must be "back" drawClickBox(backTextAnchor.getX(), backTextAnchor.getY(), ! backTextAnchor.getZ(), backWidth, 10, "back"); //Name must be "bar" pushName(gl, "bar"); |
From: Michael L. <he...@us...> - 2009-06-19 14:53:37
|
Update of /cvsroot/bprocessor/gl/src/gfx In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv4407/src/gfx Added Files: Biconselecttool2.gif Log Message: new space-select tool --- NEW FILE: Biconselecttool2.gif --- (This appears to be a binary file; contents omitted.) |
From: Michael L. <he...@us...> - 2009-06-19 14:53:36
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv4407/src/net/sourceforge/bprocessor/gl/tool Modified Files: Tool.java ToolFactory.java Added Files: SpaceSelectTool.java Log Message: new space-select tool Index: ToolFactory.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/ToolFactory.java,v retrieving revision 1.104 retrieving revision 1.105 diff -C2 -d -r1.104 -r1.105 *** ToolFactory.java 5 Feb 2008 13:34:32 -0000 1.104 --- ToolFactory.java 19 Jun 2009 13:32:29 -0000 1.105 *************** *** 65,68 **** --- 65,69 ---- private AbstractTool select; private AbstractTool assign; + private AbstractTool spaceselect; private Pencil pencil; *************** *** 132,135 **** --- 133,137 ---- select = new SelectTool(editor, null); assign = new SpaceTool(editor, null); + spaceselect = new SpaceSelectTool(editor, null); pencil = new Pencil(editor, pencilcursor); eraser = new EraserTool(editor, pencilcursor); *************** *** 152,155 **** --- 154,158 ---- Toolbar tb = Toolbar.getInstance(); + registerTool(Tool.SPACE_SELECT, spaceselect, "Biconselecttool2.gif", "Sensor Select"); registerTool(Tool.SELECT_TOOL, select, "Biconselecttool.gif", "Select"); registerTool(Tool.ASSIGN_TOOL, assign, "assign-icon-3.png", "Assign"); Index: Tool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/Tool.java,v retrieving revision 1.41 retrieving revision 1.42 diff -C2 -d -r1.41 -r1.42 *** Tool.java 3 Dec 2007 17:29:48 -0000 1.41 --- Tool.java 19 Jun 2009 13:32:29 -0000 1.42 *************** *** 80,83 **** --- 80,86 ---- public static final int ASSIGN_TOOL = 27; + /** the zoom tool */ + public static final int SPACE_SELECT = 28; + /** * Return the current selection --- NEW FILE: SpaceSelectTool.java --- //--------------------------------------------------------------------------------- // $Id: SpaceSelectTool.java,v 1.1 2009/06/19 13:32:29 henryml Exp $ // // Copyright (c) 2005 The BProcessor Team (http://bprocessor.sourceforge.net) // Released under the Lesser GNU Public License v2.1 //--------------------------------------------------------------------------------- package net.sourceforge.bprocessor.gl.tool; import net.sourceforge.bprocessor.gl.Editor; import net.sourceforge.bprocessor.gui.GUI; import net.sourceforge.bprocessor.model.Geometric; import net.sourceforge.bprocessor.model.Selection; import net.sourceforge.bprocessor.model.Space; import net.sourceforge.bprocessor.model.Surface; import java.awt.Cursor; import java.awt.event.MouseEvent; import java.util.LinkedList; import javax.swing.JPopupMenu; /** * The Space Select Tool */ public class SpaceSelectTool extends AbstractTool { /** * The constructor * @param editor The 3D canvas * @param cursor The cursor */ public SpaceSelectTool(Editor editor, Cursor cursor) { super(editor, cursor); } /** * Invoked when the mouse cursor has been moved * @param e The MouseEvent object */ protected void moved(MouseEvent e) { } /** * Invoked when a mouse button has been pressed on a component. * @param e The MouseEvent object */ protected void pressed(MouseEvent e) { boolean done = false; if (e.getButton() == MouseEvent.BUTTON1) { findTarget(e); if (target instanceof Surface) { Surface surface = (Surface) target; Space front = surface.getFrontDomain(); Space back = surface.getBackDomain(); if (front.isConstructionSpace()) { Selection.primary().set(front); } else if (back.isConstructionSpace()) { Selection.primary().set(back); } } } } /** * Invoked when the mouse is held pressed and moved * @param e The MouseEvent object */ protected void dragged(MouseEvent e) { if ((e.getModifiersEx() & MouseEvent.BUTTON1_DOWN_MASK) == MouseEvent.BUTTON1_DOWN_MASK) { // Empty if block } } /** * Invoked when a mouse button has been released on a component. * @param e The MouseEvent */ protected void released(MouseEvent e) { if (e.getButton() == MouseEvent.BUTTON1) { // Empty if block } } /** * {@inheritDoc} */ public String initialTip() { return "Click objects to select." + " Hold shift to add to selection." + " Drag to multi-select."; } /** * {@inheritDoc} */ public void handleMenu(MouseEvent event) { Selection selection = Selection.primary(); JPopupMenu menu = null; if (target == null) { selection.clear(); menu = GUI.getInstance().menuFactory().menuFor(new LinkedList<Geometric>()); } else { if (target instanceof Geometric) { if (!selection.contains(target)) { selection.set((Geometric) target); } menu = GUI.getInstance().menuFactory().menuFor(selection); } } if (menu != null && menu.getComponentCount() > 0) { editor.popup(menu, event.getX(), event.getY()); } } } |
From: Michael L. <he...@us...> - 2009-06-19 14:53:35
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv4356/src/net/sourceforge/bprocessor/model Modified Files: Command.java Log Message: new space-select tool Index: Command.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Command.java,v retrieving revision 1.76 retrieving revision 1.77 diff -C2 -d -r1.76 -r1.77 *** Command.java 3 Nov 2008 14:26:18 -0000 1.76 --- Command.java 19 Jun 2009 13:32:25 -0000 1.77 *************** *** 30,34 **** parameters = new ParameterBlock(); } ! /** {@inheritDoc} */ public List<Attribute> getAttributes() { --- 30,34 ---- parameters = new ParameterBlock(); } ! /** {@inheritDoc} */ [...3160 lines suppressed...] center.x = (xmin.x + xmax.x) / 2; --- 3019,3023 ---- v2 = zmax; } ! center = v1.add(v2).scale(0.5); center.x = (xmin.x + xmax.x) / 2; *************** *** 2935,2939 **** center.z = (zmin.z + zmax.z) / 2; radius = dia / 2; ! for (Vertex current : vertices) { Vertex d = current.minus(center); --- 3025,3029 ---- center.z = (zmin.z + zmax.z) / 2; radius = dia / 2; ! for (Vertex current : vertices) { Vertex d = current.minus(center); |
From: Michael L. <he...@us...> - 2009-06-19 14:53:31
|
Update of /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/actions In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv4449/src/net/sourceforge/bprocessor/gui/actions Modified Files: ImportFileReader.java FileImportActionListener.java Log Message: new space-select tool Index: FileImportActionListener.java =================================================================== RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/actions/FileImportActionListener.java,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** FileImportActionListener.java 3 Nov 2008 14:26:21 -0000 1.23 --- FileImportActionListener.java 19 Jun 2009 13:32:32 -0000 1.24 *************** *** 26,30 **** import net.sourceforge.bprocessor.gui.GUI; - import net.sourceforge.bprocessor.model.Component; import net.sourceforge.bprocessor.model.Project; import net.sourceforge.bprocessor.model.Container; --- 26,29 ---- *************** *** 123,131 **** try { Container s = Space.createUnion(lfile.getName()); ! Component lo = new Component(Byte.MAX_VALUE, lfile, s); ImportFileReader.importObjFile(lfile, s, info.objPanel.getScale(), info.objPanel.getDirection(), info.objPanel.getCalcNormals()); //s.computeEnvelope(); ! Project.getInstance().addLibraryObject(lo); Project.getInstance().changed(s); Project.getInstance().checkpoint(); --- 122,131 ---- try { Container s = Space.createUnion(lfile.getName()); ! //Component lo = new Component(Byte.MAX_VALUE, lfile, s); ImportFileReader.importObjFile(lfile, s, info.objPanel.getScale(), info.objPanel.getDirection(), info.objPanel.getCalcNormals()); + Project.getInstance().getActiveSpace().add(s); //s.computeEnvelope(); ! //Project.getInstance().addLibraryObject(lo); Project.getInstance().changed(s); Project.getInstance().checkpoint(); Index: ImportFileReader.java =================================================================== RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/actions/ImportFileReader.java,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** ImportFileReader.java 3 Nov 2008 13:14:12 -0000 1.19 --- ImportFileReader.java 19 Jun 2009 13:32:32 -0000 1.20 *************** *** 175,179 **** surfaces.add(s); if (currentMaterial == null) { ! currentMaterial = new Material("Object", new float[]{0f, 0.9f, 0f}); materialMap.put("default", currentMaterial); } --- 175,179 ---- surfaces.add(s); if (currentMaterial == null) { ! currentMaterial = new Material("Object", new float[]{0.9f, 0.9f, 0.9f}); materialMap.put("default", currentMaterial); } |
From: Michael L. <he...@us...> - 2009-06-11 14:53:41
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv23772/src/net/sourceforge/bprocessor/model Modified Files: Persistence.java Log Message: Fixed bug externalizing grid Index: Persistence.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Persistence.java,v retrieving revision 1.76 retrieving revision 1.77 diff -C2 -d -r1.76 -r1.77 *** Persistence.java 19 May 2009 10:33:45 -0000 1.76 --- Persistence.java 11 Jun 2009 12:42:15 -0000 1.77 *************** *** 1246,1249 **** --- 1246,1250 ---- xml.setId(counter++); + xml.setEditable(true); xml.setProgid(grid.getId()); xml.setActive(grid.isActive()); |
From: Michael L. <he...@us...> - 2009-05-29 11:58:04
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv20678/src/net/sourceforge/bprocessor/model Modified Files: Container.java Log Message: Grid bugfix Index: Container.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Container.java,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -d -r1.25 -r1.26 *** Container.java 15 May 2009 11:17:48 -0000 1.25 --- Container.java 29 May 2009 11:57:59 -0000 1.26 *************** *** 497,500 **** --- 497,513 ---- /** + * + * @return Grid + */ + public Grid getGrid() { + for (Constructor current : getConstructors()) { + if (current instanceof Grid) { + return (Grid) current; + } + } + return null; + } + + /** * Answer with a collection of coordinatesystems in this space * @return collection of coordinatesystems |