aboutsummaryrefslogtreecommitdiffstats
path: root/make/scripts/tests.sh
Commit message (Collapse)AuthorAgeFilesLines
* Bug 776 GLContext Sharing: GLSharedContextSetter API Doc: Add 'glFinish()' ↵Sven Gothel2013-10-301-2/+2
| | | | to lifecycle considerations ; GearsES2: Add glFinish() after init().
* Bug 776 GLContext Sharing: GLSharedContextSetter API Doc: No 'Driver ↵Sven Gothel2013-10-301-3/+5
| | | | | | | | | | | | | | 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 GLSharedContextSetter to SWT GLCanvasSven Gothel2013-10-281-2/+2
|
* Bug 776 GLContext Sharing: Add note about driver stability (destruction ↵Sven Gothel2013-10-281-2/+5
| | | | | | | | | | | | | | | | | | | | | 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-271-1/+2
|
* Bug 776 GLContext Sharing: Refine API for relaxed and lazy GLContext sharing ↵Sven Gothel2013-10-271-12/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ; 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
* GLProfile: Fix native profile mapping, i.e. use actual mapped profile-impl ↵Sven Gothel2013-10-251-2/+2
| | | | | | | | | | | | | | | | 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.
* Bug 867 OSX [Common Code]: Trigger GLRendererQuirks.GL4NeedsGL3Request and ↵Sven Gothel2013-10-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | 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 ↵Sven Gothel2013-10-191-3/+3
| | | | more stable (i.e. only 2 pointer pressed)
* Fix Bug 862: Fix GL Version Validation / NVidia GTX550 driver 331.13 - 64bit ↵Sven Gothel2013-10-191-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Linux - No compatibility GLProfile (GL2, >= GL3bc) Fix GL Version Validation: We shall not rely on our known good versions when validating a queried GL context version, but allow some 'room' for a higher version post JOGL release while still cutting off 'odd versions'. While GL version detection, we always iterate from the highest known version down to the lowest. Hence 'GLContext.isValidGLVersion(..)' is satisfied by validating the lowest version number but allowing a higher than known one. Now we would return 'invalid' for a version >= 6. It is enough to clip to the maximum known version when iterating, allowing the highest unknown version to be available. GLContext.isValidGLVersion(..): Returns true, if the major.minor is not inferior to the lowest valid version and does not exceed the highest known major number by more than one. The minor version number is ignored by the upper limit validation and the major version number may exceed by one. The upper limit check is relaxed since we don't want to cut-off unforseen new GL version since the release of JOGL. Hence it is important to iterate through GL version from the upper limit and 'decrementGLVersion(..)' until invalid. Add GL Version 4.4 to valid known versions. Remove ES3 desktop detection, which is impossible Regression of commit 3a0d7703da32e9a5ddf08a334f18588a78038d88 (ES3 support)
* Bump 7u45Sven Gothel2013-10-181-3/+3
|
* MouseEvent: Clarify button-number and pointer-ID relation incl. case 'no ↵Sven Gothel2013-10-181-2/+2
| | | | | | | | | | button/pointer', i.e. button == 0, pointer-ID == -1 doPointerEvent: - allow id==-1 -> button==0 for no button, i.e. mouse move doMouseEvent: - keep button 0 value, i.e. map to pointer-ID -1
* AWTPrintLifecycle.setupPrint(..): Fix regression of commit ↵Sven Gothel2013-10-181-2/+2
| | | | | | | | | | | | a05b87a369441d9ef38f97929f866b3d4ced0e57: NULL printGLAD of GLCanvas and NewtCanvasAWT We have to pre-init printGLAD w/ current GLAD (similiar w/ GLJPanel). Also properly define reqNewGLAD: reqNewGLAD = !caps.getSampleBuffers() && ( reqNewGLADOnscrn || reqNewGLADSamples || reqNewGLADSize ); where '!caps.getSampleBuffers() && ( .. )' is due to Bug 830, swapGLContextAndAllGLEventListener and onscreen MSAA w/ NV/GLX does not work.
* Bug 800: Windows 7 Touch Event Support for NEWT: Fix Focus and ↵Sven Gothel2013-10-171-2/+2
| | | | | | | | | | | | | LBUTTON[DOWN|UP] issues - w/ TOUCH, Win8 may steal focus (KILLFOCUS), quickly grab FOCUS again when on TOUCH operation - track 'touchDownLastUp', and don't act on LBUTTON[UP|DOWN] and MOUSEMOVE if just lifted last finger - don't use GetMessageExtraInfo() to distinguish MOUSE/TOUCH, simply use tracked touchDownCount - Also track mouseInside in TOUCH operation, i.e. true if _all_ fingers are inside, otherwise don't send TOUCH event
* NEWT PointerEvent: Unify event processing in new doPointerEvent(..) and ↵Sven Gothel2013-10-171-2/+2
| | | | | | | | | | | | | | | consumePointerEvent(..) - Unifies native mouse and Android's pointer event, ready for Win7 touch Unify event processing in new doPointerEvent(..), which is also invoked from doMouseEvent(..), and consumePointerEvent(). doPointerEvent(..): Validates and modifies event data and finally creates the event, where consumePointerEvent(..) calls gesture handlers and may synthesize events. Unifies native mouse and Android's pointer event, ready for Win7 touch. AndroidNewtEventFactory calls doPointerEvent(..) directly. Removed lots of duplicated pointer event handling code.
* AWTPrintLifecycle.setupPrint(..): Add optional tileWidth and tileHeight, ↵Sven Gothel2013-10-151-2/+2
| | | | allowing user to set custom tile size for performance evaluation/tweak
* Bug 861 - NEWT: Unify MouseEvent Processing incl. gesture processingSven Gothel2013-10-151-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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, ..).
* Bug 365: Add unit test, which run's through most of the ScaleInternal ↵Michael Esemplare2013-10-131-1/+2
| | | | functions for a single column image.
* Bug 860 - AWT Printing (AWTTilePainter): Shall use the enclosing integer ↵Sven Gothel2013-10-121-2/+2
| | | | | | | | | | | | | | | | | rectangle of the scaled double precision clipping rect AWTTilePainter simply rounds the scaled double precision clipping rectangle to receive the integer rectangle. This leads to uncovered drawing areas, since the integer rectangle position could be greater - and the size could be smaller than the double precision source. To get the enclosing rectangle, we need to use iPos = floor(position) iSize = ceil(position+size) - floor(position) .. turns our that the double precision 'Rectangle Rectangle2D.getBounds()' already performs this math.
* Bug 859: Let TileRenderer detect zero columns and rows in eot() where ↵Sven Gothel2013-10-121-2/+2
| | | | beginTile() throws an EOT IllegalStateException to avoid division by zero
* Bug 852: Validate CPU sourced data API is allowed, throw exception if not. ↵Sven Gothel2013-10-101-2/+2
| | | | GLContext: isCPUSourcedAvail() -> isCPUDataSourcingAvail()
* NEWT Reparent/Fullscreen: Add 'waitForPosition(..)' when reparenting or back ↵Sven Gothel2013-10-091-2/+2
| | | | 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-091-3/+3
| | | | | | | 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.
* NEWT Reparent/Fullscreen: Fixes X11 unsuccessful return to parent window; ↵Sven Gothel2013-10-091-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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/Fullscreen (Bug 836): Exit re-parenting fullscreen w/ ↵Sven Gothel2013-10-071-3/+3
| | | | | | | | | | | | | | | [invisible-exit-visible] (-> like reparent); Always force focus; X11: Always use ALWAYSONTOP. - Remove unused 'fullscreenUseSpanningMode' state - Exit re-parenting fullscreen w/ [invisible-exit-visible] (-> like reparent) solves X11 issue, where the NEWT window doesn't 'return to it's parent'. Probably also fixes Bug 836! - Always force focus when enter and exit FS - X11: Always use ALWAYSONTOP No reason to behave different (spanning and normal-fs)
* Bug 729, Bug 849: Honor JAWTWindow's [parent] visibility stateSven Gothel2013-10-061-1/+3
| | | | | | | | | | | | 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-2/+2
| | | | | | | | component. Completes commit 3b02a219b1b9e446e87df1beb7da4266f74824fa See unit test: TestBug816OSXCALayerPos03AWT
* Bug816 OSX CALayer: getLocationOnScreenNonBlocking(..) stop traversing at ↵Sven Gothel2013-10-051-1/+3
| | | | | | | | | | 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.
* test scripts (test Bug 729 w/ TestAWTCardLayoutAnimatorStartStopBug532)Sven Gothel2013-10-051-2/+2
|
* AWTTilePainter: Avoid NPE if Graphic2D's AffineTransform is null, use ↵Sven Gothel2013-10-031-2/+2
| | | | identity tranform in such case.
* Bug 818: Enable new quirk GLSLNonCompliant on OSX < 10.7 w/ NV GPU; ↵Sven Gothel2013-10-031-2/+2
| | | | GLJPanel: Don't use GLSL flip if quirk GLSLNonCompliant is present.
* Bug 816: Add 2 more unit tests (Swing JFrame w/ 2 JRootPanes, AWT Frame ↵Sven Gothel2013-10-031-2/+4
| | | | | | BorderLayout w/ Checkbox North, GLCanvas Center) Thx to Emmanuel Puybaret
* GLJPanel/AWTGLPixelBuffer: Reused BufferedImage didn't account for ↵Sven Gothel2013-10-021-2/+2
| | | | | | | | | | | | | | | | | | | | | row-stride (regression of b33bdf41cf53f37203643a8551bf5d94b42a8fab) SingleAWTGLPixelBufferProvider w/ allowing row-stride reuses the AWTGLPixelBuffer and it's BufferedImage even w/ different width. This leads to distortion if using the BufferedImage unhandled. GLJPanel also set GL_PACK_ROW_LENGTH to pixelBuffer.width, which leads to an 'out-of-bounds' exception if ReadPixels is used w/ panelwidth and panelHeight. ++ Introduce AWTGLPixelBuffer.getAlignedImage(width, height) which returns an aligned BufferedImage while reusing the DataBuffer. GLJPanel fetches a new alignedImage if required. This allows a more efficient single buffer usage as intended, w/o the need of copying data.
* GLJPanel/Printing: Perform backend.reshape immediatly after printing if ↵Sven Gothel2013-09-291-2/+2
| | | | | | | 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
* Fix TileRenderer regression of commit ↵Sven Gothel2013-09-281-2/+2
| | | | | | c8abb9d2c9a8c92f0c5c42aba13e3e80c69739dc: Test isSetup() _after_ running glEventListenerPre. glEventListenerPre may be utilized to setup the TileRenderer.
* Fix Bug 816: JAWTWindow.getLocationOnScreenNonBlocking(..) shall use ↵Sven Gothel2013-09-271-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | JRootPane for last position offset; AWTMisc.getInsets(..) add special JRootPane case. Please note that we use JAWTWindow.getLocationOnScreenNonBlocking(..) to determine the location on the screen 'only' b/c we cannot allow AWT to aquire the tree-lock! The latter would be the case if using AWT's 'getLocationOnScreen()'. If anybody has a more reliable implementation to achieve the same .. please provide your patch! The following fix has been performed to fix the last issue w/ vZome. - JAWTWindow.getLocationOnScreenNonBlocking(..) shall use JRootPane for last position offset - w/ vZome, the frame's position was 0/0 (invalid), instead JRootPane's position is good. Use JRootPane's position and stop traversing here (LW top-level). - AWTMisc.getInsets(..) add special JRootPane case. + * Exception is JRootPane. + * Return it's parent's Window component's insets if available, + * otherwise return JRootPane's insets.<br> + * This is due to <i>experience</i> that <i>some</i> JRootPane's + * do not expose valid insets value. -
* Test AWT Printing: Frame size contains border/insets, use as-is for scaling; ↵Sven Gothel2013-09-271-2/+2
| | | | Only force TEXT AA print-rendering hint.
* Bug 816: Fix JAWTWindow's getLocationOnScreenNonBlocking(); Derive CALayer ↵Sven Gothel2013-09-271-2/+2
| | | | | | | | | | | | | | | | | | | | | | | position from AWT component's location on screen. Track fixedFrame size of root CALayer; Add Split layout to unit test, add [manual] Applet tests. - Fix JAWTWindow's getLocationOnScreenNonBlocking() Skip JRootPane while traversing up to root Container. JRootPane would duplicate the top-level container's offset (Window insets). - Derive CALayer position from AWT component's location on screen. Add Split layout to unit test, add [manual] Applet tests. AWT >= 7u40: - AWT position is top-left w/ insets, where CALayer position is bottom/left from root CALayer w/o insets. - Use getLocationOnScreenNonBlocking() to get location-on-screen w/o insets. - Native code: flip origin AWT < 7u40 still uses fixed position 0/0 for root and sub layer. - Track fixedFrame size of root CALayer - MyCALayer: - Override layoutSublayers to validate root and sub-layer pos/size - Override setFrame to use fixedFrame, if set (similar to MyNSOpenGLLayer) - Add Split layout to unit test, add [manual] Applet tests. - Thx to 'jimthev' and 'Manu' for providing Applet unit tests
* DirectDataBufferInt: createBufferedImage(..) use BufferedImage type value ↵Sven Gothel2013-09-271-2/+2
| | | | | | | | | | | | | | | | | | | | | instead of component-count, support all int types ; Add type 'BufferedImageInt' preserving the custom image-type, add note about TYPE_CUSTOM - createBufferedImage(..) use BufferedImage type value instead of component-count, support all int types - Support all integer data image-type, hence we need to pass image-type instead of component count (collision). - Also pass 'properties' to allow configuring all BufferedImage parameters (just in case) - Return BufferedImageInt to allow user to query the used image-type, see below. - Add type 'BufferedImageInt' preserving the custom image-type, add note about TYPE_CUSTOM - Simply extends BufferedImage w/ custom image-type, since BufferedImage's type is TYPE_CUSTOM due to our custom storage type (see API doc comment). Unit tests: - Testing all integer image-type's in - TestTiledPrintingGearsSwingAWT - TestTiledPrintingNIOImageSwingAWT - Disable all AA print-hints, all AWT text visible on X11. Probably has a regression on Windows / OSX .. TBD.
* Bug 816: Add unit test 'TestBug816OSXCALayerPosAWT'Sven Gothel2013-09-241-1/+3
|
* Fix Bug 839: Clarify whether resetStates(..) shall clearStates() - Pass ↵Sven Gothel2013-09-211-3/+3
| | | | 'isInit' flag.
* AWT Printing: Fix non vertical-flipped printing, i.e. cut-off top-row's tile ↵Sven Gothel2013-09-201-2/+2
| | | | | | | | | | | | | | | upper area, cleanup. TestTiledPrintingGearsSwingAWT2: Provoked !flipped bug where top-row was positioned too low due to using full size tile-height. Cutting of the unused top-row's upper area corrects this issue. vertical-flip mode does not expose this situation, since flipping shifts the payload to the upper tile area. TestTiledPrintingGearsSwingAWT2: Also tests an alternative transparent overlapping mode without layout.
* Fix Bug 826: GLJPanel: Fully restore TextureState and ViewportSven Gothel2013-09-201-1/+4
| | | | | | | | | | | | In FBO mode save TextureState of current texture-unit, as well as for the fbo texture-unit if the latter is a different. In glslTextureRaster mode for verical flip (using FBO), set the viewport to drawable size if before flipping and restore afterward - if equired. TestGLJPanelTextureStateAWT fully tests use cases: - Keep texture bound w/ same or other texture-unit - Use 2 viewports within one drawable and keep it
* AWTTilePainter: Fix case with no GLOrientation, i.e. no vertical-flip. Tile ↵Sven Gothel2013-09-181-3/+3
| | | | | | location and destination must follow same math as w/ vertical-flip. .. clipping and tile-height was not considered.
* Add 'DirectDataBufferInt' supporting NIO based BufferedImagesSven Gothel2013-09-161-1/+2
| | | | | | | | | | - Contains convenient method to create an NIO backed BufferedImage 'BufferedImage createBufferedImage(int width, int height, int numComponents, Point location)' Standalone test TestTiledPrintingNIOImageSwingAWT 'prints', i.e. renders offscreen, the Frame into - a traditional array-backed BufferedImage - an NIO-backed backed BufferedImage
* TestTiledPrintingGearsSwingAWT: Add a second demo GLEventListener showing ↵Sven Gothel2013-09-101-2/+2
| | | | it's working/scaling well; Adding TileRendererBase.TileRendererNotify to RedAquareES2 having a 3rd demo case.
* NewtCanvasAWT: Implement AWTPrintLifecycle and hence support for AWT printing.Sven Gothel2013-09-081-2/+3
| | | | | | | | | Note: Same bug existing as w/ GLCanvas, i.e. 'GLDrawableUtil.swapGLContextAndAllGLEventListener(gladPre, gladNew)': If 'gladPre' is onscreen and using MSAA (on NV/GLX), the ctx cannot be made current in it's new 'gladNew' location. Same workaround applied, i.e. use onscreen drawable while printing.
* Test: Don't resize frame, tweek print-matrix; AWTPrintLifecycle: Add scale ↵Sven Gothel2013-09-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | and convenient AWT container traversal context; GLCanvas/GLJPanel properly handle existing MSAA and req. AA; - Test: Don't resize frame, tweek print-matrix - Use scaleComp72 to scale the frame to fit on page, i.e. global print matrix - Use scaleGLMatXY = 72.0 / glDPI to locally scale on the GL drawable as being passed to AWTPrintLifecycle.setup(..) - Hence frame stays untouched/stable, no need for 'offscreen' print test, which is removed. - AWTPrintLifecycle: Add scale and convenient AWT container traversal context Use a simple decoration for all AWTPrintLifecycle impl. components within a container: final AWTPrintLifecycle.Context ctx = AWTPrintLifecycle.Context.setupPrint(frame, g2d, scaleGLMatXY, scaleGLMatXY); try { } finally { ctx.releasePrint(); } - GLCanvas/GLJPanel properly handle existing MSAA and req. AA; - GLCanvas: Workaround bug where onscreen MSAA cannot switch to offscreen FBO, i.e. stay 'onscreen' - GLJPanel: Use new offscreen FBO if MSAA is requested and not yet used. - GLJPanel.Offscreen.postGL(): always swapBufer(), was missing for !GLSL swapping Results GLCanvas / GLJPanel: - Good scaling - Stable behavior / visibility - High DPI mode works
* TiledPrintingAWTBase: Fix scaling - Fit frame to page, add MSAA ↵Sven Gothel2013-09-071-3/+3
| | | | | | | | | | | | | | RenderingHints test; setupPrint(Graphics2D): Query RenderingHints to use MSAA rendering - AWTPrintLifecycle.setupPrint(Graphics2D): Query RenderingHints to use MSAA rendering - Impl. in GLCanvas - TODO GLJPanel (would need a new offscreen buffer) - TiledPrintingAWTBase: - Fix scaling - Fit frame to page - add MSAA RenderingHints test - GLCanvas: Remove dumpStack() DEBUG output
* GLCanvas Printing WIP: Add GLJPanel; GLCanvas TILE_SIZE 512; ↵Sven Gothel2013-09-061-0/+1
| | | | print(Graphics): Don't force on AWT-EDT -> Deadlock; releasePrint(): perform reshape/display!