summaryrefslogtreecommitdiffstats
path: root/src/test/com/jogamp/opengl
Commit message (Collapse)AuthorAgeFilesLines
* Workaroung a Java7 AWT EDT/Robot bug: Validate whether AWT-EDT is alive ↵Sven Gothel2013-06-242-3/+59
| | | | | | | | | | | | | | | | | | | | | before certain robot ops. We have experienced that w/o utilizing AWT components, i.e. NEWT tests, the AWT-EDT 'sometimes' dies. Performing AWT robot's waitForIdle() in this situation causes a deadlock, since the call will never complete it's EventQueue.invokeAndWait() call. While analyzing this issue, we created a test tool whether the the AWT EDT is still alive. This test issues EventQueue.invokeLater( .. { flag=true; } ); and polls up until 2s for the result. Turns out that the sporadic AWT-EDT issues are solved by this test itself, i.e. it probably cause it to be reinstated. (?!) We have to observe this behavior. Another proof that quantum mechanic rules also apply in the macro cosmos :)
* UITestCase: Increase SINGLE_INSTANCE_LOCK_TO from 3 to 6 minutes!Sven Gothel2013-06-241-1/+1
|
* TestSWTAccessor03AWTGLn: Fix SWT deadlock on Java7/Windows: Must perform AWT ↵Sven Gothel2013-06-241-2/+6
| | | | frame close on current thread ..
* TestGearsES2GLJPanel*: Use Gears (GL 1 based) if using bitmap - On Windows ↵Sven Gothel2013-06-242-6/+4
| | | | | | GDI would be returned and neither ES1 nor ES2 features are available. Fixes commit 3e528a69db38711c789a08d1d7335e5a7739f780
* TestGearsES2GLJPanel*: Use GearsES1 is using bitmap - On Windows GDI would ↵Sven Gothel2013-06-242-5/+20
| | | | | | | be returned! We still have to solve the GL renderer selection / probing problem, i.e. in such cases we don't know before context realization which GL renderer we actually receive.
* GearsES2/RedSquareES2: Detect !GLSL and don't attempt to render in such case.Sven Gothel2013-06-242-9/+34
|
* Tests: Remove subsequent exceptions .. (not original issue, but annoying ↵Sven Gothel2013-06-243-5/+13
| | | | while analyzing)
* Fix Bug 761 (part 2/2): NEWT registers one customShutdownHook @ ↵Sven Gothel2013-06-231-0/+46
| | | | | | | | | | | | | | | | | | | | | | | NativeWindowFactory.shutdownHook head, allowing proper resource cleanup. 1 WindowImpl.shutdownAll(): - For all instances: - mark invalid (causes any user thread to disregard the window) 2 ScreenImpl.shutdownAll(): - Removed own shutdown-hook! - For all instances: - Reset ScreenMonitorState 3 DisplayImpl.shutdownAll(): - For all instances: - Remove EDT - closeNativeImpl Manually tested on X11 w/ NV and ATI Catalyst (fglrx) - DFLAGS="-Djogl.debug.GLDrawable -Dnativewindow.debug.X11Util -Dnativewindow.debug.NativeWindow -Dnewt.debug.Display -Dnewt.debug.Screen -Dnewt.debug.Window" - java $DFLAGS com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT -time 2000 -sysExit testExit - valid arguments for sysExit: testExit, testError, displayExit, displayError
* Fix Bug 735: GLAutoDrawable must issue glViewport(..) even w/o ↵Sven Gothel2013-06-172-5/+1
| | | | | | | | | | | GLEventListener ; Optimize GLDrawableHelper's glViewportCall(..) GLAutoDrawable must issue glViewport(..) even w/o GLEventListener - Same behavior w/ or w/o GLEventListener requires to issue glViewport, always. Optimize GLDrawableHelper's glViewportCall(..) - 'private void init(..)' receives 'setViewport' argument to be passed to 'private void reshape(..)' allowing to only the the viewport once @ 'public void init(..)' and display.
* Fix TestNewtKeyEventAutoRepeatAWT (Bug 688): Reduce head/tail event check to ↵Sven Gothel2013-06-171-16/+4
| | | | 2 events (Windows can't produce AR)
* Fix Bug 688: Removal of NEWT KeyEvent.EVENT_KEY_TYPED and ↵Sven Gothel2013-06-172-5/+3
| | | | KeyListener.keyTyped(KeyEvent) - Part2: API Documentation and Comments
* Fix Bug 688: Removal of NEWT KeyEvent.EVENT_KEY_TYPED and ↵Sven Gothel2013-06-1729-138/+114
| | | | KeyListener.keyTyped(KeyEvent)
* Bug 735: Fix comment in test, since mystery is solved :)Sven Gothel2013-06-172-2/+4
|
* Solve Bug 735 Mystery: glViewport(..) was missing - duh :)Sven Gothel2013-06-172-0/+4
|
* Bug735: Bug735Inv0AppletAWT/Bug735Inv1AppletAWT tests: Use shader ↵Sven Gothel2013-06-172-6/+7
| | | | customization, no Clear required, .. (still don't work w/ CALAyer)
* Fix Bug 753: Stuttering caused by lack of GL resource synchronization ↵Sven Gothel2013-06-179-12/+3802
| | | | | | | | | | | | | | | | | | | | | between Java GL- and CALayer thread ; Simplify / Fix waitUntilRenderSignal(). Stuttering caused by lack of GL resource synchronization between Java GL- and CALayer thread + // Required(?) to finish previous GL rendering to give CALayer proper result, + // i.e. synchronize both threads each w/ their GLContext sharing same resources. + // + // FIXME: IMHO this synchronization should be implicitly performed via 'CGL.flushBuffer(contextHandle)' above, + // in case this will be determined a driver bug - use a QUIRK entry in GLRendererQuirks! + gl.glFinish(); Simplify / Fix waitUntilRenderSignal() - remove loop and 'ready' condition -> nonsense - if too later, i.e. lastWaitTime+TO < now, use now+TO as max. vsync waiting time Bug735 Tests: - Make vsync, wait and ECT (exclusive context thread) configurable via main args. - Inv2*, Inv3* and Inv4*: Fluent Animation - Works w/ ECT
* Bug 735: Bug735Inv4AWT on Java7 is also stuttering!Sven Gothel2013-06-164-12/+11
|
* Bug 735: Adding Andres test cases for analysis. OSX exposes diff. odd ↵Sven Gothel2013-06-1610-0/+2467
| | | | behaviors - See BugXYZ test cases.
* Fix Bug 745: NPE - QTT definition shall be allowd to _follow_ SOF (frame) - ↵Sven Gothel2013-06-142-2/+19
| | | | Reference QTT via QTT[] passed to frame, validate after parsing.
* TestRedSquareES2NEWT: CleanupSven Gothel2013-06-131-8/+11
|
* TestX11DefaultDisplay: Validate the chosen default device, test only one ↵Sven Gothel2013-06-131-75/+61
| | | | GLDefault/RedSquareES1; Tested w/ Xvnc4 + build-in Mesa 4.0.4
* added unit test for nativewindow.x11.display.default system propertyMaik Riechert2013-06-131-0/+158
|
* Bug 733: Refine Test case: warp-random at display, and warp-center at ↵Sven Gothel2013-06-121-9/+64
| | | | mouse-leave.
* Adds a unit test for GLWindow.warpPointer(int,int)Julien Gouesse2013-06-121-0/+116
|
* Fix Bug 748 - PMVMatrix gluProject and gluUnProject broken w/ backingArray ↵Sven Gothel2013-06-091-0/+125
| | | | | | | | | (default) ; Also: Use FloatUtil in-place multMatrixf. PMVMatrix gluProject(..) and gluUnProject(..) don't pass their position (offset) to the multMatrixf operation - even though they are sliced. The API doc actually emphasizes this.
* Adapt to Gluegen's IOUtil change commit b98825eb7cfb61aead4a7dff57471cd2d2c26823Sven Gothel2013-06-091-2/+2
|
* ScreenMode Unit Tests: Add wait for screen destroy (off-thread)Sven Gothel2013-06-094-1/+12
|
* Unit Tests: Group *math* tests in own test packageSven Gothel2013-06-095-7/+7
|
* GLVersionNumber.createVendorVersion(): Only test match result and ↵Sven Gothel2013-05-311-5/+11
| | | | potentially continue matching if having a pattern-match (don't loop for-ever).
* Complete/Fix GLVersionNumber (81afec4e963ac4372dc2b604d6f91237b81ee6f2): Set ↵Sven Gothel2013-05-311-2/+27
| | | | | | 'valid' flag, always set major/minor and strEnd. Also: Add negative tests to unit test.
* GLVersionNumber: Fix vendor version parser; Adapt to GlueGen commit ↵Sven Gothel2013-05-311-0/+170
| | | | | | | | | | | | | | | 959d6d83ec26152343d538287c02eeebf0dcf238 Adapt to GlueGen commit 959d6d83ec26152343d538287c02eeebf0dcf238: - Use only RegExp and cache default (no wrapped whitespace tokenizer) - String match: Store end-of-match and flag defined components. - Remove manual parsing, utilize VersionNumber - No need to look further for 'updated' GL version, (probably the vendor version), since we utilize the ARB version number as set at creation. Fix vendor version parser: - Cut off GL version part of versionString (fixes case where GL version was interpreted as vendor version) - Loop through remaining string until a valid version number w/ major.minor has been found
* Unit Test: Remove unused importSven Gothel2013-05-181-1/+0
|
* Fix Unit Tests Exclusion " if( !GLProfile.isAvailable(GLProfile.GL*) ) { .. ↵Sven Gothel2013-05-187-0/+10
| | | | } ": Add missing return statement to abort test.
* Fix Bug 711: Align Graphs's Curve Shader programmatically to used GL/GLSL ↵Sven Gothel2013-05-171-2/+17
| | | | version, following all other internal GLSL usage utilizing ShaderCode.
* Fix Bug 737: Add shader default precision for GLSL [1.30 .. 1.50[ - See GLSL ↵Sven Gothel2013-05-1711-36/+162
| | | | Spec [1.30 - 1.40].
* NEWT: MouseEvent Ctor: Use proper float[] rotationXYZ and float ↵Sven Gothel2013-05-161-1/+2
| | | | rotationScale arguments.
* Fix Bug 731: GLJPanel: Access global GLPixelBuffer via ↵Sven Gothel2013-05-091-8/+7
| | | | SingletonGLPixelBufferProvider, if provided - releasing prev. smaller GLPixelBuffer after resize.
* Refactor: TextureData's PixelAttributes/PixelBufferProvider -> ↵Sven Gothel2013-05-089-36/+143
| | | | | | | | | | | | | | | | | | | | | | | GLPixelBuffer/.. and enhance usage; GLJPanel: Use GLPixelBuffer* API and SingleAWTGLPixelBufferProvider if possible. Refactor: TextureData's PixelAttributes/PixelBufferProvider -> GLPixelBuffer/.. and enhance usage - GLPixelBuffer, GLPixelAttributes and GLPixelBufferProvider have potential for wider audience, hence extract them to package 'com.jogamp.opengl.util'. - Using GLPixelBuffer, shall attempt to use pack/unpack row-stride, i.e. GL2GL3.GL_PACK_ROW_LENGTH, or GL2GL3.GL_UNPACK_ROW_LENGTH. See GLReadBufferUtil and GLJPanel - AWTGLPixelBuffer*: Attribute 'row-stride' allows reusing a bigger buffer than requested. GLJPanel: Use GLPixelBuffer* API and SingleAWTGLPixelBufferProvider if possible. - Use GLPixelBuffer API to remove redundancies - Attempts to use SingleAWTGLPixelBufferProvider to save JVM/CPU heap space for BuffereImage and IntBbuffer (readBack) Added unit new test demonstrating multiple overlapping GLJPanels reusing (or not) a singlton SingleAWTGLPixelBufferProvider.
* Add TestGearsGLJPanelAWT, i.e. multiple JPanels w/ GLJPanel running GearsES2 ↵Sven Gothel2013-05-0811-31/+388
| | | | | | in their own color. Note: JComponent will introduce flickering if using opaque rendering mode!
* GLJPanel: Use PixelBufferProvider AWTPixelBufferProviderInt; ↵Sven Gothel2013-05-081-0/+266
| | | | | | PixelBufferProvider: Add 'dispose()' to interface. Transition reusing AWT specific PixelBufferProvider to allow a later user provided PixelBufferProvider.
* MonitorMode: Fix API doc / comments / names.Sven Gothel2013-05-071-6/+6
|
* MonitorMode Unit Tests: Perform 'filterByRate(..)' _after_ ↵Sven Gothel2013-05-065-12/+11
| | | | 'filterByResolution(..)' (desired resolution)
* Fix GLSL Version Exposure: Type in 'static' GL -> GLSL matching, don't set ↵Sven Gothel2013-05-069-10/+10
| | | | GLSL version if GLSL is n/a
* Fix Bug 600 and Bug 721: Adding support for multiple monitors w/ NEWTSven Gothel2013-05-0619-299/+916
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Support for all monitor devices and their available modes - X11: Use RandR 1.3 if available - Retrieve information - Changing a monitor device's mode - Support for dedicated and spannig fullscreen - See <http://jogamp.org/files/screenshots/newt-mmonitor/html/> - TODO: - X11 RandR does _not_ relayout the virtual screen size and neither the CRT's viewport. We may need to relayout them if they were covering a seamless region to achieve same experience! - OSX: No machine to attach a secondary CRT -> TEST! - Tested Manually for Regressions - Linux ARMv6hf (Rasp-Pi/BCM, Panda/X11) - Android (Huawei, Kindle) - Tested Manually and junit: - X11/Linux - NV, ATI-Catalyst w/ 2 CRTs - VBox w/ 4 CRTs - Win/Windows - NV, w/ 2 CRTs - VBox w/ 4 CRTs - X11/OpenIndiana, NV, 1 CRT
* GLReadBufferUtil: Utilizing PixelBufferProvider; Adding AWTGLReadBufferUtil ↵Sven Gothel2013-04-274-20/+263
| | | | adding BufferedImage support; Demonstrating w/ unit tests.
* TextureData: Add PixelAttributes and PixelBufferProvider; ColorSink back to ↵Sven Gothel2013-04-273-8/+4
| | | | | | | | | | | | | | | | JPEGDecode (not general enough) - TextureData: Add PixelAttributes and PixelBufferProvider - PixelBufferProvider is intended as a pattern allowing producers (i.e. GLReadBufferUtil) to utilize custom pixel buffer for various intend. - PixelAttributes can be chosen by PixelBufferProvider implementation and groups the texture's pixel/data format and type. TextureData uses PixelAttributes internally now. - ColorSink back to JPEGDecode (not general enough) - Partially reverts 94ea306d1809290db678d3181619bdc39d4334bb
* Fix Bug 722: Make GLEventListenerState 'transaction' safe Animator.pause[ ↵Sven Gothel2013-04-235-44/+229
| | | | | | | | | | | | | | | | | | | | | surface.lock[ modify ] ] GLEventListenerState: New model for GLEventListenerState's transaction safety: - Z Decorate-1: Animator.pause [ X ] Animator.resume - X Decorate-2: Surface.lock [ Y ] Surface.unlock - Instead of setting AbstractGraphicsDevice, just swap the handle and ownership. - Issuing setRealized(..) only if required, i.e. having an upstream-surface (EGL..) depending on used device - Utilizing setRealized(..) on the GLAD's delegated 'real' drawable, avoiding optional GLAD locking. - Cleanup and above changes shall render impl. easier to read. GLEventListenerState Unit Tests: - If swapping/moving from AWT -> NEWT, use a NEWT dedicated Display avoiding ATI driver XCB crash - read comment.
* Bug 718: WindowsBitmapWGLDrawable: Requires GLProfile.GL2, fix BITMAP GLCaps ↵Sven Gothel2013-04-181-0/+182
| | | | | | | | | ASAP at Ctor instead of setRealized(true); WindowsWGLContext: Exclude ARB creation for BITMAP Unit Test TestGLAutoDrawableFactoryGLnBitmapCapsNEWT added using BITMAP on GLProfile.getDefault() Also: X11GLXContext, WindowsWGLContext: Cleanup formatting in createImpl(..)
* Fix Bug 720: Unify all platform specific GLContextImpl specializations; Fix ↵Sven Gothel2013-04-182-17/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug 719 - Windows BITMAP Offscreen Orientation is not propagated through API Fix Bug 719 - Windows BITMAP Offscreen Orientation is not propagated through API Depends on Bug 720, since cleaning up GLContextImpl* is required to move property 'GLContext.isGLOrientationFlippedVertical()' to 'GLDrawable.isGLOriented()' where it belongs! Windows BITMAP GLDrawable impl. isGLOriented() shall return false, while we keep the BITMAPINFOHEADER's height field negative to remove the need for vertical flip when used w/ AWT or Windows, .. Then property 'GLDrawable.isGLOriented()' has to be recognized throughout the utility functions, i.e. TextureData's mustFlipVertically and hence TextureIO writer. Fix Bug 720: Unify all platform specific GLContextImpl specializations GLContextImpl shall have only _one_ unique platform derivative to allow proper swapping of GLDrawables of any type via: - 'GLAutoDrawable.setContext(GLContext newCtx, boolean destroyPrevCtx)', which calls - 'GLContext.setGLDrawable(GLDrawable readWrite, boolean setWriteOnly)' Exception: External context may be specialized. All drawable specific property handling shall be provided and implemented (if possible) via GLDrawable specializations. - GLContext.isGLOrientationFlippedVertical() -> GLDrawable.isGLOriented() - PNGImage.createFromData() takes 'isGLOriented' to properly handle vertical flipping simply by line ordering - TextureIO's PNG writer passes TextureData's getMustFlipVertically() as isGLOriented to PNGImage.createFromData() - GLReadBufferUtil respects GLDrawable's isGLOriented() when creating TextureData instance. - Screenshot respects GLDrawable's isGLOriented() - Screenshot is deprecated, use GLReadBufferUtil. - Removed all PBuffer attributes, i.e. floatingPoint, RenderToTexture and RenderToTextureRectangle. - Allows removal of special pbuffer handling in GLContext* implementations. - Removed also from GLCapabilities* - Removed from deprecated GLPbuffer Impact: - Low, users who desire to render into a texture shall use our FBO GLOffscreenDrawable. - Only use case was the deprecated GLPbuffer - floating point framebuffer technology is still patented anyways :) - Removed Java2DGLContext, which was only used for OSX's GLJPanel Java2D bridge, which is no more supported anyways.
* Bug 718: Windows BITMAP Offscreen Fails w/ GLCaps other than simple RGB888 - ↵Sven Gothel2013-04-177-104/+578
| | | | | | | | | Refine Unit Tests ; UITestCase.Snapshot: Add RGBA bits to filename. Split TestGLAutoDrawableFactoryOffscrnCapsNEWT to TestGLAutoDrawableFactoryGL2OffscrnCapsNEWT and TestGLAutoDrawableFactoryES2OffscrnCapsNEWT TestGLAutoDrawableFactoryGL2OffscrnCapsNEWT contains more 'Bitmap' tests of various caps, w/ snapshots.