aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/com
Commit message (Collapse)AuthorAgeFilesLines
* Graph/Math: Fix minor apidoc issuesSven Gothel2014-10-096-17/+42
|
* Graph: Fix minor apidoc issuesSven Gothel2014-10-092-3/+7
|
* ShaderCode: Fix link to create(..) methodSven Gothel2014-10-081-3/+3
|
* Bug 1088: Add GLRendererQuirks.NeedSharedObjectSync; Tests: Synchronize GL ↵Sven Gothel2014-10-081-2/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* GLRendererQuirks: Align wording in API docSven Gothel2014-10-081-13/+19
|
* AnimatorBase thread-name: Add instance sequence numberSven Gothel2014-10-081-2/+5
|
* Fix of the bug 1078Julien Gouesse2014-10-081-2/+18
|
* Bug 1078: Add Fallback in AWTPrintLifecycle.setupPrint(): Use Onscreen GLAD ↵Sven Gothel2014-10-011-1/+1
| | | | | | | | | | | | | | | | | | | 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.
* Fix all backward compatibility issues w/ 2.2.0 and 2.2.1Sven Gothel2014-09-244-45/+62
| | | | | | | | | | | | | | | - 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.
* Fix synchronization issues in Animator* Exception casev2.2.2Sven Gothel2014-09-233-74/+77
| | | | | | | | | | | | | | | | | | | | | | | 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.
* Fix synchronization issues in GLDrawableHelper.flushGLRunnables(), fixes ↵Sven Gothel2014-09-223-40/+60
| | | | | | | | | | | | | | | | | | | | | 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
* Stabilize, fix regression: GLDrawable.invoke(..) and Animator* display-loop ↵Sven Gothel2014-09-222-8/+14
| | | | | | | | | | | | | | | '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'.
* FBObject: Fix depth- and stencil bit count selection for attachRenderbuffer(..);Sven Gothel2014-09-202-41/+95
| | | | | | | | | | | | | | | - 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.
* FBObject: Fix merge issues of commit 034d843359508833094b6a87eb4b58fd5231bafaSven Gothel2014-09-201-7/+14
| | | | - Handle deprecated reset(..) variants return type in a backward compatible manner
* FBObject: Simplify API (init/reset); Only issue automatic ↵Sven Gothel2014-09-202-160/+369
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* StereoClientRenderer: Remove redundant FBObject.detachAllColorbuffer(gl) for ↵Sven Gothel2014-09-201-1/+0
| | | | init call
* New GLRendererQuirks.BuggyColorRenderbuffer: On Mesa 7.2 software, FBO color ↵Sven Gothel2014-09-201-2/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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) +++
* GLContextImpl.setRendererQuirks(..): Use GLRendererQuirks.addQuirk(int), ↵Sven Gothel2014-09-201-0/+20
| | | | | | dropping usage of .addQuirks(int[] quirks, offset, len) Directly adding a quirk allows dropping usage of erroneous fixed-sized int[] array for accumulated quirks.
* FPSAnimator: Remove toString() override as accidently added in commit ↵Sven Gothel2014-09-141-5/+0
| | | | fa0115efb3989c28af21fc5f570ae49723566107
* FPSAnimator: Align code and pause/resume conditions w/ Animator, simplifying ↵Sven Gothel2014-09-141-29/+37
| | | | review.
* AnimatorBase.finishLifecycleAction(): Non blocking call shall return true, ↵Sven Gothel2014-09-142-12/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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. +++
* GLBuffers.sizeof(..): Add support for ES3, reading supported glPixelStorei ↵Sven Gothel2014-09-141-5/+9
| | | | states
* Fix GLPixelStorageModes: Add missing import GLContext ; Regression of commit ↵Sven Gothel2014-09-091-0/+1
| | | | | | 01c709ff0e81ddd84e3bc78ec180a53587ec855c (happens when you try to do things fast w/ line commits and w/o checking .. duh!)
* Don't utilize glPixelStorei's PACK/UNPACK IMAGE_HEIGHT and SKIP_IMAGES for ↵Sven Gothel2014-09-092-8/+16
| | | | | | | | | | | | | | 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.
* Adding missing '@since 2.2.1' tags to ShaderCode and GLContextSven Gothel2014-09-031-4/+20
|
* Bug 1043 - Add Tessellation Control and Evaluation Shader SupportSven Gothel2014-09-021-16/+56
| | | | | - 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
* Bug 1017 - TextureIO.write(Texture, File) throws GLException Not a GL2 ↵Sven Gothel2014-09-011-1/+5
| | | | | | implementation on GL3 contexts _gl.getGL2() -> _gl.getGL2GL3()
* FBObject Cleanup: Add comments about maxSamples > 0 implies fullFBOSupport; ↵Sven Gothel2014-08-311-14/+11
| | | | | | | | | 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()
* GLSharedContextSetter: Fix API doc and all html references (fix URL and ↵Sven Gothel2014-08-292-0/+13
| | | | complete notes in all implementations)
* glsl.sdk.CompileShader: Use IOUtil.StreamMonitorSven Gothel2014-08-281-33/+1
|
* graph/font: Use 'pixelSize' var-name, remove redundanciesSven Gothel2014-08-281-4/+39
|
* Fix commit b5910f18f0b82a8a1f6f6252dc19971d5e487f39 for toString(): Call ↵Sven Gothel2014-08-282-0/+11
| | | | super.hashCode(), due to InternalError("hashCode not designed")
* Bug 1021: Refine Stereo API; Fix GenericStereoDevice; Fix StereoDemo01 for ↵Sven Gothel2014-08-072-1/+22
| | | | | | | | | | | | | | | | | | | | movie playback and OSX usage (HiDPI surfaceSize) - StereoDevice.DeviceType: Add API doc - StereoDevice: Add getFactory() - GenericStereoDevice - Use common static vars for configurations for simplicity - Fix createRenderer(..)'s eyeViewport in case no post-processing is performed, i.e. needs viewport X offset. - StereoDemo01 - Use 'movie' eyePosition instead of default if: - using a movie player _and_ using lenses! - Fix NEWT window pixel-unit size after window creation!
* Bug 1039: Rename GLAnimatorControl.UncaughtGLAnimatorExceptionHandler -> ↵Sven Gothel2014-08-061-3/+3
| | | | GLAnimatorControl.UncaughtExceptionHandler
* Bug 1039 - Specify behavior of GLEventListener Exceptions occurring while ↵Sven Gothel2014-08-066-49/+156
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GLAutoDrawable processing [part-3] Add GLAnimatorControl.UncaughtGLAnimatorExceptionHandler interface to optionally handle uncaught exception within an animator thread by the user. Implementation also requires to flush all enqueued GLRunnable instances via GLAutoDrawable.invoked(..) in case such exception occurs. Hence 'GLAutoDrawable.flushGLRunnables()' has been added. Only subsequent exceptions, which cannot be thrown are dumped to System.stderr. +++ Handling of exceptions during dispose() Exception in NEWT's disposeGL*() are also caught and re-thrown after the NEWT window has been destroyed in WindowImpl.destroyAction: - GLEventListener.dispose(..) - GLDrawableHelper.disposeAllGLEventListener(..) - GLDrawableHelper.disposeGL(..) - GLAutoDrawableBase.destroyImplInLock(..) - GLWindow.GLLifecycleHook.destroyActionInLock(..) - WindowImpl.destroyAction on NEWT-EDT - WindowImpl.destroy Further more, exceptions occuring in native windowing toolkit triggered destroy() are ignored: - GLAutoDrawableBase.defaultWindowDestroyNotifyOp(..) It has to be seen whether such exception handling for dispose() shall be added to AWT/SWT. +++ TestGLException01NEWT covers all GLEventListener exception cases on-thread and off-thread (via animator). +++
* Bug 1039 - Specify behavior of GLEventListener Exceptions occurring while ↵Sven Gothel2014-08-051-2/+34
| | | | | | | | | | | | | GLAutoDrawable processing [part-2] In case of an exception thrown within an GLEventListener called off-thread by Animator: - Animator shall stop - Animator shall forward the exception GLDrawableHelper shall also flush all queued GLRunnable tasks in case of an exception, so that another thread waiting until it's completion is notified and continues processing.
* Bug 1039 - Specify behavior of GLEventListener Exceptions occurring while ↵Sven Gothel2014-07-311-13/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GLAutoDrawable processing [part-1] Implements Specification as described on 'Bug 1039 Comment 1' <https://jogamp.org/bugzilla/show_bug.cgi?id=1039#c1> TODO: - Offthread exception handler ++++ GLDrawableHelper is used in all GLAutoDrawable implementations and for most operations. GLAutoDrawable/GLDrawableHelper invoke(..) method: - invoke(..) forwards a caught exception - if blocking, it forwards an exception happening within the passed GLRunnable(s). Here the exception is caught, printed and then thrown by invoke itself. - if non-blocking, an exception happening within the passed GLRunnable(s) will be thrown in the thread issuing it's execution, i.e. display() call. Here the exception is not caught and simply thrown by the GLRunnable. GLAutoDrawable.destroy() -> GLDrawableHelper.disposeGL(..) method: - disposeAllGLEventListener() being invoked by disposeGL(..), catches exception thrown by GLEventListener.dispose(..) and prints them to stderr. The first caught exception is re-thrown at the end as an GLException. - disposeGL() catches re-thrown GLException by disposeAllGLEventListener() for GLEventListener.dispose(..) and re-throws it when operation is complete. - disposeGL() catches an exception thrown at context destruction or release and re-throws it when operation is complete. An early exception at context.makeCurrent() is _not_ caught, since it is the first operation which simply shall unwind the stack. GLAutoDrawable.display() -> GLDrawableHelper.invokeGLImpl(..) method: - invokeGLImpl(..) for display() follows disposeGL() mechanism, i.e. it catches exception thrown at GLEventListener's init(..), reshape(..) and display(..) methods and re-throws it when operation is complete. It also catches an exception thrown at context release and re-throws it when operation is complete. An early exception at context.makeCurrent() is _not_ caught, since it is the first operation which simply shall unwind the stack. ++++ None of the above thrown exception shall be caught and suppressed on the caller side. If an operation must be completed while an exception is caught, it shall be cached and re-thrown after the operations. In case multiple exception at multiple places are caught within an operation, they all shall be cached and the first one shall be re-thrown. In case of multiple exception from the same place, i.e. a loop through all GLEventListener, the first shall be cached and re-thrown after operation is completed. It has to be determined, whether we like to dump the exceptions, especially the ones who get suppressed in case of multiple exceptions.
* Bug 830 - Refine Heuristics for to query whether ↵Sven Gothel2014-07-311-11/+28
| | | | GLDrawableUtil.swapGLContextAndAllGLEventListener is safe: Add Accumulator Buffer bits
* GLDrawable: Expose getRequestedGLCapabilities() (Include to public API)Sven Gothel2014-07-311-6/+2
| | | | | | | | | | In certain cases, it is required to read the user requested capabilities from places other than the user code. Hence adding public method to GLDrawable interface. This removes the need to cast to private GLDrawableImpl, which included such method.
* Refine test ff5dba28610b4f680c9320e9e52669ed54d4de43: Perform context switch ↵Sven Gothel2014-07-301-2/+18
| | | | on GL capable thread if required. Add API doc note about this requirement.
* Bug 830 - Add Heuristics for to query whether ↵Sven Gothel2014-07-301-0/+31
| | | | | | | | | | | | | | | | | | | | | | | GLDrawableUtil.swapGLContextAndAllGLEventListener is safe (Doesn't work w/ pre MSAA onscreen drawable) GLDrawableUtil.isSwapGLContextSafe(..) allows user to query whether 'we think' it's safe to utilize swapping of GLContext between GLAutoDrawable instances. Currently known unsafe cases are: - between on- and offscreen and one of the following: - MSAA involved, or - STEREO involved Enhanced unit tests in this regard: - TestGLContextDrawableSwitch02AWT - using GLContextDrawableSwitchBase0 - TestGLContextDrawableSwitch02NEWT - using GLContextDrawableSwitchBase0 Utilized safe query for setupPrint(..) action in: - AWT GLCanvas - AWT GLJPanel - NewtCanvasAWT
* Fix ShaderCode.es3_default_precision_fp: ES 3.x requires same precision for ↵Sven Gothel2014-07-291-2/+6
| | | | uniforms -> re-use es3_default_precision_vp; Fixes PointsDemoES2
* BuildComposablePipeline: Handle synthetic isGL* and getGL* more generic, ↵Sven Gothel2014-07-291-149/+115
| | | | | | | | | | | | | | | | | allow FixedFunctionHook to properly determine it's identity BuildComposablePipeline: Handle synthetic isGL* and getGL* more generic, allow using a prologue hook as needed for FixedFunctionHook's 'isGL*core()', 'isGLES*Compatible()' and 'getGLProfile()' methods. The latter FixedFunctionHook take the emulated GL profile GL2ES1 into account, allowing JOGL code to assume only having GL2ES1 available. Otherwise methods like Texture.enable(..) would skip the glEnable(TEXTURE_2D) call and FixedFunctionHook could not enable it's usage. GLProfile received a 'public static GLProfile createCustomGLProfile(final String profile, final GLProfile profileImpl)' allowing utilities like FixedFunctionHook to create a generic profile. BuildComposablePipeline sorts the methods before emitting for better readability.
* Bug 1037 - FBObject: Add proper attachment size validation at init, reset ↵Sven Gothel2014-07-281-13/+43
| | | | and attachColorbuffer(..) / attachRenderbuffer(..)
* Bug 1037 - FBObject/GLFBODrawable: Do not assume using a TextureAttachment ↵Sven Gothel2014-07-282-145/+258
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | for a Colorbuffer, also make DEPTH optional. API Change +++ In certain cases a TextureAttachment for the FBO's color buffer is not desired, either for performance reasons where texture functionality is not required or to avoid texture restrictions like size, etc. +++ GLFBODrawable shall use TextureAttachment for the FBO's color buffer and a DEPTH buffer per default. However, the user shall be allowed to use a plain ColorAttachment (renderbuffer) and also no DEPTH buffer. +++ FBObject Details: - Colorbuffer interface exposes Attachment details like format, size, etc as well as it's implementation specifics, isTextureAttachment() and getTextureAttachment() allowing a clean cast and type query. - Allow ColorAttachment to be used for non MSAA - Make TextureAttachment optional for method 'use(GL, TextureAttachment)' - Only validate size against MAX_TEXTURESIZE if using a TextureAttachment - API Change: - rename: getColorAttachmentCount() -> getColorbufferCount() - add: getTextureAttachmentCount() - change 'TextureAttachment getSamplingSink()' -> 'Colorbuffer getSamplingSink()'
* Bug 1035 - Allow Gamma [Brightness, Contrast] settings to be performed on ↵Sven Gothel2014-07-271-53/+63
| | | | | | | | | | | | | | | | | | | | | | | | | display/screen of a NativeSurface Currently GLDrawableFactoryImpl's gamma settings are performed only on the main screen. Allow passing a NativeSurface, so it's display/screen gamma values will be changed. Further, promote low-level gamma settings to GLDrawableFactory for direct usage. Change com.jogamp.opengl.util.Gamma to use a GLDrawable instead of a GL object to clarify that we use the drawable. Also add a GLAutoDrawable variant, allowing proper locking of its 'upstream-lock' to guarantee atomicity. +++ Tested manually w/ TestGearsES2NEWT on X11 and Windows using the 'g' and 'G' to modify gamma. Value is properly reset on exit.
* Bug 1033: Guarantee atomicity of high-level GLAutoDrawable operations, ↵Sven Gothel2014-07-274-331/+550
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | avoiding race conditions. GLAutoDrawable (API CHANGE) allowing atomic operations: - Add class API-doc chapter about 'GLAutoDrawable Locking' - Add method invoke(..) API-doc description about throwing IllegalStateException in case of a detected deadlock situation ahead (Note: Implemented in GLDrawableHelper.invoke(..) for all implementations) - Add new methods for proper multithread handling: - public RecursiveLock getUpstreamLock(); - public boolean isThreadGLCapable(); +++ GLEventListenerState/GLDrawableUtil: - Perform operation in a atomic fashion, i.e. lock GLAutoDrawable during whole operations: - GLDrawableUtil.swapGLContext(..) - GLDrawableUtil.swapGLContextAndAllGLEventListener(..) - GLEventListenerState.moveFrom(..) - GLEventListenerState.moveTo(..) - ReshapeGLEventListener: - Moved from GLEventListenerState.ReshapeGLEventListener -> GLDrawableUtil.ReshapeGLEventListener - Takes 'displayAfterReshape' case into account. +++ javax.media.opengl.Threading Clarifications: - Public 'enum Mode', i.e. Threading.Mode - Public getMode() - Clarified 'isOpenGLThread()': - Take 'singleThreaded' into account directly, i.e. always return 'true' if singleThreaded == false
* Bug 1024: Add fallback for native-jar-file location via classpathSven Gothel2014-07-111-1/+1
| | | | Adapt to GlueGen commit f5c48efcf546ba4e08e197ccced6df83b57e1755
* StereoClientRenderer: Fix API doc anchor linkSven Gothel2014-07-101-2/+1
|
* StereoDeviceRenderer/ClientRenderer: Add note about 'Correct Asymmetric FOV ↵Sven Gothel2014-07-102-0/+18
| | | | Rendering', using FovHVHalves - incl. references