Permalink
Browse files

fixes #2087

I just put isDrawingNormals to false by default and add a condition in
drawTesselatedPolygon.
  • Loading branch information...
1 parent c2e7f40 commit 4e9419c13bcafd0926eab90822d27a41b1d4b7f3 @agrignard agrignard committed Jan 10, 2017
@@ -89,7 +89,7 @@ public void notifyListeners(final Changes property, final boolean value) {
private boolean isTriangulating = false;
// private int traceSize = 0;
private boolean isZFighting = true; // GamaPreferences.CORE_Z_FIGHTING.getValue();
- private boolean isDrawingNormals = true; // GamaPreferences.CORE_DRAW_NORM.getValue();
+ private boolean isDrawingNormals = false; // GamaPreferences.CORE_DRAW_NORM.getValue();
private boolean isDisplayingAsACube = false; // GamaPreferences.CORE_CUBEDISPLAY.getValue();
private boolean ortho = false;
private boolean disableCameraInteraction = false; // "fixed_camera" facet of
@@ -145,7 +145,9 @@ public void drawTesselatedPolygon(final GL2 gl, final Polygon p, final int norm_
final GamaPoint[] vertices = getExteriorRingVertices(p);
final double[] normal = GLUtilNormal.CalculateNormal(vertices[0], vertices[1], vertices[2], norm_dir);
- GLUtilNormal.drawNormal(vertices, renderer, gl, normal);
+ if (renderer.data.isDraw_norm()){
+ GLUtilNormal.drawNormal(vertices, renderer, gl, normal);
+ }
GLU.gluTessNormal(tobj, normal[0], normal[1], normal[2]);
for (final GamaPoint pp : GeometryUtils.getCoordinates(p)) {

0 comments on commit 4e9419c

Please sign in to comment.