From 668eaf9cfb060f9fdbaf31aba6f0ac46664b7e38 Mon Sep 17 00:00:00 2001 From: "bre..ns" Date: Fri, 8 Jul 2011 00:11:44 +0000 Subject: [PATCH] changed TerrainGrid methods to protected access git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7842 75d07b2b-3a1a-0410-a2c5-0572b91ccdca --- .../jme3/terrain/geomipmap/TerrainGrid.java | 37 +++++++++---------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/engine/src/terrain/com/jme3/terrain/geomipmap/TerrainGrid.java b/engine/src/terrain/com/jme3/terrain/geomipmap/TerrainGrid.java index 7c647e991..db6d6c508 100644 --- a/engine/src/terrain/com/jme3/terrain/geomipmap/TerrainGrid.java +++ b/engine/src/terrain/com/jme3/terrain/geomipmap/TerrainGrid.java @@ -56,22 +56,21 @@ import java.util.concurrent.Callable; */ public class TerrainGrid extends TerrainQuad { - private static final Logger log = Logger.getLogger(TerrainGrid.class.getCanonicalName()); - private Vector3f currentCell; - private int quarterSize; - private int quadSize; - private HeightMapGrid heightMapGrid; - //private Vector3f[] quadOrigins; - private Vector3f[] quadIndex; - private Map listeners = new HashMap(); - private Material material; - private LRUCache cache = new LRUCache(16); - private RigidBodyControl[] quadControls; - private PhysicsSpace space; - - private class UpdateQuadCache implements Runnable { - - private final Vector3f location; + protected static final Logger log = Logger.getLogger(TerrainGrid.class.getCanonicalName()); + protected Vector3f currentCell; + protected int quarterSize; + protected int quadSize; + protected HeightMapGrid heightMapGrid; + protected Vector3f[] quadIndex; + protected Map listeners = new HashMap(); + protected Material material; + protected LRUCache cache = new LRUCache(16); + protected RigidBodyControl[] quadControls; + protected PhysicsSpace space; + + protected class UpdateQuadCache implements Runnable { + + protected final Vector3f location; public UpdateQuadCache(Vector3f location) { this.location = location; @@ -116,11 +115,11 @@ public class TerrainGrid extends TerrainQuad { } } - private boolean isCenter(int quadIndex) { + protected boolean isCenter(int quadIndex) { return quadIndex == 9 || quadIndex == 5 || quadIndex == 10 || quadIndex == 6; } - private int getQuadrant(int quadIndex) { + protected int getQuadrant(int quadIndex) { if (quadIndex == 9) { return 1; } else if (quadIndex == 5) { @@ -242,7 +241,7 @@ public class TerrainGrid extends TerrainQuad { updateModelBound(); } - private void updateChildrens(Vector3f cam) { + protected void updateChildrens(Vector3f cam) { // --------------------------------------------------- // LRU cache is used, so elements that need to remain // should be touched.