Jogamp
jogl.git
2 years agoTestGearsES2GLJPanelAWT: Add manual test of creating a new JFrame/GLJPanel while... b22x
Sven Gothel [Fri, 18 Sep 2015 06:32:59 +0000 (08:32 +0200)]
TestGearsES2GLJPanelAWT: Add manual test of creating a new JFrame/GLJPanel while running

2 years agoBackport detection of pixel-scale change JAWTWindow/GLCanvas and GLJPanel
Sven Gothel [Wed, 16 Sep 2015 05:09:59 +0000 (07:09 +0200)]
Backport detection of pixel-scale change JAWTWindow/GLCanvas and GLJPanel

Partial backport of commit 6516a52d3da5cced924db63b64af911d55355325:
- Detect change of pixel-scale and propagate accordingly.
  This allows GLCanvas, GLJPanel instances
  to be dragged between monitor devices w/ different pixel-scale.
- NOT NewtCanvasAWT

Partial backport of commit b0af5159bc6100a6262afe6b52f9092a207ac2b3:
  Bug 1181 - JOGL WebStart Applications using GLCanvas/AWT may Deadlock by two AWT-EDT on Java >= 1.8.0_45

3 years agoTestVersionSemanticsNOUI: Add tests against v2.2.3 v2.2.4
Sven Gothel [Fri, 10 Oct 2014 14:04:55 +0000 (16:04 +0200)]
TestVersionSemanticsNOUI: Add tests against v2.2.3

3 years agoManual test of TestVersionSemanticsNOUI
Sven Gothel [Fri, 10 Oct 2014 13:45:01 +0000 (15:45 +0200)]
Manual test of TestVersionSemanticsNOUI

3 years agoFix minor compile errors introduced while backporting from master branch
Sven Gothel [Fri, 10 Oct 2014 13:43:43 +0000 (15:43 +0200)]
Fix minor compile errors introduced while backporting from master branch

3 years agoBug 1093 - NEWT PointerIcon swizzled on X11 and OSX; WindowIcon swizzled on OSX ...
Sven Gothel [Fri, 10 Oct 2014 01:37:21 +0000 (03:37 +0200)]
Bug 1093 - NEWT PointerIcon swizzled on X11 and OSX; WindowIcon swizzled on OSX ([R] -> [B])

Following mistakes were made in native PixelFormat
for PointerIcon and WindowIcon:

PointerIcon:
  X11: RGBA8888 -> BGRA8888
  OSX: BGRA8888 -> RGBA8888

WindowIcon:
  OSX: BGRA8888 -> RGBA8888

Test case: TestWindowAndPointerIconNEWT

(requires visual validation)

+++

Summary:

PointerIcon:
  BGRA8888: X11, Win32
  RGBA8888: OSX

WindowIcon:
  BGRA8888: X11, Win32
  RGBA8888: OSX

+++

Reported by 'LT'
  <http://forum.jogamp.org/Mac-OSX-newt-pointer-and-window-icon-displays-incorrectly-tp4033294.html>

Conflicts:
make/scripts/tests-win.bat

3 years agoGraph/Math: Fix minor apidoc issues
Sven Gothel [Thu, 9 Oct 2014 11:07:12 +0000 (13:07 +0200)]
Graph/Math: Fix minor apidoc issues

3 years agoGraph: Fix minor apidoc issues
Sven Gothel [Thu, 9 Oct 2014 10:28:32 +0000 (12:28 +0200)]
Graph: Fix minor apidoc issues

3 years agojavadoc: Add missing graph package to apidoc
Sven Gothel [Thu, 9 Oct 2014 09:46:22 +0000 (11:46 +0200)]
javadoc: Add missing graph package to apidoc

3 years agoNewt ScreenMode Tests: Return XRandR error-code, allowing fall-back (OpenIndiana...
Sven Gothel [Thu, 9 Oct 2014 01:33:36 +0000 (03:33 +0200)]
Newt ScreenMode Tests: Return XRandR error-code, allowing fall-back (OpenIndiana has issues); Min delay 4s before next setScreenMode(..)

3 years agoNewt Screen viewport in windows units: Add missing setup in overriden calcVirtualScre...
Sven Gothel [Wed, 8 Oct 2014 23:59:33 +0000 (01:59 +0200)]
Newt Screen viewport in windows units: Add missing setup in overriden calcVirtualScreenOriginAndSize(..) method (duplicate pixel unit)

3 years agoTestLandscapeES2NewtCanvasAWT: Enforce landscape shader to be compiled/linked upfront...
Sven Gothel [Wed, 8 Oct 2014 19:57:58 +0000 (21:57 +0200)]
TestLandscapeES2NewtCanvasAWT: Enforce landscape shader to be compiled/linked upfront AWT migration, since it takes a long time on Mesa/AMD

3 years agoShaderCode: Fix link to create(..) method
Sven Gothel [Wed, 8 Oct 2014 19:15:27 +0000 (21:15 +0200)]
ShaderCode: Fix link to create(..) method

3 years agoFix windows test scripts: Add gluegen-test-util.jar
Sven Gothel [Wed, 8 Oct 2014 19:15:04 +0000 (21:15 +0200)]
Fix windows test scripts: Add gluegen-test-util.jar

3 years agoTestTessellationShader01GL4NEWT: Add robustness, i.e. case where tessellation failed...
Sven Gothel [Wed, 8 Oct 2014 19:14:35 +0000 (21:14 +0200)]
TestTessellationShader01GL4NEWT: Add robustness, i.e. case where tessellation failed to compile/link (on unsupported platforms)

3 years agoUnit Tests: Increase minimum manual set timeout to 10s
Sven Gothel [Wed, 8 Oct 2014 18:05:34 +0000 (20:05 +0200)]
Unit Tests: Increase minimum manual set timeout to 10s

3 years agoBug 1079 - Remove symbolic link jogl/doc/bouml
Sven Gothel [Wed, 8 Oct 2014 06:57:44 +0000 (08:57 +0200)]
Bug 1079 - Remove symbolic link jogl/doc/bouml

Symbolic links may cause problems on platform where such feature is not supported (Windows)

3 years agoBug 1087: Set default framebuffer for OSX DummyDrawable, hence enforce NSView realiza...
Sven Gothel [Wed, 8 Oct 2014 06:17:23 +0000 (08:17 +0200)]
Bug 1087: Set default framebuffer for OSX DummyDrawable, hence enforce NSView realization for DummyDrawable

3 years agoBug 1088: Add GLRendererQuirks.NeedSharedObjectSync; Tests: Synchronize GL objects...
Sven Gothel [Wed, 8 Oct 2014 06:16:10 +0000 (08:16 +0200)]
Bug 1088: Add GLRendererQuirks.NeedSharedObjectSync; Tests: Synchronize GL objects if GLRendererQuirks.NeedSharedObjectSync is set.

GLSharedContextSetter#synchronization GL Object Synchronization

Usually synchronization of shared GL objects should not be required,
if the shared GL objects are created and immutable before concurrent usage.

However, using drivers exposing GLRendererQuirks.NeedSharedObjectSync
always require the user to synchronize access of shared GL objects.

Synchronization can be avoided if accessing the shared GL objects
exclusively via a queue or com.jogamp.common.util.Ringbuffer,
see GLMediaPlayerImpl as an example.

+++

GLRendererQuirks.NeedSharedObjectSync is set for all OSX versions

+++

Handle GLRendererQuirks.NeedSharedObjectSync in user code!

+++

All shared context tests passed on OSX 10.9.5,
and GNU/Linux w/ Nvidia + Mesa/AMD driver.

Conflicts:
src/jogl/classes/com/jogamp/opengl/GLRendererQuirks.java

3 years agoGLRendererQuirks: Align wording in API doc
Sven Gothel [Wed, 8 Oct 2014 06:12:03 +0000 (08:12 +0200)]
GLRendererQuirks: Align wording in API doc

3 years agoBug 1088: Fix ant test target 'junit.run.sharedctx': Reuse generalized 'generic.junit...
Sven Gothel [Wed, 8 Oct 2014 06:08:03 +0000 (08:08 +0200)]
Bug 1088: Fix ant test target 'junit.run.sharedctx': Reuse generalized 'generic.junit.run.newt.headless', 'generic.junit.run.awt', ..

Create generalized junit test launchers (targets)
to be reused w/ different input patterns to reduce copy/paste.

Since macrodef cannot be used, we use namespace properties for the new targets.
The properties are unset at the end of the target.

Now ''junit.run.sharedctx' utilizes the proper launch target,
hence works properly on OSX as well.

3 years agobuild-test.xml: Add junit.run.newt.headless.singletest target
Sven Gothel [Mon, 22 Sep 2014 20:31:31 +0000 (22:31 +0200)]
build-test.xml: Add junit.run.newt.headless.singletest target

3 years agoBug 1088: Shared Gears* Unit Tests: Align all 3 Gears* implementation to use a shared...
Sven Gothel [Wed, 8 Oct 2014 06:00:42 +0000 (08:00 +0200)]
Bug 1088: Shared Gears* Unit Tests: Align all 3 Gears* implementation to use a shared Gears* object

3 years agoGLContextImpl: Unify common TRACE_SWITCH and DEBUG_TRACE_SWITCH base info-string...
Sven Gothel [Wed, 8 Oct 2014 03:34:13 +0000 (05:34 +0200)]
GLContextImpl: Unify common TRACE_SWITCH and DEBUG_TRACE_SWITCH base info-string creation; MacOSXCGLContext: Fix intendation

3 years agoNEWT Display: Fix typo in API doc
Sven Gothel [Tue, 7 Oct 2014 17:26:38 +0000 (19:26 +0200)]
NEWT Display: Fix typo in API doc

3 years agoNativeWindow's ToolkitLock TRACE_LOCK: Show more usable details
Sven Gothel [Tue, 7 Oct 2014 07:53:11 +0000 (09:53 +0200)]
NativeWindow's ToolkitLock TRACE_LOCK: Show more usable details

3 years agoAnimatorBase thread-name: Add instance sequence number
Sven Gothel [Tue, 7 Oct 2014 07:48:36 +0000 (09:48 +0200)]
AnimatorBase thread-name: Add instance sequence number

3 years agoWindowsWGLGraphicsConfiguration[Factory]: Refine indentation to increase readability...
Sven Gothel [Thu, 2 Oct 2014 22:08:06 +0000 (00:08 +0200)]
WindowsWGLGraphicsConfiguration[Factory]: Refine indentation to increase readability (140 chars width)

3 years agoUses System.err instead of System.out in order to drive the debug logs more consisten...
unknown [Thu, 2 Oct 2014 14:15:02 +0000 (16:15 +0200)]
Uses System.err instead of System.out in order to drive the debug logs more consistent, adds a method to convert an attribute list into a capabilities object with no check in order to display some information about skipped capabilities objects and fixes a NullPointerException when skipping a capabilities object

3 years agoBug 1078: Fix commit 99f91f8b28d42cdf341533736e878056bcae4708 (GLRendererQuirks.NoPBu...
Sven Gothel [Wed, 1 Oct 2014 22:59:51 +0000 (00:59 +0200)]
Bug 1078: Fix commit 99f91f8b28d42cdf341533736e878056bcae4708 (GLRendererQuirks.NoPBufferWithAccum): Accum buffer allowed if !usePBuffer; Avoid NPE.

99f91f8b28d42cdf341533736e878056bcae4708

3 years agoFix of the bug 1078
Julien Gouesse [Wed, 1 Oct 2014 15:53:32 +0000 (17:53 +0200)]
Fix of the bug 1078

3 years agoBug 1085: Fix GLJPanel regression while printing w/ invisible GLJPanel: Zero size... v2.2.3
Sven Gothel [Thu, 2 Oct 2014 18:42:19 +0000 (20:42 +0200)]
Bug 1085: Fix GLJPanel regression while printing w/ invisible GLJPanel: Zero size panel size

This is a regression due to commit 84f367a73c5b16dcebfd877e82e1c2cb90ae74ce:
   GLJPanel Cleanup: Remove initial FBO reshape;
   ** Propagate reshape only if differs from panel-size; ** <- this one
   Use pre-fetched panel-size.

Above commit only issued 'sendReshape'
if the reshape-size differs from the actual panel-size.

Note: The reshape-size is propagated to panel-size either in
  [1] initializeBackendImpl(..) or
  [2] handleReshape(..) @ paintComponent.

While printing w/ an invisible GLJPanel the reshape-size
has not yet propagated to the panel-size (see above)
and two consecutive reshape calls will cause the last one to be dropped.

With this patch we have:

GLJPanel.addNotify()
GLJPanel.reshape.0 null resize [paint] [ this 0x0, pixelScale 1x1, panel 560x420] -> 0x0 * 1x1 -> 0x0, reshapeSize 0x0
GLJPanel.reshape.0 null resize [paint] [ this 560x420, pixelScale 1x1, panel 560x420] -> 560x420 * 1x1 -> 560x420, reshapeSize 560x420
GLJPanel.setupPrint: scale 1.000000 / 1.000000, samples 0, tileSz -1 x -1
GLJPanel.createAndInitializeBackend.1: [printing] 560x420 @ scale 1x1 -> 560x420 @ scale 1x1

A

3 years agoBug 1085: Increase and fix DEBUG verbosity in GLJPanel to catch reshape regression...
Sven Gothel [Thu, 2 Oct 2014 18:34:38 +0000 (20:34 +0200)]
Bug 1085: Increase and fix DEBUG verbosity in GLJPanel to catch reshape regression during print

3 years agoBug 1084: Fix GLProfile Mapping regarding hardware priority, honor software/hardware...
Sven Gothel [Wed, 1 Oct 2014 21:51:33 +0000 (23:51 +0200)]
Bug 1084: Fix GLProfile Mapping regarding hardware priority, honor software/hardware attribute of all profiles

GLProfile's mapping code does not consider the following combination:
  - GL4 software
  - GL3 hardware

and hence maps GL4-software -> [GL2ES2, GL2GL3],
where GL3-hardware -> [GL2ES2, GL2GL3] is desired.

This combination has recently been observed on
Mac OSX 10.9.5, which includes a software GL 4.1 implementation.

However, other systems could be affected as well.

+++

Fix GLProfile.computeProfileImpl(..):

Only use the higher profile, if hardware-accelerated or none of the
lower profiles offers hardware-acceleration!

This extra condition was missing for certain profiles,
e.g. GL4, GL4bc, GL3, GL3bc and GL2.

3 years agoBug 1078, Bug 1082: Fix regression (typo), add missing assignment of printGLAD in...
Sven Gothel [Wed, 1 Oct 2014 02:54:42 +0000 (04:54 +0200)]
Bug 1078, Bug 1082: Fix regression (typo), add missing assignment of printGLAD in NewtCanvasAWT.setupPrint()

3 years agoBug 1081: Fix GLJPanel Regression: Honor pre-init reshape-size at initializeBackendImpl()
Sven Gothel [Tue, 30 Sep 2014 22:36:09 +0000 (00:36 +0200)]
Bug 1081: Fix GLJPanel Regression: Honor pre-init reshape-size at initializeBackendImpl()

Commit 84f367a73c5b16dcebfd877e82e1c2cb90ae74ce removed utilization of reshape-size
in case panel-size is valid, even if a reshape event happened in between:
  - addNotify
  - paintComponent

initializeBackendImpl() includes now uses reshape-size IFF handleReshape is set.
Before it was using reshape-size only if panel-size was invalid.

TestAWT03GLJPanelRecreate01 covers this issue.

3 years agoBug 1078: Add Fallback in AWTPrintLifecycle.setupPrint(): Use Onscreen GLAD if Offscr...
Sven Gothel [Tue, 30 Sep 2014 21:18:15 +0000 (23:18 +0200)]
Bug 1078: Add Fallback in AWTPrintLifecycle.setupPrint(): Use Onscreen GLAD if Offscreen-GLAD Realization throws an Exception (Stability)

- GLDrawableFactoryImpl: createOffscreenDrawable(..) and createDummyAutoDrawable(..)
  Temporary catch exception during setRealized(true) of newly created GLDrawable,
  to unrealize the instance before propagating the exception.

  This handling removes a memory leak in case the exception of this method is handled
  and application continues to operate, e.g. as in AWTPrintLifecycle.setupPrint().

  The underlying drawable gets unrealized, since it's setRealized(boolean)
  implementation toggles its realize-state before delegating the realize-operation.
  Hence this is functional.

- AWTPrintLifecycle.setupPrint() Stability
  Catch exception thrown by factory.createOffscreenAutoDrawable(..)'s setRealize(true)
  to continue operation w/ onscreen GLAD.

3 years agoTestVersionSemanticsNOUI: Use 'V22X' to mark current version on branch b22x
Sven Gothel [Tue, 23 Sep 2014 23:31:53 +0000 (01:31 +0200)]
TestVersionSemanticsNOUI: Use 'V22X' to mark current version on branch b22x

3 years agoFix all backward compatibility issues w/ 2.2.0 and 2.2.1
Sven Gothel [Tue, 23 Sep 2014 23:25:49 +0000 (01:25 +0200)]
Fix all backward compatibility issues w/ 2.2.0 and 2.2.1

- Preserve fields, but make them deprecated and don't use them anymore.
  Using a new version with less visibility.

- Revert incompatible method prototype changes

- GLFBODrawable:
  - Completly remove FBOMODE_DEFAULT and FBOMODE_USE_DEPTH usage
    and deprecate them

- GLRendererQuirks:
  - Completly remove COUNT usage and deprecate it.
  - Add getCount() method for future compatibility.

3 years agoFix synchronization issues in Animator* Exception case v2.2.2
Sven Gothel [Tue, 23 Sep 2014 01:56:04 +0000 (03:56 +0200)]
Fix synchronization issues in Animator* Exception case

Refines commit cef7ba607ad7e8eb1ff2a438d77710a29aa0bda6

- The animator monitor-lock was still hold in the post finally block
  issuing flushGLRunnables(), due to intrinsic monitor release (in finally):
   - <http://docs.oracle.com/javase/specs/jvms/se7/html/jvms-2.html#jvms-2.11.10>
   - <http://stackoverflow.com/questions/10743285/behavior-of-a-synchronized-method-with-try-and-finally>

- Further: AnimatorBase.flushGLRunnables() acquired the lock itself (duh!)

This commit removes the requirement for finally altogether
by simply return a boolean from handleUncaughtException(caughtException),
where false denotes the caller to propagate the exception itself (no handler).

Post synchronized block then issues flushGLRunnables() and
exceptation propagation as required.

AnimatorBase.flushGLRunnables() 'synchronized' modifier is removed.

Further, ThreadDeath is being propagated if caught.
Here the finally block is also removed - redundant.

3 years agoFix GLContextImpl.setRendererQuirks(..) CTX_IMPL_ACCEL_SOFT profile state
Sven Gothel [Mon, 22 Sep 2014 21:22:57 +0000 (23:22 +0200)]
Fix GLContextImpl.setRendererQuirks(..) CTX_IMPL_ACCEL_SOFT profile state

- GLContextImpl.setRendererQuirks(..) in called in GLContextImpl.setGLFunctionAvailability(..)

- GLContextImpl.setRendererQuirks(..) was called before fixing CTX_IMPL_ACCEL_SOFT
  via isCurrentContextHardwareRasterizer().

  The latter set CTX_IMPL_ACCEL_SOFT based on known software renderer string within GL_RENDERER.

  This lead to incorrect hwAccel assumption and hence wrong setting of GLRendererQuirks:
    - NoDoubleBufferedPBuffer (was selected even w/ later CTX_IMPL_ACCEL_SOFT)
    - BuggyColorRenderbuffer  (was never selected)

- Fix performs GLContextImpl.setRendererQuirks(..) _after_
  fixing CTX_IMPL_ACCEL_SOFT via isCurrentContextHardwareRasterizer().

3 years agoFix synchronization issues in GLDrawableHelper.flushGLRunnables(), fixes rare deadloc...
Sven Gothel [Mon, 22 Sep 2014 21:17:28 +0000 (23:17 +0200)]
Fix synchronization issues in GLDrawableHelper.flushGLRunnables(), fixes rare deadlock with animator-exception and invoke(wait=true, ..)

Fix synchronization issues in GLDrawableHelper.flushGLRunnables():
  - Querying 'glRunnables.size()' is not synchronized, only its reference is volatile,
    not the instance's own states.

  - 'flushGLRunnable()' must operates while acquired the 'glRunnable' lock.

  - 'glRunnables' are no more volatile

  - introduced volatile 'glRunnableCount', allowing 'display(..)' method
    to pre-query whether blocking 'execGLRunnables(..)' must be called.
    This is risk (deadlock) free.

Also fixes rare deadlock in animator display-exception / GLAD.invoke(wait=true, ..) case:
  - 'GLDrawableHelper.invoke(.., GLRunnable)' acquires the 'glRunnable' lock.
  - Then it queries animator state, which is blocking.
  - Hence animator's 'flushGLRunnable()' call must happen outside the animator lock

3 years agoStabilize, fix regression: GLDrawable.invoke(..) and Animator* display-loop 'closure'
Sven Gothel [Mon, 22 Sep 2014 05:07:42 +0000 (07:07 +0200)]
Stabilize, fix regression: GLDrawable.invoke(..) and Animator* display-loop 'closure'

GLDrawable.invoke(..) regression of commit c77b8f586cb2553582a42f5b90aeee5ef85f1efe:
  'wait' was not set to false, if 'deferredHere' was forced to 'false'.
  This could lead to the situation where GLRunnableTask
  will catch the exception and supresses it.

Animator/FPSAnimator post exception propagation code
   animThread = null; notifyAll();
must be complete to finalize animator state in case of an exception.
Decorate 'handleUncaughtException(..)' w/ try { } finally { }
where the latter ensures the mentioned 'closure'.

3 years agoAdding missing applet launcher html page for GLJPanelsAndGLCanvasDemoGL2Applet
Sven Gothel [Sat, 20 Sep 2014 21:01:13 +0000 (23:01 +0200)]
Adding missing applet launcher html page for GLJPanelsAndGLCanvasDemoGL2Applet

3 years agoTestVersionSemanticsNOUI: V221 -> V222 Add exception for GLFBODrawable.FBOMODE_DEFAULT
Sven Gothel [Sat, 20 Sep 2014 14:48:57 +0000 (16:48 +0200)]
TestVersionSemanticsNOUI: V221 -> V222 Add exception for GLFBODrawable.FBOMODE_DEFAULT

3 years agoAdd GLJPanelsAndGLCanvasDemoGL2Applet: Simple applet test for GLJPanel/GL2 testing...
Sven Gothel [Sat, 20 Sep 2014 14:48:18 +0000 (16:48 +0200)]
Add GLJPanelsAndGLCanvasDemoGL2Applet: Simple applet test for GLJPanel/GL2 testing (offscreen, ..); Clean up GL2 Gears and Teapot state enable/disable

3 years agoFBObject: Fix depth- and stencil bit count selection for attachRenderbuffer(..);
Sven Gothel [Sat, 20 Sep 2014 14:06:56 +0000 (16:06 +0200)]
FBObject: Fix depth- and stencil bit count selection for attachRenderbuffer(..);

- Fix depth- and stencil bit count selection for attachRenderbuffer(..)
  - Add generic values: DEFAULT_BITS, REQUESTED_BITS, CHOSEN_BITS, MAXIMUM_BITS

  - Refactor depth- and stencil bit-count -> format into own method

  - Allow depth- and stencil bit-count select a higher bit-count if required (fix)

- GLFBODrawable.FBOMODE_USE_DEPTH is deprecated, using GLCapabilities.[get|set]DepthBits(..)
  - It was an oversight to introduce the bit flag in the first place,
    since we should have used the capabilities depth bit-count

- Graph Test: GLEventListenerButton shall use requested capabilities for FBO drawable.

3 years agoTestVersionSemanticsNOUI: Add v2.2.1 jogl-all.jar
Sven Gothel [Sat, 20 Sep 2014 06:02:32 +0000 (08:02 +0200)]
TestVersionSemanticsNOUI: Add v2.2.1 jogl-all.jar

3 years agoTestVersionSemanticsNOUI: Enable test V220->V221 and V221->V222 (w/ 2 extra exclusions)
Sven Gothel [Sat, 20 Sep 2014 05:24:06 +0000 (07:24 +0200)]
TestVersionSemanticsNOUI: Enable test V220->V221 and V221->V222 (w/ 2 extra exclusions)

Enable tests:

- V220->V221

- V221->V222 (w/ 2 extra exclusions)
  - GLRendererQuirks COUNT has been increased (-> use a method, FIXME)
  - Animator pauseIssued is volatile now

3 years agoGLJPanel: Fix backward compatibility, regression of commit fa6ba9d70d4fe47f05facc7260...
Sven Gothel [Sat, 20 Sep 2014 05:21:55 +0000 (07:21 +0200)]
GLJPanel: Fix backward compatibility, regression of commit fa6ba9d70d4fe47f05facc72608fb10c889f9d09

- bring back removed 'void dispose()' -> deprecated now

3 years agoFBObject: Fix merge issues of commit 034d843359508833094b6a87eb4b58fd5231bafa
Sven Gothel [Sat, 20 Sep 2014 05:20:35 +0000 (07:20 +0200)]
FBObject: Fix merge issues of commit 034d843359508833094b6a87eb4b58fd5231bafa

- Handle deprecated reset(..) variants return type in a backward compatible manner

3 years agoTestGearsES2GLJPanelAWT: Update frame title (awt-size, pixel-size) for GLEventListene...
Sven Gothel [Sat, 20 Sep 2014 00:52:27 +0000 (02:52 +0200)]
TestGearsES2GLJPanelAWT: Update frame title (awt-size, pixel-size) for GLEventListener.reshape(..)

3 years agoFBObject: Simplify API (init/reset); Only issue automatic resetSamplingSink(..) if...
Sven Gothel [Sat, 20 Sep 2014 00:51:44 +0000 (02:51 +0200)]
FBObject: Simplify API (init/reset); Only issue automatic resetSamplingSink(..) if required; Fix resetSamplingSink(..), isBound(), ..

- Simplify API (init/reset)
  - use new unique methods for init and reset:
    - void init(final GL gl, final int newWidth, final int newHeight, final int newSamples)
      - does not issue resetSamplingSink(..)
    - boolean reset(final GL gl, final int newWidth, final int newHeight, final int newSamples)
      - always issues resetSamplingSink(..)

  - deprecated dual-use (init/reset):
    - boolean reset(final GL gl, final int newWidth, final int newHeight)
    - boolean reset(final GL gl, int newWidth, int newHeight, int newSamples, final boolean resetSamplingSink)

- reset(..) no more creates a dummy 'samplingSink' instance if sampling > 0,
  left up to resetSamplingSink(..)

- Track 'modified' state of FBObject,
  if size, format or any attachment has been changed since last
    - use(..)
    - syncSamplingSink(..)
    - resetSamplingSink(..)

- Only issue resetSamplingSink(..) from syncSamplingSink(..)/use(..)
  if 'modified == true'

+++

- Fix setSamplingSink(..), i.e. samplingSink state handling:
  - Validated whether given samplingSink is initialized,
    throws Exception if not.

- Fix resetSamplingSink(..)
  - resets the bound state, i.e. leaves it untouched
    - also unbinds the samplingSink

  - sampleSinkDepthStencilMismatch() also returns true if
    this.depth/stencil == null, but samplingSink is not.

  - Newly created colorbuffer/-texture matches
    exiting colorbuffer's internal-format, if exists.

  - Using simplified resetSizeImpl(..) for size mismatch

  - Simplified samplingColorSink init check

- Fix isBound()
    was: 'bound = bound && fbName != gl.getBoundFramebuffer(GL.GL_FRAMEBUFFER)'
    fix: 'bound = bound && fbName == gl.getBoundFramebuffer(GL.GL_FRAMEBUFFER)'

- Fix detachRenderbuffer(..) validates whether detachment was successful,
  similar to detachColorbuffer(..)

Conflicts:
src/jogl/classes/com/jogamp/opengl/FBObject.java

3 years agoStereoClientRenderer: Remove redundant FBObject.detachAllColorbuffer(gl) for init...
Sven Gothel [Fri, 19 Sep 2014 17:21:29 +0000 (19:21 +0200)]
StereoClientRenderer: Remove redundant FBObject.detachAllColorbuffer(gl) for init call

3 years agoFBOobject GLEL Tests: Remove redundant detachAllColorbuffer(gl) for init call
Sven Gothel [Fri, 19 Sep 2014 17:20:48 +0000 (19:20 +0200)]
FBOobject GLEL Tests: Remove redundant detachAllColorbuffer(gl) for init call

3 years agoNew GLRendererQuirks.BuggyColorRenderbuffer: On Mesa 7.2 software, FBO color renderbu...
Sven Gothel [Thu, 18 Sep 2014 23:24:32 +0000 (01:24 +0200)]
New GLRendererQuirks.BuggyColorRenderbuffer: On Mesa 7.2 software, FBO color renderbuffer may cause a crash

Workaround crash caused by Mesa 7.2 software rendering
using color renderbuffer target in FBO.

If Mesa < 8.0 and software - or -
property 'jogl.fbo.force.nocolorrenderbuffer' is set,
set quirks:
- GLRendererQuirks.BuggyColorRenderbuffer
- GLRendererQuirks.NoFullFBOSupport (to disable MSAA)

GLFBODrawable always uses FBOMODE_USE_TEXTURE
if GLRendererQuirks.BuggyColorRenderbuffer is set.

+++

Crash Report:
  GNU C Library       : 2.13 stable
  OpenGL              : software
  Operating System    : Linux 3.2.0-4-amd64 #1 SMP Debian 3.2.51-1 x86_64
  Processor ID        : x86 Family 6 Model 44 Stepping 2, GenuineIntel

Abnormal termination:
Segmentation violation

Register State (from fault):
  RAX = 00000000ff1818f0  RBX = 00000000beaf8afc
  RCX = 0000000000000004  RDX = 00007f85ed9c9010
  RSP = 00007f8252d24fd0  RBP = 00007f8252d25020
  RSI = 0000000017b9b330  RDI = 0000000015bca400

   R8 = 0000000000000000   R9 = 00007f81edcd3014
  R10 = 00007f823565f6ce  R11 = 00007f827bee49aa
  R12 = 0000000000001406  R13 = 0000000000000001
  R14 = 00000000154d5458  R15 = 00000000154d4f10

  RIP = 00007f823565f7bc  EFL = 0000000000010206

   CS = 0033   FS = 0000   GS = 0000

Stack Trace (from fault):
[  0] 0x00007f823565f7bc put_row_ubyte4 at /mesa/main/renderbuffer.c:665 (in /lib/libGL.so.1)
[  1] 0x00007f8235727239 _swrast_write_rgba_span at /mesa/swrast/s_span.c:1450 (in /lib/libGL.so.1)
[  2] 0x00007f823574b071 smooth_rgba_triangle at /mesa/swrast/s_tritemp.h:862 (in /lib/libGL.so.1)
[  3] 0x00007f82357155f0 _swrast_Triangle at /mesa/swrast/s_context.c:692 (in /lib/libGL.so.1)
[  4] 0x00007f8235771780 triangle_offset_twoside_rgba at /mesa/swrast_setup/ss_tritmp.h:188 (in /lib/libGL.so.1)
[  5] 0x00007f82356d2cea _tnl_render_poly_elts at /mesa/tnl/t_vb_rendertmp.h:313 (in /lib/libGL.so.1)
[  6] 0x00007f82356d335e _tnl_RenderClippedPolygon at /mesa/tnl/t_vb_render.c:244 (in /lib/libGL.so.1)
[  7] 0x00007f82356c9313 clip_tri_4 at /mesa/tnl/t_vb_cliptmp.h:230 (in /lib/libGL.so.1)
[  8] 0x00007f82356cd026 clip_render_triangles_verts at /mesa/tnl/t_vb_rendertmp.h:163 (in /lib/libGL.so.1)
[  9] 0x00007f82356d37d9 run_render at /mesa/tnl/t_vb_render.c:320 (in /lib/libGL.so.1)
[ 10] 0x00007f82356c2436 _tnl_run_pipeline at /mesa/tnl/t_pipeline.c:158 (in /lib/libGL.so.1)
[ 11] 0x00007f82356c37da _tnl_draw_prims at /mesa/tnl/t_draw.c:402 (in /lib/libGL.so.1)
[ 12] 0x00007f82356b673a vbo_exec_DrawArrays at /mesa/vbo/vbo_exec_array.c:263 (in /lib/libGL.so.1)
[ 13] 0x00007f823583e5b0 glDrawArrays at /mesa/glapi/glapitemp.h:1645 (in /lib/libGL.so.1)

+++

3 years agoGLContextImpl.setRendererQuirks(..): Use GLRendererQuirks.addQuirk(int), dropping...
Sven Gothel [Thu, 18 Sep 2014 23:15:07 +0000 (01:15 +0200)]
GLContextImpl.setRendererQuirks(..): Use GLRendererQuirks.addQuirk(int), dropping usage of .addQuirks(int[] quirks, offset, len)

Directly adding a quirk allows dropping usage of erroneous fixed-sized int[] array for accumulated quirks.

3 years agoGLFBODrawableImpl: Utilize common self-contained setupFBO(..) method for FBO creation...
Sven Gothel [Thu, 18 Sep 2014 01:59:04 +0000 (03:59 +0200)]
GLFBODrawableImpl: Utilize common self-contained setupFBO(..) method for FBO creation incl. Bug 1020 glClear(..) ; Fixes missing fbo.unbind(gl)

Utilize common self-contained setupFBO(..) method for FBO creation incl. Bug 1020 glClear(..)
  initialize(..) and reset(..)'s fallback code
  contained duplicated FBO setup/creation code.

  The former was updated to suite the new FBO mode bits,
  where the latter left untouched, hence was buggy.

  Now setup and creation of a single FBO has been merged into setupFBO(..).

Fixes missing fbo.unbind(gl):
  We did no issue unbind() on each fbo instance
  while adding the workaround for Bug 1020.

  Adding fbo.markUnbound() call to all fbos but the last.

  Note: This might not cause any issues, since fbo.bind(gl) tests the currently bound fbo.

3 years agoGLJPanel Cleanup: Remove initial FBO reshape; Propagate reshape only if differs from...
Sven Gothel [Thu, 18 Sep 2014 01:43:13 +0000 (03:43 +0200)]
GLJPanel Cleanup: Remove initial FBO reshape; Propagate reshape only if differs from panel-size; Use pre-fetched panel-size.

3 years agoGLJPanel: Allow reconfiguration of offscreen's GLCapabilitiesImmutable
Sven Gothel [Sat, 13 Sep 2014 23:14:38 +0000 (01:14 +0200)]
GLJPanel: Allow reconfiguration of offscreen's GLCapabilitiesImmutable

Offscreen's GLCapabilitiesImmutable reconfiguration will dispose a realized instance
and issues recreation via initializeBackendImpl() immedietly.

Implementation performs operation on AWT-EDT.

Tests:
  - TestGearsES2GLJPanelAWT:
      - Toggle MSAA via 'm'

  - TestGearsGLJPanelAWT:
      - Toggle MSAA via 'm'
      - Toggle Bitmap via 'b'

3 years agoGears* Demos: Spin at same speed (0.5f tan per frame) ; GearsES2: Bring back default...
Sven Gothel [Sat, 13 Sep 2014 23:09:45 +0000 (01:09 +0200)]
Gears* Demos: Spin at same speed (0.5f tan per frame) ; GearsES2: Bring back default Z values, allow Z customization (StereoDemo01)

3 years agoFPSAnimator: Remove toString() override as accidently added in commit fa0115efb3989c2...
Sven Gothel [Sat, 13 Sep 2014 22:44:09 +0000 (00:44 +0200)]
FPSAnimator: Remove toString() override as accidently added in commit fa0115efb3989c28af21fc5f570ae49723566107

3 years agoFPSAnimator: Align code and pause/resume conditions w/ Animator, simplifying review.
Sven Gothel [Sat, 13 Sep 2014 13:28:58 +0000 (15:28 +0200)]
FPSAnimator: Align code and pause/resume conditions w/ Animator, simplifying review.

3 years agoAnimatorBase.finishLifecycleAction(): Non blocking call shall return true, success...
Sven Gothel [Sat, 13 Sep 2014 13:27:43 +0000 (15:27 +0200)]
AnimatorBase.finishLifecycleAction(): Non blocking call shall return true, success - otherwise pause()/.. return value is inconsistent.

Caller of e.g. pause() running on the anim-thread or AWT-EDT (AWTAnimatorImpl)
will be non-blocking.

Before this change, a non-blocking simply did not wait until the 'hold' condition is reached
and returned its negated value.
This ofc is 'false', indicated unsuccessful operation.

Caller use the return value to determine whether the call actually paused (or ..)
the animator. Despite the non-blocking nature, the pause state was set, even if not reached.

Hence a resume() would be required to continue operation after a temporary pause.

+++

This change ignores the non-blocking nature's unmet condition.
finishLifecycleAction() returns !nok || !blocking,
i.e. either true for the reached condition (blocking) or true if non-blocking.
Blocking calls with unmet condition still return false.

+++

In case an animated GLAutoDrawableis being pulled after a non-blocking animator pause() call,
the GLAutoDrawable's implementation thread-safety must ensure proper operation.

+++

3 years agoGLBuffers.sizeof(..): Add support for ES3, reading supported glPixelStorei states
Sven Gothel [Tue, 9 Sep 2014 19:02:55 +0000 (21:02 +0200)]
GLBuffers.sizeof(..): Add support for ES3, reading supported glPixelStorei states

3 years agoFix GLPixelStorageModes: Add missing import GLContext ; Regression of commit 01c709ff...
Sven Gothel [Tue, 9 Sep 2014 20:18:39 +0000 (22:18 +0200)]
Fix GLPixelStorageModes: Add missing import GLContext ; Regression of commit 01c709ff0e81ddd84e3bc78ec180a53587ec855c

(happens when you try to do things fast w/ line commits and w/o checking .. duh!)

3 years agoDon't utilize glPixelStorei's PACK/UNPACK IMAGE_HEIGHT and SKIP_IMAGES for Desktop...
Sven Gothel [Tue, 9 Sep 2014 17:58:47 +0000 (19:58 +0200)]
Don't utilize glPixelStorei's PACK/UNPACK IMAGE_HEIGHT and SKIP_IMAGES for Desktop GL < 1.2, avoiding GL-Error

Commit fc1e98790a02b4fa7922f3cdd9d437f87d7c99e5
added handling of PACK/UNPACK IMAGE_HEIGHT and SKIP_IMAGES in GLPixelStorageModes.

However, it has been overseen that the four states are not available in OpenGL 1.1.

Adding exclusion of the same if desktop GL < 1.2
and hence avoiding GL errors.

Same applies to GLBuffers.sizeof(..) method.

3 years agoBug 1065: Handle NULL result of TISGetInputSourceProperty(keyboard, kTISPropertyUnico... v2.2.1
Sven Gothel [Mon, 8 Sep 2014 06:27:03 +0000 (08:27 +0200)]
Bug 1065: Handle NULL result of TISGetInputSourceProperty(keyboard, kTISPropertyUnicodeKeyLayoutData), avoiding crash

3 years agoLICENSE.txt: Emphasice incompatible A.7) module is OPTIONAL
Sven Gothel [Mon, 8 Sep 2014 03:59:05 +0000 (05:59 +0200)]
LICENSE.txt: Emphasice incompatible A.7) module is OPTIONAL

3 years agoBug 1047 - jogamp.opengl.glu.mipmap.Mipmap now uses already parsed GL version number...
Sven Gothel [Mon, 8 Sep 2014 03:58:35 +0000 (05:58 +0200)]
Bug 1047 - jogamp.opengl.glu.mipmap.Mipmap now uses already parsed GL version number and GL profile selection

Since Bug 1047 didn't provide a unit tests, this must be fine for now.

3 years agoBug 1060 - Add GLProfile.isInitialized(): Returns true if JOGL has been initialized
Sven Gothel [Wed, 3 Sep 2014 21:32:52 +0000 (23:32 +0200)]
Bug 1060 - Add GLProfile.isInitialized(): Returns true if JOGL has been initialized

3 years agoAdding missing '@since 2.2.1' tags to ShaderCode and GLContext
Sven Gothel [Wed, 3 Sep 2014 21:25:52 +0000 (23:25 +0200)]
Adding missing '@since 2.2.1' tags to ShaderCode and GLContext

3 years agoBug 1059 _and_ version-compat breackage of commit c78ceb642d0ef5bb5bf27ff8ff1495175ee...
Sven Gothel [Wed, 3 Sep 2014 13:42:37 +0000 (15:42 +0200)]
Bug 1059 _and_ version-compat breackage of commit c78ceb642d0ef5bb5bf27ff8ff1495175ee2e983

Commit c78ceb642d0ef5bb5bf27ff8ff1495175ee2e983 changed:
  -    public static final String GL4   = "GL4";
  +    public static final String GL4   = "GL4".intern();

which is identified by semver as incompatible,
due to Bug 1059 (no more inlining of interned string references).

3 years agoHowToBuild: Debian i386 on x64: Add symbolic links for shared libs
Sven Gothel [Wed, 3 Sep 2014 04:25:40 +0000 (06:25 +0200)]
HowToBuild: Debian i386 on x64: Add symbolic links for shared libs

3 years agoBug 1058 - Fix GLContext.getGLSLVersionString(): Add 'profile' after version for...
Sven Gothel [Tue, 2 Sep 2014 05:16:58 +0000 (07:16 +0200)]
Bug 1058 - Fix GLContext.getGLSLVersionString(): Add 'profile' after version for GLSL >= 150 allowing GLSL compatibility profile

3 years agoBug 1043 - Add Tessellation Control and Evaluation Shader Support
Sven Gothel [Tue, 2 Sep 2014 05:11:18 +0000 (07:11 +0200)]
Bug 1043 - Add Tessellation Control and Evaluation Shader Support

- Add GL4.GL_TESS_CONTROL_SHADER and GL4.GL_TESS_EVALUATION_SHADER support for GLSL util class ShaderCode
- Add unit test TestTessellationShader01GL4NEWT, testing TessellationShader01aGL4 and TessellationShader01bGL4

3 years agoBug1044: Offscreen drawable AWT/ImageIO results in black image on OSX/[Java7-Java8]
Sven Gothel [Tue, 2 Sep 2014 03:38:39 +0000 (05:38 +0200)]
Bug1044: Offscreen drawable AWT/ImageIO results in black image on OSX/[Java7-Java8]

- Using our PNGJ writer results in proper images (RGB and RGBA) on all platforms
- Seems to be a bug w/ AWT/ImageIO

3 years agoBug 1048: Add unit tests demonstrating multiple NewtCanvasAWT instances are working
Sven Gothel [Tue, 2 Sep 2014 02:53:30 +0000 (04:53 +0200)]
Bug 1048: Add unit tests demonstrating multiple NewtCanvasAWT instances are working

Enhance following performance test cases, adding NewtCanvasAWT,
beside GLCanvas and GLJPanel, 25 instances:
  com.jogamp.opengl.test.junit.jogl.perf.TestPerf001GLJPanelInit01AWT
  com.jogamp.opengl.test.junit.jogl.perf.TestPerf001GLJPanelInit02AWT

Adding simple com.jogamp.opengl.test.junit.newt.TestMultipleNewtCanvasAWT
w/ two instances.

Manually tested on GNU/Linux and OSX (java7 and java8).

3 years agoGLProfile: Use String.intern() on static final profile strings ('GL4bc', 'GL4', ...
Sven Gothel [Tue, 2 Sep 2014 00:38:14 +0000 (02:38 +0200)]
GLProfile: Use String.intern() on static final profile strings ('GL4bc', 'GL4', ..) consequently using reference comparison.

GLProfile already compared profile strings by reference, hence interning those strings
to become canonical references was missing!

Consequently using reference comparison for all profile strings in GLProfile.

3 years agoBug 1052 - OpenGL ES 3.0 Mesa 10.1.3 Caught GLException: Not a GL4ES3 implementation...
Sven Gothel [Tue, 2 Sep 2014 00:20:52 +0000 (02:20 +0200)]
Bug 1052 - OpenGL ES 3.0 Mesa 10.1.3 Caught GLException: Not a GL4ES3 implementation - Part 2/2

- TestGLProfile01NEWT: Allow ctx.isGLES3Compatible() and hence GL4ES3 on GL3bc and GL3

- GLProfile: Remove GL4ES3 mapping using GL3bc and GL3, only GL4bc, GL4 and GLES3 are allowed in static mapping.

3 years agoBug 1052 - OpenGL ES 3.0 Mesa 10.1.3 Caught GLException: Not a GL4ES3 implementation...
Sven Gothel [Tue, 2 Sep 2014 00:04:22 +0000 (02:04 +0200)]
Bug 1052 - OpenGL ES 3.0 Mesa 10.1.3 Caught GLException: Not a GL4ES3 implementation - Part 1/2

Test enhancements triggering issue 'Bug 1052 - OpenGL ES 3.0 Mesa 10.1.3 Caught GLException: Not a GL4ES3 implementation'

- TestGLProfile01NEWT: Complete GLProfile and GL-object and GLContext validation

- On OpenGL ES 3.0 Mesa 10.1.4 it produces:

1) test06GLProfileGL4ES3(com.jogamp.opengl.test.junit.jogl.acore.TestGLProfile01NEWT)
javax.media.opengl.GLException: GL4ES3 is neither GL4bc, GL4 nor GLES3
    at com.jogamp.opengl.test.junit.jogl.acore.TestGLProfile01NEWT.validateGLProfileGL4ES3(TestGLProfile01NEWT.java:531)
    at com.jogamp.opengl.test.junit.jogl.acore.TestGLProfile01NEWT.validateOffline(TestGLProfile01NEWT.java:708)
    at com.jogamp.opengl.test.junit.jogl.acore.TestGLProfile01NEWT.test06GLProfileGL4ES3(TestGLProfile01NEWT.java:948)

i.e. wrong mapping of request GL4ES3 -> GL3

3 years agoBug 1017 - TextureIO.write(Texture, File) throws GLException Not a GL2 implementation...
Sven Gothel [Mon, 1 Sep 2014 14:14:43 +0000 (16:14 +0200)]
Bug 1017 - TextureIO.write(Texture, File) throws GLException Not a GL2 implementation on GL3 contexts

_gl.getGL2() -> _gl.getGL2GL3()

3 years agoScripts: Bump to java 1.8.0_20
Sven Gothel [Sun, 31 Aug 2014 19:17:43 +0000 (21:17 +0200)]
Scripts: Bump to java 1.8.0_20

3 years agoTestSharedContextNewtAWTBug523: Fix junit usage ..
Sven Gothel [Sun, 31 Aug 2014 15:50:05 +0000 (17:50 +0200)]
TestSharedContextNewtAWTBug523: Fix junit usage ..

3 years agoBug 1020 - First MSAA FBO frame on a mac osx nvidia card not antialiased
Sven Gothel [Sun, 31 Aug 2014 03:53:28 +0000 (05:53 +0200)]
Bug 1020 - First MSAA FBO frame on a mac osx nvidia card not antialiased

OSX/Nvidia's FBO needs to be cleared before blitting,
otherwise first MSAA frame lacks antialiasing.

GLFBODrawableImpl.initialize(..) can clear
GL.GL_COLOR_BUFFER_BIT and GL.GL_DEPTH_BUFFER_BIT, if used.

FBObject cannot clear the buffer(s) due to it's low-level API,
i.e. it cannot know when the first bind occurs _after_ user
completed FBO setup (attaching buffers).

Hence plain FBObject usage required manual injection
of glClear(..) after setup as demonstrated in GLJPanel.

We may need to elaborate in this case,
i.e. add an FBObject API entry like 'fbo.postInitNotify()'.

3 years agoTestGLReadBuffer01GLJPanelAWT: Add keyFrame-wait after init
Sven Gothel [Sun, 31 Aug 2014 02:25:52 +0000 (04:25 +0200)]
TestGLReadBuffer01GLJPanelAWT: Add keyFrame-wait after init

3 years agoFBObject Cleanup: Add comments about maxSamples > 0 implies fullFBOSupport; bind...
Sven Gothel [Sun, 31 Aug 2014 02:24:56 +0000 (04:24 +0200)]
FBObject Cleanup: Add comments about maxSamples > 0 implies fullFBOSupport; bind(): Set dedicated read/write if fullFBOSupport

- Add comments about maxSamples > 0 implies fullFBOSupport

- bind(): Set dedicated read/write if fullFBOSupport
  as done in syncSamplingSink() and unbind()

3 years agoRefine test cases for synchronous GLAutoDrawable display, swap-buffer and read-pixels...
Sven Gothel [Sat, 30 Aug 2014 18:32:56 +0000 (20:32 +0200)]
Refine test cases for synchronous GLAutoDrawable display, swap-buffer and read-pixels (non-MSAA and MSAA) Bugs: 841, 975 and 1020

.. add Platform and GL info !

3 years agoRefine test cases for synchronous GLAutoDrawable display, swap-buffer and read-pixels...
Sven Gothel [Sat, 30 Aug 2014 18:05:27 +0000 (20:05 +0200)]
Refine test cases for synchronous GLAutoDrawable display, swap-buffer and read-pixels (non-MSAA and MSAA) Bugs: 841, 975 and 1020

3 years agoBug 1054: Revert dfb9ed47ac6d8e85f6ae5fe166e7a6e28ca8ff83: Cannot change protected...
Sven Gothel [Sat, 30 Aug 2014 10:03:03 +0000 (12:03 +0200)]
Bug 1054: Revert dfb9ed47ac6d8e85f6ae5fe166e7a6e28ca8ff83: Cannot change protected field name w/o breaking backward compatibility

3 years agoBug 1055 - Access and query shared master GLContext in a deterministic fashion ;...
Sven Gothel [Sat, 30 Aug 2014 09:59:13 +0000 (11:59 +0200)]
Bug 1055 - Access and query shared master GLContext in a deterministic fashion ; Don't use arbitrary shared context as 'master'.

GLContext* passes the shared-master to GLContextShareSet,
which only creates a sets of shared contexts
without differentiating the master context.

GLContext*'s shared-slave attempts to lock
the realized shared-master's surface at creation.

Currently only an arbitrary shared context is selected
due to the missing 'master' identity.
The arbitrary shared context's surface is locked
and its shared context handle used to create the slave context.

Lacking of using the user given shared-master
can lead to deadlock situations - and locking a 'wrong' surface.

+++

The patch:

  - Allows query the user given shared-master!

  - Use the user given shared-master for locking and it's
    context handle for the slave's creation.

  - The shared-context mapping maps each shared-master
    to a shared-slave within one shared-context-set,
    allowing deterministic and individual shared-master queries.

3 years agoBug 1054: GLContext: makeCurrent() needs a null-check of [mutable] drawable; Review...
Sven Gothel [Fri, 29 Aug 2014 22:21:00 +0000 (00:21 +0200)]
Bug 1054:  GLContext: makeCurrent() needs a null-check of [mutable] drawable; Review null checks and synchronization/locking.

'drawable' field of GLContextImpl is mutable via setGLDrawable(..),
which requires high-level locking as documented.

The required high-level locking allows us to _not_ add special
synchronization to this field (and drawableRead).

A simple null-check in makeCurrent() shall be sufficient,
plus ensuring mentioned high-level locking is applied.

GLContextImpl 'drawable' and 'drawableRead' synchronization:
  - commit ad79bd072b600a3f2416cc6f0c61e2925000069d check of null drawable is sufficient
  - Add GLAutoDrawable upstream-lock locking to:
    - AWT GLCanvas setupPrint/releasePrint
    - AWT GLJPanel (was missing)

Misc:
  - validate shared-context native-surface locking, throw exception if not successful
  - pixelDataEvaluated does not need to be synchronized, since it's being called while context is current, locking
  - GLDrawableHelper.recreateGLDrawable(..): Remove redundant glFinish() call

3 years agoBug 1054: Cleanup GLContext: 'lock' -> 'contextLock'
Sven Gothel [Fri, 29 Aug 2014 14:11:08 +0000 (16:11 +0200)]
Bug 1054: Cleanup GLContext: 'lock' -> 'contextLock'

3 years agoBug 1054: Cleanup GLContext 'lock' and 'drawable' usage, perform drawable null check...
Sven Gothel [Fri, 29 Aug 2014 13:19:50 +0000 (15:19 +0200)]
Bug 1054: Cleanup GLContext 'lock' and 'drawable' usage, perform drawable null check in constructor.

This patch merely cleans up 'lock' and 'drawable' usage,
while fixing:
  - constructor: Add drawable null check -> IllegalArgumentException
  - setGLReadDrawable: Proper precondition checks
  - setGLDrawable: Proper precondition checks

Affected methods of mutable drawable for which we have to consider locking:
  - setGLReadDrawable
  - setGLDrawable
  - release
  - destroy
  - makeCurrent

3 years agoGLSharedContextSetter: Fix API doc and all html references (fix URL and complete...
Sven Gothel [Thu, 28 Aug 2014 23:31:03 +0000 (01:31 +0200)]
GLSharedContextSetter: Fix API doc and all html references (fix URL and complete notes in all implementations)

3 years agoglsl.sdk.CompileShader: Use IOUtil.StreamMonitor
Sven Gothel [Thu, 28 Aug 2014 17:07:36 +0000 (19:07 +0200)]
glsl.sdk.CompileShader: Use IOUtil.StreamMonitor

3 years agoTestVersionSemantics: BACKWARD_COMPATIBLE_USER current vs 2.2.0
Sven Gothel [Thu, 28 Aug 2014 17:00:42 +0000 (19:00 +0200)]
TestVersionSemantics: BACKWARD_COMPATIBLE_USER current vs 2.2.0

3 years agoHowToBuild: Revert required git version back to 1.6.0 (from 1.7.10, commit 1882b65513...
Sven Gothel [Thu, 28 Aug 2014 05:26:33 +0000 (07:26 +0200)]
HowToBuild: Revert required git version back to 1.6.0 (from 1.7.10, commit 1882b6551326e583c311b6b169be2222125df4d9)

git version 1.7.10 is not available on certail 'long life' / LTS systems,
we have to reschedule the gluegen patch for a later time.

3 years agoHowToBuild: Bump requirements: ant >= 1.9.0, git >= 1.7.10
Sven Gothel [Thu, 28 Aug 2014 04:56:16 +0000 (06:56 +0200)]
HowToBuild: Bump requirements: ant >= 1.9.0, git >= 1.7.10

- ant >= 1.9.0
 - Due to java8 build support

- git >= 1.7.10
 - Due to gluegen's new git query of HEAD branch and sha1-tip

3 years agoGraph/Text: Prepare unit tests for font rendering validation (WIP)
Sven Gothel [Thu, 28 Aug 2014 04:15:49 +0000 (06:15 +0200)]
Graph/Text: Prepare unit tests for font rendering validation (WIP)

http://JogAmp.org git info: FAQ, tutorial and man pages.