summaryrefslogtreecommitdiffstats
path: root/src/test/com
Commit message (Collapse)AuthorAgeFilesLines
* Bug 885 - GLMediaPlayer: Allow single threaded mode - Especially where ↵Sven Gothel2013-11-011-50/+50
| | | | | | | | | | | | multiple media textures (Android) or shared GL context are not usable. - GLMediaPlayer: - TEXTURE_COUNT_MIN is the new minimum: '1' - i.e. no multithreading, single threaded player - TEXTURE_COUNT_DEFAULT is '4' - multithreaded - GLMediaPlayerImpl: - Add Single threaded mode, but perform initStreamImpl(..) off-thread. -
* Bug 852: Add unit test TestCPUSourcingAPINEWT validating CPU sourcing, i.e. ↵Sven Gothel2013-11-012-3/+225
| | | | expecting exception w/ core profile!
* Clarify Bug 692: Unbinding a VAO does _not_ imply unbinding of set VBOs ↵Sven Gothel2013-11-011-36/+127
| | | | | | | | | | | | | | | | | | | | | (spec doesn't mention it, and it does not show results w/ CPU sourced rendering) ; Clean up GLBuffer*Tracker + * Note that VAO initialization does unbind the VBO .. since otherwise they are still bound + * and the CPU_SRC test will fail!<br/> + * The OpenGL spec does not mention that unbinding a VAO will also unbind the bound VBOs + * during their setup.<br/> + * Local tests here on NV and AMD proprietary driver resulted in <i>no ourput image</i> + * when not unbinding said VBOs before the CPU_SRC tests.<br/> + * Hence Bug 692 Comment 5 is invalid, i.e. <https://jogamp.org/bugzilla/show_bug.cgi?id=692#c5>, + * and we should throw an exception to give users a hint! Leaving uncommented code in GLBufferStateTracker .. +++ - Clean up GLBuffer*Tracker - Use final - Use static final keyNotFound value.
* Bug 882 - Crash on OSX when closing NEWT window - Fix: Release NewtMacWindow ↵Sven Gothel2013-11-011-0/+140
| | | | | | | | | | manually in close0() Release NewtMacWindow manually in close0() - Mark [NewtMacWindow setReleasedWhenClosed: NO] in init0(..) - Release NewtMacWindow manually in close0(..) Check pointer args in close0(..)
* GLDrawableFactory: createDummy*(..) Pass GLCapabilitiesImmutable + ↵Sven Gothel2013-10-312-2/+2
| | | | GLCapabilitiesChooser instead of GLProfile, allowing using same or similar caps - important for sharing ctx
* TestBinary16NOUI: Remove hardship from test node - Disable 'verbose' avoids ↵Sven Gothel2013-10-311-49/+79
| | | | 'out of memory' and saves most of the time; Also run test exclusively.
* Fix Bug 878 - JAWTWindow's HierarchyListener doesn't set component visible ↵Sven Gothel2013-10-311-0/+175
| | | | | | | | | | | | | | | | | | | (again) on 'addNotify(..)' - GLCanvas in JtabbedPane disappear Regression of commit e33e6374e0be0454f7e9732b5f897f84dbc3c4dc (Fix for Bug 729 and Bug 849) ! +++ JAWTWindow's HierarchyListener doesn't set component visible (again) on 'addNotify(..)' It only renders the component invisible after removeNotify() which is performed implicit anyways .. Case java.awt.event.HierarchyEvent.DISPLAYABILITY_CHANGED shall perform similar as our java.awt.event.HierarchyEvent.SHOWING_CHANGED impl. +++ Tested on Gnu/Linux X11 and OSX incl. re-test Bug 729 and Bug 849 unit tests.
* Test Rename: Add Bug 729 / Bug 849 to Bug 816 Unit Test Names - Allowing a ↵Sven Gothel2013-10-314-8/+7
| | | | better unit test lookup
* Rename Binary*Test -> TestBinary*NOUI to get picked up by build-test.xml's ↵Sven Gothel2013-10-313-3/+3
| | | | junit.run.noui
* Merge remote-tracking branch 'mraynsford/mark'Sven Gothel2013-10-313-0/+871
|\
| * Add functions for converting to and from binary16 half-precision floating ↵Mark Raynsford2013-10-313-0/+871
| | | | | | | | point values. Derived from http://mvn.io7m.com/ieee754b16, of which I am the original author.
* | TestSharedContextVBOES2NEWT1: Fix copy/paste (mistakenly used sharedGears), ↵Sven Gothel2013-10-312-3/+5
|/ | | | add println; GearsES: Add init/shared state to 'toString()'
* Fix Unit Test Regression (commit 9f2a9df0a4b7093925c8854b37fba053469a4b35): ↵Sven Gothel2013-10-302-22/+20
| | | | GearsObject used getGL2ES2(), which is not allowed.
* Bug 776 GLContext Sharing: GLSharedContextSetter API Doc: Add 'glFinish()' ↵Sven Gothel2013-10-306-0/+37
| | | | to lifecycle considerations ; GearsES2: Add glFinish() after init().
* Bug 776 GLContext Sharing: GLSharedContextSetter API Doc: No 'Driver ↵Sven Gothel2013-10-306-27/+21
| | | | | | | | | | | | | | stability constraints' ; Fixing Test cases: Enable all, GearsObject*: Check VBO - GLSharedContextSetter API Doc: No 'Driver stability constraints' - No driver issues .. - Use 'Lifecycle Considerations' to describe usage issues .. - Fixing Test cases: Enable all, GearsObject*: Check VBO - GearsObject* needs to check whether VBO is 'still alive' if sharing is enabled. - Enable all unit tests.
* Bug 776 GLContext Sharing: Add copy-ctor to GLArrayData* w/ sliced Buffer; ↵Sven Gothel2013-10-295-58/+65
| | | | | | | | | | | Refine GearsObject* GLArrayDataServer copying; GearsES*: Init VBO eagerly Add copy-ctor to GLArrayData* w/ sliced Buffer to allow general sharing of VBO via these high-level types. Refine GearsObject* GLArrayDataServer copying (commit bcfaa149b9803ce33c5a356cbcb45f7dfd3e4361): Utilize new GLArrayData* copy-ctor. GearsES*: Init VBO eagerly, allowing VBO usage after init(..).
* Fix TestSharedContextNewtAWTBug523: Don't use VAO's w/ GL2 context - No VAO ↵Sven Gothel2013-10-291-80/+112
| | | | on GL2 ctx on OSX ; GLWindow #2 shall also use sharedDrawable; Cleanup ..
* Bug 776 GLContext Sharing: Add GLSharedContextSetter to SWT GLCanvasSven Gothel2013-10-286-53/+420
|
* Bug 776 GLContext Sharing: Add note about driver stability (destruction ↵Sven Gothel2013-10-2811-135/+354
| | | | | | | | | | | | | | | | | | | | | order) ; Fix unit tests (Shared Gears, wait for created context and destruction order) - Add note about driver stability (destruction order) - See GLSharedContextSetter: Don't destroy master context before slaves! - Fix spec-overview.html#SHARED links, add link to GLSharedContextSetter in SHARED subsection. - Fix unit tests (Shared Gears, wait for created context and destruction order) - The GearsObject sharing was completly bogus! It simply used the _same_ GLArrayDataServer instance for sharing, but it should use a _copy_ of the shared GLArrayDataServer while only preserving the VBO object! Fixed, while adding required methods to GLArrayDataServer. - Waiting for the created GLContext of a GLAutoDrawable required us to pass the latter _and_ check whether it's GLContext exists and is natively created. - Accomodated the destruction order - see above!
* Bug 776 GLContext Sharing: Add GLSharedContextSetter to GLJPanelSven Gothel2013-10-272-1/+322
|
* Fix GLCanvas ctor shared GLContext: Use helper.setSharedContext(..) remove ↵Sven Gothel2013-10-272-1/+2
| | | | | | local shared ctx fields. Regression of 7f7a23dd0ddf106e6f0c69fc2a05ff92ac56200e
* Bug 776 GLContext Sharing: Refine API for relaxed and lazy GLContext sharing ↵Sven Gothel2013-10-2733-892/+2547
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ; Fix GLContext memory contract (volatile) (Unit test remarks see below) - Add shared GLContext queries - Refined GLContextShareSet: - Use IdentityHashMap since GLContext's can only be identical w/ same reference (footprint, performance) - Add API doc for clarification - Add methods: - ArrayList<GLContext> getCreatedShares(final GLContext context) - ArrayList<GLContext> getDestroyedShares(final GLContext context) - Use 'final' where possible - Add GLContext methods: - boolean isShared() - List<GLContext> getCreatedShares() - List<GLContext> getDestroyedShares() - Add GLSharedContextSetter interface defining setting a shared GLContext directly (GLContext) or via a GLAutoDrawable: - setSharedContext(GLContext) - setSharedAutoDrawable(GLAutoDrawable) Both cause initialization/creation of GLAutoDrawable's drawable/context to be postponed, if the shared GLContext is not yet created natively or the shared GLAutoDrawable's GLContext does not yet exist. Most of impl. resides in GLDrawableHelper Implemented in: - GLAutoDrawableBase, GLOffscreenAutoDrawable - GLWindow - AWT GLCanvas TODO: - GLJPanel - SWT GLCanvas - GLDrawableFactory: - Add 'GLOffscreenAutoDrawable createOffscreenAutoDrawable(..)' variant w/o passing the optional shared GLContext _and_ specifying lazy GLContext creation. This allows to benefit from GLSharedContextSetter contract. Lazy GLContext creation is performed at 2st display() call at the latest. All JOGL code and unit tests use this new method now. - Mark 'createOffscreenAutoDrawable(..)' w/ shared GLContext argument and immediate GLContext creation deprecated - shall be removed in 2.2.0 - Make reference to GLContext and it's native handle volatile Since we rely on the query 'GLContext.isCreated()' to properly allow GLAutoDrawable's to query whether a shared GLContext is natively created (already), the handle must be volatile since such query and the actual creation may operate on different threads. +++++ - Add/Refine shared GLContext unit tests demonstrating diff. sharing methods. All variants of using shared GLContext: com.jogamp.opengl.test.junit.jogl.acore.TestSharedContextVBO* Most convenient way to share via setSharedAutoDrawable(GLAutoDrawable): com.jogamp.opengl.test.junit.jogl.acore.TestSharedContextVBOES2[NEWT|AWT]3 AWT use w/ JTabbedPane using setSharedAutoDrawable(GLAutoDrawable): com.jogamp.opengl.test.junit.jogl.acore.TestSharedContextWithJTabbedPaneAWT
* TestGLProfile00NEWT: Dump Desktop's and EGL's default-device GLProfilesSven Gothel2013-10-251-1/+17
|
* GLProfile: Fix native profile mapping, i.e. use actual mapped profile-impl ↵Sven Gothel2013-10-251-5/+7
| | | | | | | | | | | | | | | | as detected and mapped by GLContext ; Enhance glAvailabilityToString(..) We shall not map profile == profile-impl, i.e. GL3 -> GL3, but use GLContext.getAvailableGLProfileName(device, reqMajor, reqProfileBits). The latter reflects the actual mapped context as detected. glAvailabilityToString(..) - Partition result in [Natives, Common and Mappings] - Mappings dumps mapped keys to profiles, while excluding default. Default is added at last. - Add count.
* Use org.junit.Assert instead of deprecated junit.framework.AssertSven Gothel2013-10-257-304/+300
|
* Bug 867 OSX [Common Code]: Trigger GLRendererQuirks.GL4NeedsGL3Request and ↵Sven Gothel2013-10-251-31/+37
| | | | | | | | | | | | | | | | | | | | | | | | make it sticky; Only alias profiles if HW-Accelerated! Only alias profiles if HW-Accelerated! GLContextImpl.mapGLVersions(..) shall not map a higher profile to a lower if it is a software renderer. +++ GLContextImpl.mapGLVersions(..) attempts to trigger GLRendererQuirks.GL4NeedsGL3Request if OSX 10.9 by creating a GL3 core context first. +++ GLContextImpl.setGLFunctionAvailability(): - On OSX 10.9: Detect GLRendererQuirks.GL4NeedsGL3Request and make it sticky (per device) while 'withinGLVersionsMapping' - Merge sticky quirks w/ local quirks +++ TestGearsES2NEWT: Add cmdline '-gl2' to force GL2 profile.
* PinchToZoomGesture: Add ctor arg 'allowMorePointer', should be false to be ↵v2.1.1Sven Gothel2013-10-191-61/+63
| | | | more stable (i.e. only 2 pointer pressed)
* MouseEvent: Clarify 'Multiple-Pointer' w/ button[mask] semantics, ; ↵Sven Gothel2013-10-173-4/+4
| | | | | | | | | | | | | | InputEvent: getButtonDownCount() and isAnyButtonDown(); - Clarify 'Multiple-Pointer' w/ button[mask] semantics - Pointer IDs start w/ 0 and are consecutive numbers. - 'button' == triggering pointer-ID - buttonMask in modifiers show pressed button _and_ pointer-IDs - deprecated BUTTON_NUMBER -> use BUTTON_COUNT (name semantics)
* AWTPrintLifecycle.setupPrint(..): Add optional tileWidth and tileHeight, ↵Sven Gothel2013-10-159-58/+98
| | | | allowing user to set custom tile size for performance evaluation/tweak
* Bug 861 - NEWT: Unify MouseEvent Processing incl. gesture processingSven Gothel2013-10-152-89/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We processed MouseEvents within NEWT as follows: sendMouseEvent/enqueueMouseEvent -> doMouseEvent, - called by native code to be delivered via consumeMouseEvent (now or later) - events are validated (move/drag, boundaries) - missing events are synthesized (click, enter, ..) as well as in several factories, i.e.: - AWTNewtEventFactory (1:1) - AndroidNewtEventFactory - synthesized events .. (click, ..) - android typed gesture detection (drag -> 1 finger scroll..) The latter enqueues events do Window/Display directly to be consumed by WindowImpl. Then users may have their own gesture detection etc. +++ This change unifies mouse/pointer event processing within NEWT within consumeEvent(..) which represents a common entry point. Gesture processing is now realized w/ a public API - GestureHandler - GestureHandler.GestureListener - GestureHandler.GesureEvent which supplies: - default impl. of optional gesture handlers (scroll, .. - default: enabled) - public API to add/remove gesture-handler and -listener +++ This allows our impl. to scale better in support of more multiple pointer devices (-> Win7/Win8, X11, ..).
* GLMediaPlayer: Fix CameraInputScheme URI doc and Android test streams (Use ↵Sven Gothel2013-10-154-6/+6
| | | | mp4 instead of webm, fix Camera URI)
* Bug 365: Add unit test, which run's through most of the ScaleInternal ↵Michael Esemplare2013-10-131-0/+272
| | | | functions for a single column image.
* Bug 859: Let TileRenderer detect zero columns and rows in eot() where ↵Sven Gothel2013-10-123-26/+94
| | | | beginTile() throws an EOT IllegalStateException to avoid division by zero
* Bug 852: Validate CPU sourced data API is allowed, throw exception if not. ↵v2.1.0Sven Gothel2013-10-101-1/+0
| | | | GLContext: isCPUSourcedAvail() -> isCPUDataSourcingAvail()
* NEWT Reparent/Fullscreen: Add 'waitForPosition(..)' when reparenting or back ↵Sven Gothel2013-10-091-1/+0
| | | | from fullscreen; JOGLNewtAppletBase: Reparent to pos 32/32, trying to avoid browser window focus/top stealing on X11.
* Bug816 OSX CALayer: Issue w/ JSplitPane within Apple (Firefox, Safari - not ↵Sven Gothel2013-10-093-1/+208
| | | | | | | appletviewer) when move horizontal slider (vertical: ok) Moving horizontal slider if run as applet (Firefox, Safari - not appletviewer) doesn't move the GLCanvas even though it is resized.
* NewtCanvasAWT Focus Traversal: Remove AWT's requestFocus*() overrides in ↵Sven Gothel2013-10-091-3/+3
| | | | | | | | | | favor of FocusPropertyChangeListener requestFocusNEWTChild() The AWT's requestFocus*() overrides were intended to receive the AWT focus (default) and clear it afterwards to forward the focus to the NEWT component -> requestFocusNEWTChild(). This can be achieved simply by using our FocusPropertyChangeListener and invoking requestFocusNEWTChild() when receiving the focus on the NewtCanvasAWT component.
* NEWT Reparent/Fullscreen: Fixes X11 unsuccessful return to parent window; ↵Sven Gothel2013-10-097-146/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add reparentWindow(..) top-level position arguments; Misc - Fixes X11 unsuccessful return to parent window On X11 when returning to parent window (-> CHILD), we have to set the window invisible and wait for the result. Otherwise it sometimes happens that the WM's reparent operation fails, i.e. the window won't become a child of desired parent and is positioned randomly. - Add reparentWindow(..) top-level position arguments .. allows bringing the child-window to top-level w/ a desired position. Otherwise the window would be positioned elsewhere as a top-level as the plain reparenting operation. X11 needs to set position and size _after_ making the window visible, otherwise WM may ignore the XConfigureWindow request. - Reparent recreate shall always store the desired position and size On OSX/CALayer when recreation is being used, we need to store the pos/size for later creation. - Tests: Use 'NewtAWTReparentingKeyAdapter' where possible (reparent/fullscreen) instead of duplicating such code. NewtAWTReparentingKeyAdapter: Performs reparenting and fullscreen operations off-thread (i.e. not on AWT/NEW EDT) while decorating the action w/ revoking/restoring the ExclusiveContextThread (ECT). Manually tested 'TestGearsES2NewtCanvasAWT' reparenting and fullscreen on X11, Windows and OSX/CALayer w/ JDK 7u40 successful.
* NEWT Display: Issue EDTUtil.start() at runOnEDTIfAvail(..) even if on EDT, ↵Sven Gothel2013-10-091-1/+1
| | | | | | | | | | | | | | | | | which is to be stopped. This case appears on e.g. OSX/CALayer (offscreen) reparenting using recreation (onscreen <-> offscreen), i.e. display destroy/create is performed on EDT. Misc Cleanup: - Rename EDTUtil: restart() -> start() - Rename Display: validateEDT() -> validateEDTStopped() - Simplify Display.setEDTUtil(..): Remove need for redundant 'newEDTUtil' local var. - Simplify Display.runOnEDTIfAvail(..): edtUtil is never null
* Bug 729, Bug 849: Honor JAWTWindow's [parent] visibility stateSven Gothel2013-10-063-4/+358
| | | | | | | | | | | | JAWTWindow snoops HierarchyEvents for SHOWING_CHANGED to track local component's visibility state as well as it's global visibility state. The later is determined by it's parent's visibility change. If 'removeNotify()' is called, component's visibility is reset to it's local visibility state. Fixes OSX CALayer component's visibility if parent's visibility changes (Bug 729). Fixes continuous GL rendering if parent is invisible (Bug 849).
* Bug 729: OSX CALayer invisible needs to have opacity 0 to not show hidden ↵Sven Gothel2013-10-061-1/+4
| | | | | | | | component. Completes commit 3b02a219b1b9e446e87df1beb7da4266f74824fa See unit test: TestBug816OSXCALayerPos03AWT
* Bug816 OSX CALayer: getLocationOnScreenNonBlocking(..) stop traversing at ↵Sven Gothel2013-10-055-3/+307
| | | | | | | | | | top-level heavyweight Window, fixes [J]Dialog use case. Top-level heavyweight Window's position is it's position on screen, hence stop traversing. Thx to Emmanuel Puybaret for pointing this out. Adding Dialog and JDialog unit tests as inspired by Emmanuel Puybaret.
* Bug 816/848: Cleanup test applet layout/size ; Note Bug 848: Not ↵Sven Gothel2013-10-043-7/+113
| | | | reproducible after restart of OSX test machine!
* Bug 848: Add test applet ; Bug 816 Bug816AppletGLCanvas02: Remove 2nd ↵Sven Gothel2013-10-043-106/+187
| | | | Animator ; Fix intendation (TAB -> WS)
* Bug 816: Add 2 more unit tests (Swing JFrame w/ 2 JRootPanes, AWT Frame ↵Sven Gothel2013-10-033-25/+304
| | | | | | BorderLayout w/ Checkbox North, GLCanvas Center) Thx to Emmanuel Puybaret
* Bug818GLJPanelApplet: Remove unused importsSven Gothel2013-10-031-2/+0
|
* Bug 818 (OSX 10.6.8 NVIDIA GeForce GT 330M): Add unit test (manual applet)Sven Gothel2013-10-031-0/+308
|
* GLJPanel/Printing: Perform backend.reshape immediatly after printing if ↵Sven Gothel2013-09-295-46/+112
| | | | | | | resized; Add unit test for resize while printing. Perform immediatly reshape at releasePrint on AWT-EDT: - sendReshape = handleReshape(); // reshapeSize -> panelSize, backend reshape w/ GL reshape
* AWT Printing: releasePrint() issue reshape from AWT-EDT; GLJPanel: Issue ↵Sven Gothel2013-09-281-0/+13
| | | | 'handleReshape' if panelSize/awtSize mismatch, otherwise 'sendReshape' and exception if offscreen size doesn't match panelSize.
* Test AWT Printing: Frame size contains border/insets, use as-is for scaling; ↵Sven Gothel2013-09-273-25/+22
| | | | Only force TEXT AA print-rendering hint.