Apat and added acos to spherycolor, not included in color yet but working
[SugarCubes.git] / GranimPattern.pde
old mode 100755 (executable)
new mode 100644 (file)
index 425b97c..da4c78f
@@ -27,7 +27,7 @@ class Granim extends Graphic
        {
                while(width()< g.position+1)
                {
-                               graphicBuffer.add(color(0,0,0));
+                               graphicBuffer.add(lx.hsb(0,0,0));
                }
                drawAll();
                displayList.put(name , g);
@@ -55,7 +55,7 @@ class Granim extends Graphic
                        {
                                while(width()< g.position + g.width())
                                {
-                                       graphicBuffer.add(color(0,0,0));
+                                       graphicBuffer.add(lx.hsb(0,0,0));
                                }
                                if(g.changed)
                                {
@@ -96,7 +96,7 @@ class GranimPattern extends SCPattern
                return displayList.get(name);
        }
 
-       public void run(int deltaMs) 
+       public void run(double deltaMs) 
        {
                drawToPointList();
        }
@@ -109,7 +109,7 @@ class GranimPattern extends SCPattern
                        {
                                ((Granim) g).update();
                        }
-                       List<Point> drawList = model.points.subList(Math.min(g.position,colors.length-1), Math.min(g.position + g.width(),colors.length-1));
+                       List<LXPoint> drawList = model.points.subList(Math.min(g.position,colors.length-1), Math.min(g.position + g.width(),colors.length-1));
                        //println("drawlistsize "+drawList.size());
                        
                        gbuffer = g.graphicBuffer.toArray(new Integer[0]);
@@ -141,7 +141,7 @@ class RedsGraphic extends Graphic
        {
                for(int i = 0; i < len ;i++)
                {
-                       graphicBuffer.add(color(0,255,255));
+                       graphicBuffer.add(lx.hsb(0,255,255));
                }
        }
 };
@@ -229,7 +229,7 @@ class ColorDotsGraphic extends Graphic
                super();
                for (int colorVal : colorSequence)
                {
-                       graphicBuffer.add(color(colorVal, 255, 255));
+                       graphicBuffer.add(lx.hsb(colorVal, 255, 255));
                }
                changed = true;
        }