Package toxi.processing

Examples of toxi.processing.ToxiclibsSupport


        }
    }

    public void setup() {
        size(600, 600, OPENGL);
        gfx = new ToxiclibsSupport(this);
        poly = new Circle(200).toPolygon2D(9).translate(width / 2, height / 2);
        poly.get(0).x *= 0.66f;
    }
View Full Code Here


        }
    }

    public void setup() {
        size(400, 400);
        gfx = new ToxiclibsSupport(this);
        Ray3D r = new Ray3D(new Vec3D(), new Vec3D(1, 0, 0));
        Ray3D r2 = new Ray3D(new Vec3D(10, 10, 0), new Vec3D(1, -1, 0));
        Ray3DIntersector ri = new Ray3DIntersector(r);
        ri.intersectsRay(r2);
        println(ri.getIntersectionData());
View Full Code Here

        }
    }

    public void setup() {
        size(1024, 576, OPENGL);
        gfx = new ToxiclibsSupport(this);
        physics = new VerletPhysics3D();
        physics.setDrag(0.15f);
        physics.setWorldBounds(new AABB(new Vec3D(), 250));
        physics.addBehavior(new GravityBehavior3D(new Vec3D(0, 0.2f, 0)));
        physics.addBehavior(new AttractionBehavior3D(new Vec3D(), 500, 0.1f));
View Full Code Here

        }
    }

    public void setup() {
        size(400, 400);
        gfx = new ToxiclibsSupport(this);
        Polygon2D bounds = new Polygon2D();
        bounds.add(new Vec2D(100, 100));
        bounds.add(new Vec2D(150, 80));
        bounds.add(new Vec2D(300, 130));
        bounds.add(new Vec2D(320, 300));
View Full Code Here

    }

    public void setup() {
        size(1024, 640, OPENGL);
        frameRate(999);
        gfx = new ToxiclibsSupport(this);
        physics = new VerletPhysics2D();
        physics.setDrag(0.1f);
        physics.setWorldBounds(new Rect(0, 0, width, height));
        physics.addBehavior(new GravityBehavior2D(new Vec2D(0, 0.15f)));
        physics.setIndex(new PointQuadtree(null, 0, 0, width + 1, height + 1));
View Full Code Here

        }
    }

    public void setup() {
        size(1280, 720, OPENGL);
        gfx = new ToxiclibsSupport(this);
    }
View Full Code Here

        }
    }

    public void setup() {
        size(1280, 720, OPENGL);
        gfx = new ToxiclibsSupport(this);
        p1 = new Plane(new Vec3D(100, 100, 100), new Vec3D(0, 1, 0));
        p2 = new Plane(new Vec3D(100, 200, 100),
                new Vec3D(1, 0, 0).rotateY(0.5f));
        p2.normal = p1.normal.copy();
    }
View Full Code Here

        }
    }

    public void setup() {
        size(1280, 720, OPENGL);
        gfx = new ToxiclibsSupport(this);
        tree = new PointQuadtree(null, 0, 0, width, height);
        for (int i = 0; i < 5000; i++) {
            tree.index(new Vec2D(random(width), random(height)));
        }
    }
View Full Code Here

TOP

Related Classes of toxi.processing.ToxiclibsSupport

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.