aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl
Commit message (Collapse)AuthorAgeFilesLines
* X11 DummyWindow: Pass size and set size in proxySven Gothel2010-12-041-2/+3
|
* Windows WGL fixes updateGraphicsConfiguration(..) and DummyWGLDrawableSven Gothel2010-12-032-31/+30
| | | | | | | | WindowsWGLGraphicsConfiguration: If updateGraphicsConfigurationARB fails, continue with updateGraphicsConfigurationGDI WindowsDummyWGLDrawable: Utilize proper GraphicsConfiguration selection using updateGraphicsConfiguration()
* GLCanvas: Adding convenient constructor for GLCapabilties and Shared Context ↵Sven Gothel2010-12-031-1/+14
| | | | (with unit test)
* DEBUG: GLProfile: Dump GLInfo ; GLContext: SET mappedVersions.. no stack traceSven Gothel2010-12-032-18/+48
|
* GLPbufferImpl: Remove redundant AWT threading constraints ; Signal dispose ↵Sven Gothel2010-12-031-91/+38
| | | | to all GLEventListeners at destroy()
* Cleanup GLDrawableFactory API and platform ImplementationsSven Gothel2010-12-0315-239/+351
| | | | | | | | | | | | | | | | | | | | | | | - Finish API change using the AbstractGraphicsDevice, which denotes the target device for the desired NativeSurface / GLDrawable. The AbstractGraphicsDevice argument may be null to reflect the platform's default device. Clarified API documentation. This move is necessary to make the API coherent. - createOffscreenDrawable(..) may create a Pbuffer drawable if caps and supported. This unifies the functionality with createGLDrawable(..). Further more, a Pbuffer drawable is an offscreen as well. - added createOffscreenSurface(..) following the same behavior as createOffscreenDrawable(..), this is a convenient native offscreen surface factory entry. - removed createGLPbufferDrawable(..), use createOffscreenDrawable(..), since it is redundant! Implementation Details: - EGLDrawableFactory holds a shared native EGLGraphicsDevice, being used by the offscreen EGL drawable (no more multiple creation).
* JOGL AnimatorImpl: issue drawable.display() even if it's not realized yet, ↵Sven Gothel2010-11-292-9/+3
| | | | since the drawable may realize itself with the display() call. This situation appears with an AWT GLCanvas
* Animator: Run as non daemon like FPSAnimator. This seems to be the users ↵Sven Gothel2010-11-281-1/+6
| | | | desired behavior and is more compliant with other APIs
* JOGL: Proper handling of Read Drawable Support (if not supported), add query.Sven Gothel2010-11-2810-352/+363
| | | | | | | | | | | | | | | | | | | Read Drawable feature reflects the make context current API having a seperate read drawable next to the write drawable (default). glXMakeContextCurrent(write, read, ..) On X11 a ready drawable is only supported for GLX >= 1.3, on Windows only if extension WGL_ARB_make_current_read is available, on EGL it's always supported, on OSX not at all. API cleanup GLContext: changes: setGLDrawableRead(GLDrawable) -> setGLReadDrawable(GLDrawable) new: isGLReadDrawableAvailable() new: getGLExtensionsString(); Access qualifier cleanup. GLContextImpl: GLVersionNumber moved out.
* minor cleanupSven Gothel2010-11-282-10/+15
|
* GLCanvas: Fix disableBackgroundErase/X11, make drawable creation more ↵Sven Gothel2010-11-272-19/+78
| | | | | | | | | | | | | | | | robust, doc Java2D/AWT properties. On X11 disableBackgroundErase() must happen before native peer creation, this patch issues it before and after super.addNotify(). Make drawable creation more robust, ie only create a drawable in case the size is > 0x0 and do this check/create at display/paint in case size it not yet determined. Add documentation about Java2D/AWT properties impact on GLCanvas. Make JUnit tests on AWT/GLProfile's more robust, while adding frame validate() ensuring 1st paint will have a size, hence will create the drawable. This is necessary for eg. AMD GPU's and GL context > 3.
* Add GL_VENDOR to JoglVersion GL outputSven Gothel2010-11-261-0/+2
|
* WGL: Add GetLastError in case external context/drawable can't be retrievedSven Gothel2010-11-262-5/+5
|
* Reduce visibility -> package privateSven Gothel2010-11-269-115/+114
|
* Refined VersionInfo usageSven Gothel2010-11-252-7/+9
|
* JOGL/Windows/ATI r3xx: Bug #438: tolerate release context if GetLastError is ↵Sven Gothel2010-11-251-11/+18
| | | | SUCCESS
* NativeWindow/GDI: Adding ERROR_SUCCESS to make the code more clear.Sven Gothel2010-11-254-10/+13
|
* GLProfile/Debug: Dump Version info upfront, otherwise we won't see it with ↵Sven Gothel2010-11-251-6/+6
| | | | | | an <init> exception. Also adding current thread name.
* GLCanvas: Refine access modifiersSven Gothel2010-11-251-4/+4
|
* Relax GLAnimatorControl, ie remove fail fast for start()/stop(), return ↵Sven Gothel2010-11-253-16/+21
| | | | (boolean)success instead.
* Fix GLCanvas Recreation - Regression 96af6c9bf2d683115996Sven Gothel2010-11-251-32/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | 96af6c9bf2d683115996 moved the creation of the AWTGraphicsConfiguration, GLDrawable and GLContext to the GLCanvas constructor. This disabled recreation, removeNotify()/addNotify() after 1st addNotify(), since the drawable/context were already set to null. Smart recreation, ie not destroying the resources completly: 1 - drawable 2 - context 3 - AWTGraphicsConfiguration's Device (X11: Display) is not possible, since removeNotify() is the only destroy notification we have from AWT, which would leave the above resources open -> leak. This is especially true for (3), since the device is created 'on the fly'. In NEWT we use lazy creation/destroy and are able to keep the references alive. A remodelling of AbstractGraphicsConfiguration would be required, which indeed would be overkill. Simple solution is to move the creation block back to addNotify() but before 'super.addNotify()', since it needs our chosen AWTGraphicsConfiguration. Also flagging sendReshape in addNotify(). Added test case com.jogamp.test.junit.jogl.awt.TestAWT03GLCanvasRecreate01.
* AnimatorBase: add()/remove() - decorate change of drawables with ↵Sven Gothel2010-11-231-30/+15
| | | | pause()/resume() so it becomes a non critical to multithreading, hence display() or state change needs to be synced
* Add GLJPanel test (works better in jogl-demos though, need to copy)Sven Gothel2010-11-231-6/+10
|
* X11/WGL: Unify GraphicsConfiguration Selection - Fixes WGL Bugs 397, 410, ↵Sven Gothel2010-11-237-359/+539
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 429, 428 and 405 Fixes bugs WGL pixelformat related bugs: http://jogamp.org/bugzilla/show_bug.cgi?id=397 http://jogamp.org/bugzilla/show_bug.cgi?id=410 http://jogamp.org/bugzilla/show_bug.cgi?id=429 http://jogamp.org/bugzilla/show_bug.cgi?id=428 http://jogamp.org/bugzilla/show_bug.cgi?id=405 Tested on Window7-x86 (amd/nvidia), WinXP-x32-VirtualBox. Solution: Cleaned up X11/GLX code to use it as a correct boilerplate for the new WGL selection, which now duplicates the same behavior. X11/GLX and WGL follow the common logic: - 1st try: - get GLCapabilities based on users GLCapabilities - setting recommendedIndex as preferred choice - 2nd try: - get all GLCapabilities available - no preferred recommendedIndex available If no recommendedIndex has been selected and no chooser has been passed, we use the DefaultGLCapabilitiesChooser. Choose the GLCapabilities if a chooser is given (or see above).
* JOGL: Fix CreateDummyWindow usage, no more sync needed, since the Window ↵Sven Gothel2010-11-221-5/+1
| | | | class HINSTANCE is acquired at static initialization
* JOGL/X11 Shutdown: Don't close pending Display connections since it may ↵Sven Gothel2010-11-221-1/+3
| | | | cause a SIGSEGV at JVM exit.
* GLAnimatorControl pause()/resume() don't fail fast, return a boolean instead ↵Sven Gothel2010-11-224-19/+22
| | | | to simplify usage.
* JOGL: AWT/GraphicsConfiguration - Use own display handle, reuse causes ↵Sven Gothel2010-11-211-5/+6
| | | | SIGSEGV on AMD
* JOGL/NEWT: Animator fixesSven Gothel2010-11-2110-219/+324
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Consider use cases with many drawables and no drawables at start, this had to be reflected all over this patch set, implementation, usage and test cases. - GLAnimatorControl - refine API doc / states - add 'void remove(GLAutoDrawable drawable);' - Animator*: - using RecursiveLock 'stateSync' for all actions out of the big synchronized (animator) block: - get status methods (thread, isPaused, ..), hence no more synchronized - display drawables change, utilizing synced ArrayList swap This removes the need for volatiles usage shouldPause/shouldStop within the display method. - added blocking wait for state change for add(GLAutoDrawable)/remove(GLAutoDrawable) method - remove flawed double checked locking in anim thread (pause/idle condition) - thread is now a daemon thread, hence it won't hinder the JVM from shutdown - - Animator use change: - Always resume after pause, except in case of final destroy -> NEWT invalidate / GLCanvas, this considers use cases with many drawables and no drawables at start. - GLDrawableHelper: Don't pause at implicit dispose()
* Merge branch 'master' of github.com:sgothel/joglMichael Bien2010-11-189-128/+182
|\
| * JOGL/AWT: Fix ~ 2 year old regressions: Choose & Use GraphicsConfiguration ↵Sven Gothel2010-11-189-128/+182
| | | | | | | | | | | | | | | | | | | | | | | | | | | | for Canvas. ; Adding FSAA test. Canvas/X11: The Canvas GraphicsConfiguraton should be chosen before the native peer is being created. Choosing AWT GraphicsConfiguration (all platforms): Don't filter our capabilities with 'AWTGraphicsConfiguration.setupCapabilitiesRGBABits(capsChosen, gc)', not necessary (see above) and it would remove ourrequired alpha channel. Canvas display(): Don't render if drawable is not realized (yet).
* | print platform info additional to the module info.Michael Bien2010-11-183-0/+5
| |
* | modifications due to changes in GlueGen's VersionUtil.getManifest().Michael Bien2010-11-181-7/+5
|/ | | | made references created in double checked locks volatile.
* NEWT: Adding CapabilitiesChooser setter and using it in createNativeImpl() ..Sven Gothel2010-11-181-2/+2
|
* Finishing Immutable changes including GLCapabiltiesImmutable.Sven Gothel2010-11-1741-359/+678
|
* Merge branch 'pulled'Sven Gothel2010-11-172-2/+2
|\
| * Implement CapabilitiesImmutable to indicate that getRequestedCapabilities() ↵Steve Vaughan2010-11-172-2/+2
| | | | | | | | and getChosenCapabilities() return immutable instances. Add cloneCapabilities() to create a mutable clone of an immutable set of capabilities.
* | Move shutdown hook registration to GLDrawableFactory.Sven Gothel2010-11-172-29/+59
| | | | | | | | Unregister the shutdown hook if called manually (recommended!).
* | Move GDI GlueGen wrapping from JOGL -> NativeWindow (following X11). Moving ↵Sven Gothel2010-11-1710-52/+142
|/ | | | NEWT WindowsWindow GetRelativeLocation() native implementation to GDI as well.
* X11: Make X11 error handler quiet where we expect an X11 error, ie OpenGL 4 ↵Sven Gothel2010-11-161-6/+6
| | | | not available ..
* NativeWindow AbstractGraphicsDevice: Add 'unitID' attribute and getUniqueID()Sven Gothel2010-11-1516-44/+28
| | | | | | | | | | Preparation to support multiple devices on one machine, hence adding the unitID a unique ID/index of the associated GPU, or GPU affinity. Adding getUniqueID() to return a cached semantic unique string id for the device. This was removed from the temp. impl in JOGL's GLContext, added unitID. All other changes just adapt to the above.
* JOGL X11/WGL: Proper usage of the shared resources in implementationSven Gothel2010-11-144-74/+103
|
* JOGL: Complete eager and lazy mapping of GLProfiles in respect to multiple ↵Sven Gothel2010-11-1421-664/+1536
| | | | | | | | | | | | | | device. AbstractGraphicsDevice's 'connection' and 'type' attribute is used as a unique key to map GLProfiles and GLContext's major/profile -> major/minor/profile mapping. Eager initialiaztion as well as lazy is supported to maintain a simple API. This is currently tested on X11, where one app display NEWT/GL window and content on the local and remote device. See TestRemoteWindow01NEWT.java and TestRemoteGLWindows01NEWT.java
* import cleanupSven Gothel2010-11-142-6/+0
|
* ExtensionAvailabilityCache: Fall back to glGetString, if glGetStringi fails; ↵Sven Gothel2010-11-141-9/+18
| | | | Add threadName to DEBUG output
* ExtensionAvailabilityCache: Only use glGetStringi() is real GL >= 3.1 contextSven Gothel2010-11-132-18/+16
|
* Adapt to GlueGen Version changes; Adding NativeWindowVersion, JoglVersion ↵Sven Gothel2010-11-123-29/+49
| | | | | | | | | and NewtVersion. Adapt to GlueGen Version changes: b735755815312b5fe2c003642de60711be1cd645 .. 556c7e70d3d57aa99b5787b1e4d8a7b1c299ed3f Show information of all subcomponenet.
* AbstractGraphicsDevice ..: Add device/display connection attribute to ↵Sven Gothel2010-11-122-7/+2
| | | | | | | | | | support multi devices & displays. Currently only the X11 Display connection is implemented to support multiple device connections. Other platforms may follow. This allows correct mapping and caching of higher level resources, eg. ProcAddressTable, GL version mapping etc with respect to the display device.
* Use GlueGen VersionUtil to dump full Manifest versionSven Gothel2010-11-102-63/+12
|
* The 'shared resource' thread must be a deamon, otherwise the application ↵Sven Gothel2010-11-091-1/+3
| | | | won't exit