diff options
author | Sven Gothel <[email protected]> | 2013-09-20 11:37:38 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2013-09-20 11:37:38 +0200 |
commit | 51df3f354a700454498371c0565bfcd6c0d3bf5f (patch) | |
tree | 9492a71383c2cbe83c410e0a2474cbe68dd98580 /src/jogl/classes/jogamp/opengl/GLStateTracker.java | |
parent | b1db882abfe6166abb5f06df8ff2d386e5f8f842 (diff) |
Bug 839: Clarifying GLStateTracker.clearStates(..) remove 'enable' change - Part 1
TODO: Only disable state tracker at GLContext.destroy()
Diffstat (limited to 'src/jogl/classes/jogamp/opengl/GLStateTracker.java')
-rw-r--r-- | src/jogl/classes/jogamp/opengl/GLStateTracker.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/jogl/classes/jogamp/opengl/GLStateTracker.java b/src/jogl/classes/jogamp/opengl/GLStateTracker.java index 391f96aed..69411979f 100644 --- a/src/jogl/classes/jogamp/opengl/GLStateTracker.java +++ b/src/jogl/classes/jogamp/opengl/GLStateTracker.java @@ -40,6 +40,7 @@ package jogamp.opengl; import javax.media.opengl.*; + import com.jogamp.common.util.IntIntHashMap; import java.nio.IntBuffer; import java.util.ArrayList; @@ -95,8 +96,7 @@ public class GLStateTracker { stack = new ArrayList<SavedState>(MIN_CLIENT_ATTRIB_STACK_DEPTH); } - public final void clearStates(boolean enable) { - enabled = enable; + public final void clearStates() { pixelStateMap.clear(); } @@ -112,7 +112,7 @@ public class GLStateTracker { * which forces the caller to query GL. */ public final boolean getInt(int pname, int[] params, int params_offset) { if(enabled) { - int value = pixelStateMap.get(pname); + final int value = pixelStateMap.get(pname); if(0xFFFFFFFF != value) { params[params_offset] = value; return true; @@ -125,7 +125,7 @@ public class GLStateTracker { * which forces the caller to query GL. */ public final boolean getInt(int pname, IntBuffer params, int dummy) { if(enabled) { - int value = pixelStateMap.get(pname); + final int value = pixelStateMap.get(pname); if(0xFFFFFFFF != value) { params.put(params.position(), value); return true; |