summaryrefslogtreecommitdiffstats
path: root/src/demos/proceduralTexturePhysics/Water.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/demos/proceduralTexturePhysics/Water.java')
-rw-r--r--src/demos/proceduralTexturePhysics/Water.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/demos/proceduralTexturePhysics/Water.java b/src/demos/proceduralTexturePhysics/Water.java
index d2c068f..a5df90c 100644
--- a/src/demos/proceduralTexturePhysics/Water.java
+++ b/src/demos/proceduralTexturePhysics/Water.java
@@ -213,12 +213,12 @@ public class Water {
// create the pbuffer. Will use this as an offscreen rendering buffer.
// it allows rendering a texture larger than our window.
- GLCapabilities caps = new GLCapabilities();
+ GLCapabilities caps = parentWindow.getGLCapabilities();
caps.setDoubleBuffered(false);
- if (!GLDrawableFactory.getFactory().canCreateGLPbuffer()) {
+ if (!GLDrawableFactory.getFactory(caps.getGLProfile()).canCreateGLPbuffer()) {
throw new GLException("Pbuffers not supported with this graphics card");
}
- pbuffer = GLDrawableFactory.getFactory().createGLPbuffer(caps,
+ pbuffer = GLDrawableFactory.getFactory(caps.getGLProfile()).createGLPbuffer(caps,
null,
initialMapDimensions[0],
initialMapDimensions[1],