X-Git-Url: http://www2.svjatoslav.eu/gitweb/?p=sixth-3d-demos.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Feu%2Fsvjatoslav%2Fsixth%2Fe3d%2Fexamples%2FRandomPolygonsDemo.java;h=82210b0d07ea8a53c0fcccea5440c2fab5c49b4c;hp=24d0d2f674fac1bfbff540b6a172fa515b67b588;hb=63b799f7add2ebb5cd30b50c2581bc246f6e7b82;hpb=5b40e0cb6e95f119345334fd2a64d7cadc118019 diff --git a/src/main/java/eu/svjatoslav/sixth/e3d/examples/RandomPolygonsDemo.java b/src/main/java/eu/svjatoslav/sixth/e3d/examples/RandomPolygonsDemo.java index 24d0d2f..82210b0 100755 --- a/src/main/java/eu/svjatoslav/sixth/e3d/examples/RandomPolygonsDemo.java +++ b/src/main/java/eu/svjatoslav/sixth/e3d/examples/RandomPolygonsDemo.java @@ -18,8 +18,8 @@ import eu.svjatoslav.sixth.e3d.renderer.raster.shapes.composite.wireframe.Grid3D public class RandomPolygonsDemo { - public static final double POLYGON_AVERAGE_SIZE = 130; - public static final int POLYGON_COUNT = 10000; + private static final double POLYGON_AVERAGE_SIZE = 130; + private static final int POLYGON_COUNT = 1000; private static void addRandomPolygon(final ShapeCollection geometryCollection) { final Point3D polygonLocation = getRandomPoint(1000); @@ -45,7 +45,7 @@ public class RandomPolygonsDemo { } /* I don't want very dark polygons, so ensure there is at least some - * brightness present. */ + * brightness present. */ private static double getColorChannelBrightness() { return Math.random() * 0.7 + 0.3f; } @@ -61,8 +61,8 @@ public class RandomPolygonsDemo { final ViewFrame viewFrame = new ViewFrame(); - final ShapeCollection shapeCollection = viewFrame.getView() - .getContext().getRootShapeCollection(); + final ShapeCollection shapeCollection = viewFrame.getViewPanel() + .getRootShapeCollection(); // add grid final LineAppearance appearance = new LineAppearance(5, new Color(100,