checkpoint
[anneal.git] / src / edu / berkeley / qfat / InteractiveMeshViewer.java
index 1a72d7e..ed23803 100644 (file)
@@ -13,7 +13,26 @@ import edu.berkeley.qfat.geom.Point;
 
 public class InteractiveMeshViewer extends MeshViewer {
 
-    public InteractiveMeshViewer(JFrame f) { super(f); }
+    public Mesh tile;
+    public Mesh goal;
+    public InteractiveMeshViewer(JFrame f) {
+        super(f);
+        setTile(new Mesh(false));
+        setGoal(new Mesh(false));
+    }
+
+    public void setTile(Mesh tile) {
+        removeMesh(this.tile);
+        this.tile = tile;
+        addMesh(this.tile);
+    }
+    public void setGoal(Mesh goal) {
+        removeMesh(this.goal);
+        this.goal = goal;
+        goal.option_selectable = false;
+        goal.option_wireframe = true;
+        addMesh(this.goal);
+    }
 
     public synchronized void dump() {
         try {
@@ -35,6 +54,26 @@ public class InteractiveMeshViewer extends MeshViewer {
         } catch (Exception e) { throw new RuntimeException(e); }
     }
 
+    public int whichNeighbor = 1;
+    public double temp;
+    public boolean tileon = true;
+    public boolean tilemeshon = false;
+    public boolean goalon = true;
+    public boolean anneal = false;
+    public boolean hillclimb = false;
+    public boolean neighbors = false;
+    public boolean neighborsWire = false;
+    public boolean neighborsWireOne = false;
+    public boolean errorNormals = false;
+
+    public boolean force = false;
+    public Mesh.Vertex[] points;
+    public int breaks = 0;
+
+    public int temps;
+    public int accepts;
+    public    int vertss;
+
     public void keyPressed(KeyEvent e)  {
         super.keyPressed(e);
         switch(e.getKeyCode()) {