From 47dc069104723f3d2e8d9ebdd700182e067163d0 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sat, 17 Dec 2011 21:41:30 +0100 Subject: GLDrawableFactory*.createOffscreenDrawable(): No implicit setRealized(true) @ creation GLDrawableFactory*.createOffscreenDrawable(): No implicit setRealized(true) @ creation, following deferred creation like onscreen drawables. This allows using offscreen drawables in classes like GLCanvas, where realization is deferred due to pending valid size. Only createGLPBuffer() realizes the offscreen pbuffer drawable immediatly to reduce the impact on user-code. GLDrawableFactoryImpl.createGLDrawable(): - Simplify OffscreenLayerSurface validation and check it first regardless of the chosenCaps to get a chance to use pbuffer. --- .../classes/jogamp/opengl/windows/wgl/WindowsBitmapWGLDrawable.java | 1 - .../classes/jogamp/opengl/windows/wgl/WindowsPbufferWGLDrawable.java | 2 -- 2 files changed, 3 deletions(-) (limited to 'src/jogl/classes/jogamp/opengl/windows/wgl') diff --git a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsBitmapWGLDrawable.java b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsBitmapWGLDrawable.java index 9e3f71513..574226570 100644 --- a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsBitmapWGLDrawable.java +++ b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsBitmapWGLDrawable.java @@ -58,7 +58,6 @@ public class WindowsBitmapWGLDrawable extends WindowsWGLDrawable { protected WindowsBitmapWGLDrawable(GLDrawableFactory factory, NativeSurface target) { super(factory, target, false); - setRealized(true); } protected void destroyImpl() { diff --git a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsPbufferWGLDrawable.java b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsPbufferWGLDrawable.java index c7becfdaf..740fb5466 100644 --- a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsPbufferWGLDrawable.java +++ b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsPbufferWGLDrawable.java @@ -64,8 +64,6 @@ public class WindowsPbufferWGLDrawable extends WindowsWGLDrawable { protected WindowsPbufferWGLDrawable(GLDrawableFactory factory, NativeSurface target) { super(factory, target, false); - - setRealized(true); } protected void destroyImpl() { -- cgit v1.2.3