aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoralbanc <[email protected]>2003-08-13 12:06:39 +0000
committeralbanc <[email protected]>2003-08-13 12:06:39 +0000
commitd2a6e3ac6ef57cf716212c12f13900280e5a86be (patch)
treeb3e98fb8722160bbc8cb955c50003b57e1e14143
parentc6cadbbd676b205c82c4ce1de6da37faba67dc22 (diff)
Issue number:
Obtained from: Submitted by: albanc Reviewed by: CVS: ---------------------------------------------------------------------- CVS: Issue number: CVS: If this change addresses one or more issues, CVS: added isInitialized() method for enabling querrying pBuffer initialization status CVS: Reviewed by: Posted a mail with diff() and explanations on the jogl CVS mailing list 2 days ago. Since I got no objections (nor replies) and since the addition can not affect compatibility nor stability, considering this as a yes. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@53 232f8b59-042b-4e1e-8c03-345bb8c30851
-rw-r--r--src/net/java/games/jogl/GLPbuffer.java3
-rw-r--r--src/net/java/games/jogl/impl/GLPbufferImpl.java9
2 files changed, 12 insertions, 0 deletions
diff --git a/src/net/java/games/jogl/GLPbuffer.java b/src/net/java/games/jogl/GLPbuffer.java
index de85f6950..5df8d616c 100644
--- a/src/net/java/games/jogl/GLPbuffer.java
+++ b/src/net/java/games/jogl/GLPbuffer.java
@@ -60,4 +60,7 @@ public interface GLPbuffer extends GLDrawable {
/** Unbinds the pbuffer from its internal texture target. */
public void releaseTexture();
+
+ /** Querries initialization status a <code>this</code> pBuffer*/
+ public boolean isInitialized();
}
diff --git a/src/net/java/games/jogl/impl/GLPbufferImpl.java b/src/net/java/games/jogl/impl/GLPbufferImpl.java
index 860fc8422..028929573 100644
--- a/src/net/java/games/jogl/impl/GLPbufferImpl.java
+++ b/src/net/java/games/jogl/impl/GLPbufferImpl.java
@@ -54,6 +54,7 @@ public class GLPbufferImpl implements GLPbuffer {
// GLPbufferContext
private GLContext context;
private GLDrawableHelper drawableHelper = new GLDrawableHelper();
+ private boolean isInitialized=false;
public GLPbufferImpl(GLContext context) {
this.context = context;
@@ -176,6 +177,13 @@ public class GLPbufferImpl implements GLPbuffer {
public void removePropertyChangeListener(String propertyName,
PropertyChangeListener listener) {}
+ /** Querries initialization status a <code>this</code> pBuffer
+ * @return true if initialized
+ * */
+ public boolean isInitialized(){
+ return isInitialized;
+ }
+
//----------------------------------------------------------------------
// Internals only below this point
//
@@ -183,6 +191,7 @@ public class GLPbufferImpl implements GLPbuffer {
class InitAction implements Runnable {
public void run() {
drawableHelper.init(GLPbufferImpl.this);
+ isInitialized=true;
}
}
private InitAction initAction = new InitAction();