aboutsummaryrefslogtreecommitdiffstats
path: root/src/native
Commit message (Collapse)AuthorAgeFilesLines
* JOGL refactoring:Sven Gothel2009-03-1626-7004/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Refactored JOGL into 3 independent components. 1 NWI - Native windowing interface Abstracts the the general NativeWindow interface and it's factory, incl the basic JAWT and Xlib toolkit. The latter was motivated to clean up the JOGL workspace, and to allow other to reuse this part. The generic core is nwi.core.jar, the AWT add-on is nwi.awt.jar. 2 JOGL - The OpenGL mapping Further cleanup of the SPEC. All non OpenGL toolkits are relocated to NWI and NEWT. There is still openmax and the windows audio layer .. Another cleanup of the fixed function pipeline emulation. Moved utilities and implementations where they belong .. Removed GLUnsupportedException. Misc .. changes 3 NEWT - The new windowing toolkit The generic NEWT, newt.core.jar. The JOGL and AWT modules are seperate, newt.ogl.jar newt.awt.jar. Their build can be switched off. The modules source and builds resides in their own directory. Because of their nature, they share the stub_includes, etc. Each module has it's own ant build script - build-nwi.xml - build-jogl.xml - build-newt.xml They can be build at once using build.xml as ususal, which just invokes the seperate build tasks. if rootrel.build=build, then the build location is jogl/build-nwi jogl/build-jogl jogl/build-newt and the sources are under jogl/src/nwi jogl/src/jogl jogl/src/newt Tested: jogl-demos, d4; Linux, MacOsX; Nvidia git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1868 232f8b59-042b-4e1e-8c03-345bb8c30851
* NEWT window closing:Sven Gothel2009-03-144-25/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - New WindowEvent.EVENT_WINDOW_DESTROY_NOTIFY and WindowListener.windowDestroyNotify() method. - Removed windowClosed() method for JNI hook - Added windowDestroyNotify() windowDestroyed(), where windowDestroyNotify() shall be called by the native implementation _before_ the window gets shutdown. The Window.java then sends a WindowEvent.EVENT_WINDOW_DESTROY_NOTIFY event, and either Window.java or it's owner GLWindow.java issues the destroy() procedure. - Added GLEventListener.dispose(GLAutoDrawable), to allow user application to release GL ressources. Issued by GLWindow (-> see windowDestroyNotify()) - X11 impl intercepts WM_DELETE_WINDOW, using Atom, MacosX impl already uses the _before_ method (VERIFY), and Windows impl uses the WM_CLOSE event (VERIFY). JOGL2 dispose/destroy .. - Added GLEventListener.dispose() to GLCanvas and GLJpanel - GL* toString() rearrangement, assumes it is issued by GLContext(), which indeed is the core information node. - Added proper destroy() methods and calls, to achieve a proper resource release at destruction. Instrumentizing almost all classes with a destroy() method, so no release function lookup is necessary. - misc changes .. JOGL2 Demos - Fixed in regards to the above changes git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1867 232f8b59-042b-4e1e-8c03-345bb8c30851
* Worked around problem on Mac OS X where right mouse button down eventsKenneth Russel2009-03-131-1/+24
| | | | | | | were not being received by Newt window git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1866 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fix NEWT X11 KeymappingSven Gothel2009-03-132-2/+236
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1862 232f8b59-042b-4e1e-8c03-345bb8c30851
* Changed how MacWindow computes the coordinates for mouse events sentKenneth Russel2009-01-151-1/+7
| | | | | | | | up to Java to improve the behavior where drag events are used to drag the window around; behavior is better but still not perfect git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1847 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixed known bug in coordinates passed for WINDOW_MOVED events on MacKenneth Russel2009-01-142-38/+12
| | | | | | | | OS X. Fixed residual bug in handling of setPosition calls. Tested manually by moving around window of Angeles demo. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1846 232f8b59-042b-4e1e-8c03-345bb8c30851
* Turned off debugging printfsKenneth Russel2009-01-141-2/+7
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1845 232f8b59-042b-4e1e-8c03-345bb8c30851
* Added GLCapabilities.setBackgroundOpaque() and isBackgroundOpaque()Kenneth Russel2009-01-062-0/+14
| | | | | | | | | | for shaped window support on Mac OS X, and modified MacOSXCGLContext to pay attention to this bit. Changed Mac OS X port of Newt to make window non-opaque if borderless, and still allow it to receive the keyboard focus. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1841 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixed problems exposed by SoyLatte JRE where there was noKenneth Russel2009-01-061-1/+16
| | | | | | | NSAutoreleasePool present. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1839 232f8b59-042b-4e1e-8c03-345bb8c30851
* Native (non-AWT) port of Newt to Mac OS X using Cocoa. MostKenneth Russel2009-01-054-17/+604
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | functionality (mouse click, mouse motion, mouse dragging, keyboard events) appears to be working. Currently works with the Apple JRE and requires the JVM command-line arguments -XstartOnFirstThread and -Djava.awt.headless=true . Will work with the standalone SoyLatte JRE pending additional launcher changes. Tested with Angeles demo and various JavaFX demos. Added -Dnewt.ws.name=AWT option to force the use of the AWT port of Newt on any supported platform. Known bugs: - While resizing a window or dropping down a menu, the application will hang. This is due to how the event processing is currently done in Newt (via Window.dispatchMessages()) and how Mac OS X deals with resize operations (by pushing a nested event loop into which we have no visibility). There are at least a couple of solutions. One would be to preserve the current API semantics but use a Newt Launcher class to move main() on to a different thread, saving the primordial thread for [NSApplication run]. Another would be to move Newt (and, by association, the JavaFX runtime code) to a callback model like GLUT. - Command-Q and the Quit menu option do not yet properly exit the application. - The coordinates for the WINDOW_MOVED event are wrong. Added the rest of the VK_ constants to the KeyEvent class. Made preliminary changes to support the SoyLatte JRE. Worked around initialization order issues with Fmod. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1838 232f8b59-042b-4e1e-8c03-345bb8c30851
* OMX cleanup - generic toolSven Gothel2008-12-014-610/+620
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1812 232f8b59-042b-4e1e-8c03-345bb8c30851
* ? buildSven Gothel2008-11-293-145/+163
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ? make/GnuCTreeParserTokenTypes.txt ? make/STDCTokenTypes.txt ? make/make.jogl.all.linux-x86.log ? make/make.jogl.cdcfp.linux-x86.log ? make/make.jogl.doc.all.log Index: make/build.xml =================================================================== RCS file: /cvs/jogl/make/build.xml,v retrieving revision 1.141.2.55 diff -r1.141.2.55 build.xml 356a357 > <property name="rootrel.src.c.openmax" value="src/native/openmax" /> 1453a1455 > <includepath path="stub_includes/openmax" if="useOpenMAX"/> Index: make/make.jogl.cdcfp.linux-x86.sh =================================================================== RCS file: /cvs/jogl/make/Attic/make.jogl.cdcfp.linux-x86.sh,v retrieving revision 1.1.2.5 diff -r1.1.2.5 make.jogl.cdcfp.linux-x86.sh 10c10 < # -Djava.generate.skip=true --- > # -Djava.generate.skip=true \ 20a21 > -Djava.generate.skip=true \ Index: src/classes/com/sun/javafx/media/video/openmax/OMXMoviePlayerImpl.java =================================================================== RCS file: /cvs/jogl/src/classes/com/sun/javafx/media/video/openmax/Attic/OMXMoviePlayerImpl.java,v retrieving revision 1.1.2.1 diff -r1.1.2.1 OMXMoviePlayerImpl.java 354a355 > gl.glDisable(gl.GL_TEXTURE_2D); Index: src/classes/javax/media/opengl/GLArrayDataWrapper.java =================================================================== RCS file: /cvs/jogl/src/classes/javax/media/opengl/Attic/GLArrayDataWrapper.java,v retrieving revision 1.1.2.1 diff -r1.1.2.1 GLArrayDataWrapper.java 165a166 > this.normalized = normalized; Index: src/native/newt/KDWindow.c =================================================================== RCS file: /cvs/jogl/src/native/newt/Attic/KDWindow.c,v retrieving revision 1.1.2.4 diff -r1.1.2.4 KDWindow.c 66c66 < #define DBG_PRINT(...) fprintf(stderr, __VA_ARGS__) --- > #define DBG_PRINT(...) fprintf(stdout, __VA_ARGS__) 73,74c73,74 < #define STDOUT_FILE "\\Storage Card\\jogl_demos\\stdout.txt" < #define STDERR_FILE "\\Storage Card\\jogl_demos\\stderr.txt" --- > #define STDOUT_FILE "\\Storage Card\\stdout.txt" > #define STDERR_FILE "\\Storage Card\\stderr.txt" Index: src/native/openmax/com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl.c =================================================================== RCS file: /cvs/jogl/src/native/openmax/Attic/com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl.c,v retrieving revision 1.1.2.1 diff -r1.1.2.1 com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl.c 74c74 < JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1createInstance --- > JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1createInstance 87c87 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1setStream --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1setStream 105c105 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1updateStreamInfo --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1updateStreamInfo 117c117 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1setEGLImageTexture2D --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1setEGLImageTexture2D 129c129 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1activateInstance --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1activateInstance 142c142 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 146c146 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1play --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1play 149c149 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1play\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1play\n"); 161c161 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 165c165 < JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1stop --- > JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1stop 174c174 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 178c178 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1setVolume --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1setVolume 185c185 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 189c189 < JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getCurrentPosition --- > JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getCurrentPosition 198c198 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 202c202 < JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getCurrentLoaded --- > JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getCurrentLoaded 210c210 < JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getDuration --- > JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getDuration 218c218 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 222c222 < JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1step --- > JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1step 225c225 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1step\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1step\n"); 232c232 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 236c236 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1setRate --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1setRate 239c239 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1setRate\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1setRate\n"); 244c244 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 248c248 < JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1setCurrentPosition --- > JNIEXPORT jlong JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1setCurrentPosition 251c251 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1setRate\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1setRate\n"); 257c257 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 261c261 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1lock --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1lock 264c264 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1lock\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1lock\n"); 269c269 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 273c273 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1unlock --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1unlock 276c276 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1unlock\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1unlock\n"); 281c281 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 285c285 < JNIEXPORT jint JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getTextureID --- > JNIEXPORT jint JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getTextureID 288c288 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getTextureID\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getTextureID\n"); 299c299 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 303c303 < JNIEXPORT jint JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getWidth --- > JNIEXPORT jint JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getWidth 306c306 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getWidth\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getWidth\n"); 318c318 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 322c322 < JNIEXPORT jint JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getHeight --- > JNIEXPORT jint JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getHeight 325c325 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1getHeight\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1getHeight\n"); 337c337 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 341c341 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1task --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1task 348c348 < * Class: com_sun_javafx_media_video_openmax_OMXMovieImpl --- > * Class: com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl 352c352 < JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1destroyInstance --- > JNIEXPORT void JNICALL Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1destroyInstance 355c355 < //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMovieImpl__1destroy\n"); --- > //fprintf(stdout, "Java_com_sun_javafx_media_video_openmax_OMXMoviePlayerImpl__1destroy\n"); Index: src/native/openmax/omx_tool.c =================================================================== RCS file: /cvs/jogl/src/native/openmax/Attic/omx_tool.c,v retrieving revision 1.1.2.1 diff -r1.1.2.1 omx_tool.c 3a4,25 > #define VERBOSE_ON 1 > #define VERBOSE2_ON 1 > > #ifdef VERBOSE_ON > #define DBG_PRINT(...) fprintf(stdout, __VA_ARGS__) > #else > #define DBG_PRINT(...) > #endif > > #if defined(VERBOSE_ON) && defined(VERBOSE2_ON) > #define DBG_PRINT2(...) fprintf(stdout, __VA_ARGS__) > #else > #define DBG_PRINT2(...) > #endif > > #ifdef VERBOSE_ON > #ifdef _WIN32_WCE > #define STDOUT_FILE "\\Storage Card\\stdout.txt" > #define STDERR_FILE "\\Storage Card\\stderr.txt" > #endif > #endif > 29c51 < fprintf(stderr, "RuntimeException: %s\n", buffer); fflush(stderr); --- > DBG_PRINT( "RuntimeException: %s\n", buffer); 86a109,116 > > #ifdef VERBOSE_ON > #ifdef _WIN32_WCE > _wfreopen(TEXT(STDOUT_FILE),L"w",stdout); > _wfreopen(TEXT(STDERR_FILE),L"w",stderr); > #endif > #endif > 104d133 < _hasEGLSync = 0; // JAU 111c140 < printf("INVALIDATE\n"); fflush(stdout); --- > DBG_PRINT("INVALIDATE\n"); 140c169 < printf("event complete: cmd 0x%X, s:0x%X, component: %p - %s\n", (unsigned)nData1, (unsigned)nData2, hComponent, name); --- > DBG_PRINT("event complete: cmd 0x%X, s:0x%X, component: %p - %s\n", (unsigned)nData1, (unsigned)nData2, hComponent, name); 144c173 < printf("\t state -> StateLoaded\n"); --- > DBG_PRINT("\t state -> StateLoaded\n"); 151c180 < printf("\t flush\n"); --- > DBG_PRINT("\t flush\n"); 159c188 < printf("event buffer EOS: component: %p - %s\n", hComponent, name); --- > DBG_PRINT("event buffer EOS: component: %p - %s\n", hComponent, name); 162c191 < printf("\t end component - FIN\n"); --- > DBG_PRINT("\t end component - FIN\n"); 171c200 < printf("event error: 0x%X IncorrectTransition, component: %p - %s\n", (unsigned int) nData1, hComponent, name); --- > DBG_PRINT("event error: 0x%X IncorrectTransition, component: %p - %s\n", (unsigned int) nData1, hComponent, name); 177c206 < printf("event error: Same State 0x%X, component: %p - %s\n", (unsigned int) nData2, hComponent, name); --- > DBG_PRINT("event error: Same State 0x%X, component: %p - %s\n", (unsigned int) nData2, hComponent, name); 181c210 < printf("event error: 0x%X, component: %p - %s\n", (unsigned int) nData1, hComponent, name); --- > DBG_PRINT("event error: 0x%X, component: %p - %s\n", (unsigned int) nData1, hComponent, name); 214c243 < fprintf(stdout, "FillBufferDone avail %d\n", pOMXAV->available); fflush(stdout); --- > DBG_PRINT("FillBufferDone avail %d\n", pOMXAV->available); 232c261 < fprintf(stdout, "WaitForState p1 c:%p s1:0x%X s2:0x%X\n", hComponent, eTestState, eTestState2); fflush(stdout); // JAU --- > DBG_PRINT( "WaitForState p1 c:%p s1:0x%X s2:0x%X\n", hComponent, eTestState, eTestState2); 234c263 < fprintf(stdout, "WaitForState p2 s:0x%X e:0x%X\n", eState, eError); fflush(stdout); // JAU --- > DBG_PRINT( "WaitForState p2 s:0x%X e:0x%X\n", eState, eError); 245c274 < fprintf(stdout, "WaitForState p3 s:0x%X e:0x%X\n", eState, eError); fflush(stdout); // JAU --- > DBG_PRINT( "WaitForState p3 s:0x%X e:0x%X\n", eState, eError); 320c349 < fprintf(stdout, "OMXToolBasicAV_WaitForState %p s:%d\n", pOMXAV, state); fflush(stdout); // JAU --- > DBG_PRINT( "OMXToolBasicAV_WaitForState %p s:%d\n", pOMXAV, state); 322c351 < fprintf(stdout, "OMXToolBasicAV_WaitForState p1\n"); fflush(stdout); // JAU --- > DBG_PRINT( "OMXToolBasicAV_WaitForState p1\n"); 328c357 < fprintf(stdout, "OMXToolBasicAV_WaitForState p4 %d c:%p\n", i, pOMXAV->comp[i]); fflush(stdout); // JAU --- > DBG_PRINT( "OMXToolBasicAV_WaitForState p4 %d c:%p\n", i, pOMXAV->comp[i]); 332c361 < fprintf(stdout, "OMXToolBasicAV_WaitForState Failed (Wait) %d c:%p - %s, s:0x%X\n", --- > DBG_PRINT( "OMXToolBasicAV_WaitForState Failed (Wait) %d c:%p - %s, s:0x%X\n", 334d362 < fflush(stdout); // JAU 348,349c376,377 < fprintf(stdout, "RequestState p2 c:%p, e:0x%X, s:0x%X\n", < hComponent, eError, eState); fflush(stdout); // JAU --- > DBG_PRINT( "RequestState p2 c:%p, e:0x%X, s:0x%X\n", > hComponent, eError, eState); 353,354c381,382 < fprintf(stdout, "RequestState p3 c:%p e:0x%X s: 0x%X -> 0x%X\n", < hComponent, eError, eState, state); fflush(stdout); // JAU --- > DBG_PRINT( "RequestState p3 c:%p e:0x%X s: 0x%X -> 0x%X\n", > hComponent, eError, eState, state); 367c395 < fprintf(stdout, "OMXToolBasicAV_RequestState %p s:%d, w:%d\n", pOMXAV, state, wait); fflush(stdout); // JAU --- > DBG_PRINT( "OMXToolBasicAV_RequestState %p s:%d, w:%d\n", pOMXAV, state, wait); 369c397 < fprintf(stdout, "OMXToolBasicAV_RequestState p1\n"); fflush(stdout); // JAU --- > DBG_PRINT( "OMXToolBasicAV_RequestState p1\n"); 420c448 < fprintf(stderr, "Destroy p1\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p1\n"); 423c451 < fprintf(stderr, "Destroy p2\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p2\n"); 429c457 < fprintf(stderr, "Destroy p3\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p3\n"); 432c460 < fprintf(stderr, "Destroy p3\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p3\n"); 435c463 < fprintf(stderr, "Destroy p4\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p4\n"); 443c471 < fprintf(stderr, "Destroy p5\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p5\n"); 452c480 < fprintf(stderr, "Destroy p6\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p6\n"); 457c485 < fprintf(stderr, "Destroy p7\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p7\n"); 459c487 < fprintf(stderr, "Destroy p8\n"); fflush(stderr); --- > DBG_PRINT( "Destroy p8\n"); 464c492 < fprintf(stderr, "Destroy DONE\n"); fflush(stderr); --- > DBG_PRINT( "Destroy DONE\n"); 592c620 < fprintf(stdout, "Play 3.2\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play 3.2\n"); 705c733 < fprintf(stdout, "Attach VR %p c:%p\n", pOMXAV, pOMXAV->comp[OMXAV_H_VSCHEDULER]); fflush(stdout); // JAU --- > DBG_PRINT( "Attach VR %p c:%p\n", pOMXAV, pOMXAV->comp[OMXAV_H_VSCHEDULER]); 708c736 < fprintf(stdout, "UseEGLImg port enable/tunneling %p\n", pOMXAV); --- > DBG_PRINT( "UseEGLImg port enable/tunneling %p\n", pOMXAV); 721c749 < fprintf(stdout, "UseEGLImg %p #%d t:%d i:%p s:%p p1\n", pOMXAV, i, pBuf->tex, pBuf->image, pBuf->sync); fflush(stdout); // JAU --- > DBG_PRINT( "UseEGLImg %p #%d t:%d i:%p s:%p p1\n", pOMXAV, i, pBuf->tex, pBuf->image, pBuf->sync); 735,736c763,764 < fprintf(stdout, "UseEGLImg %p #%d t:%d i:%p s:%p b:%p - p2\n", < pOMXAV, i, pBuf->tex, pBuf->image, pBuf->sync, pBuf->omxBufferHeader); fflush(stdout); // JAU --- > DBG_PRINT( "UseEGLImg %p #%d t:%d i:%p s:%p b:%p - p2\n", > pOMXAV, i, pBuf->tex, pBuf->image, pBuf->sync, pBuf->omxBufferHeader); 739c767 < fprintf(stdout, "UseEGLImg %p #%d DONE\n", pOMXAV, i); fflush(stdout); // JAU --- > DBG_PRINT( "UseEGLImg %p #%d DONE\n", pOMXAV, i); 752c780 < fprintf(stderr, "DetachVideoRenderer p0\n"); fflush(stderr); --- > DBG_PRINT( "DetachVideoRenderer p0\n"); 754c782 < fprintf(stderr, "DetachVideoRenderer DONE (already state loaded)\n"); fflush(stderr); --- > DBG_PRINT( "DetachVideoRenderer DONE (already state loaded)\n"); 759c787 < fprintf(stderr, "DetachVideoRenderer p1\n"); fflush(stderr); --- > DBG_PRINT( "DetachVideoRenderer p1\n"); 764c792 < fprintf(stderr, "DetachVideoRenderer p2\n"); fflush(stderr); --- > DBG_PRINT( "DetachVideoRenderer p2\n"); 780c808 < fprintf(stderr, "DetachVideoRenderer p3\n"); fflush(stderr); --- > DBG_PRINT( "DetachVideoRenderer p3\n"); 784c812 < fprintf(stderr, "DetachVideoRenderer DONE\n"); fflush(stderr); --- > DBG_PRINT( "DetachVideoRenderer DONE\n"); 795c823 < fprintf(stderr, "buffer number %d > MAX(%d)\n", vBufferNum, EGLIMAGE_MAX_BUFFERS); --- > DBG_PRINT( "buffer number %d > MAX(%d)\n", vBufferNum, EGLIMAGE_MAX_BUFFERS); 800c828 < fprintf(stderr, "Init struct failed!\n"); --- > DBG_PRINT( "Init struct failed!\n"); 830c858 < fprintf(stdout, "SetStream 1 %s ..\n", stream); fflush(stdout); // JAU --- > DBG_PRINT( "SetStream 1 %s ..\n", stream); 840c868 < fprintf(stdout, "SetStream 3\n"); fflush(stdout); // JAU --- > DBG_PRINT( "SetStream 3\n"); 852c880 < fprintf(stdout, "SetStream 4\n"); fflush(stdout); // JAU --- > DBG_PRINT( "SetStream 4\n"); 905c933 < fprintf(stdout, "SetStream 5 ; audioPort %d, videoPort %d\n", pOMXAV->audioPort, pOMXAV->videoPort); fflush(stdout); // JAU --- > DBG_PRINT( "SetStream 5 ; audioPort %d, videoPort %d\n", pOMXAV->audioPort, pOMXAV->videoPort); 909c937 < fprintf(stdout, "Configuring comp[OMXAV_H_CLOCK]\n"); --- > DBG_PRINT( "Configuring comp[OMXAV_H_CLOCK]\n"); 925c953 < fprintf(stdout, "SetStream X\n"); fflush(stdout); // JAU --- > DBG_PRINT( "SetStream X\n"); 941c969 < fprintf(stdout, "SetEGLImg %p #%d/%d t:%d i:%p s:%p..\n", pOMXAV, i, pOMXAV->vBufferNum, tex, image, sync); fflush(stdout); // JAU --- > DBG_PRINT( "SetEGLImg %p #%d/%d t:%d i:%p s:%p..\n", pOMXAV, i, pOMXAV->vBufferNum, tex, image, sync); 961c989 < fprintf(stdout, "ActivateInstance 1\n"); fflush(stdout); // JAU --- > DBG_PRINT( "ActivateInstance 1\n"); 1000c1028 < fprintf(stdout, "Setup tunneling\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Setup tunneling\n"); 1005c1033 < fprintf(stdout, "Setup tunneling audio\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Setup tunneling audio\n"); 1012c1040 < fprintf(stdout, "Setup tunneling video\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Setup tunneling video\n"); 1017c1045 < fprintf(stdout, "ActivateInstance .. %p\n", pOMXAV); fflush(stdout); --- > DBG_PRINT( "ActivateInstance .. %p\n", pOMXAV); 1031c1059 < fprintf(stdout, "ActivateInstance done %p\n", pOMXAV); fflush(stdout); --- > DBG_PRINT( "ActivateInstance done %p\n", pOMXAV); 1090c1118 < fprintf(stderr, "Err: Play invalid"); fflush(stderr); --- > fprintf(stderr, "Err: Play invalid"); 1097c1125 < fprintf(stdout, "Play 1\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play 1\n"); 1099c1127 < fprintf(stdout, "Play 2\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play 2\n"); 1109c1137 < fprintf(stdout, "Play 3.0\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play 3.0\n"); 1112c1140 < fprintf(stdout, "Play 3.1\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play 3.1\n"); 1119c1147 < fprintf(stdout, "Play 3.2\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play 3.2\n"); 1125c1153 < fprintf(stdout, "Play 3.3\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play 3.3\n"); 1127c1155 < fprintf(stdout, "Play 4.0\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play 4.0\n"); 1131c1159 < fprintf(stdout, "Play DONE\n"); fflush(stdout); // JAU --- > DBG_PRINT( "Play DONE\n"); 1299,1300c1327,1328 < // fprintf(stdout, "GetTexture A avail %d, filled %d, pos o:%d g:%d\n", < // pOMXAV->available, pOMXAV->filled, pOMXAV->omxPos, pOMXAV->glPos); fflush(stdout); --- > DBG_PRINT2("GetTexture A avail %d, filled %d, pos o:%d g:%d\n", > pOMXAV->available, pOMXAV->filled, pOMXAV->omxPos, pOMXAV->glPos); 1310c1338 < // fprintf(stdout, "GetTexture p2.1 attr 0x%X\n", attr); fflush(stdout); --- > DBG_PRINT2( "GetTexture p2.1 attr 0x%X\n", attr); 1314c1342 < // fprintf(stdout, "GetTexture p2.2\n", attr); fflush(stdout); --- > DBG_PRINT2( "GetTexture p2.2\n"); 1321c1349 < // fprintf(stdout, "GetTexture p2.3\n", attr); fflush(stdout); --- > DBG_PRINT2( "GetTexture p2.3\n"); 1328c1356 < // fprintf(stdout, "GetTexture p3.1\n"); fflush(stdout); --- > DBG_PRINT2("GetTexture p3.1\n"); 1338c1366 < // fprintf(stdout, "GetTexture p3.2\n"); fflush(stdout); --- > DBG_PRINT2( "GetTexture p3.2\n"); 1347,1348c1375,1376 < // fprintf(stdout, "GetTexture B avail %d, filled %d, pos o:%d g:%d t:%d\n", < // pOMXAV->available, pOMXAV->filled, pOMXAV->omxPos, pOMXAV->glPos, texID); fflush(stdout); --- > DBG_PRINT2( "GetTexture B avail %d, filled %d, pos o:%d g:%d t:%d\n", > pOMXAV->available, pOMXAV->filled, pOMXAV->omxPos, pOMXAV->glPos, texID); 1368,1372d1395 < #ifdef _WIN32_WCE < #define STDOUT_FILE "\\Storage Card\\stdout.txt" < #define STDERR_FILE "\\Storage Card\\stderr.txt" < #endif < 1427,1431d1449 < #ifdef _WIN32_WCE < _wfreopen(TEXT(STDOUT_FILE),L"w",stdout); < _wfreopen(TEXT(STDERR_FILE),L"w",stderr); < #endif < 1538c1556 < printf("7\n"); fflush(stdout); --- > printf("7\n"); 1543c1561 < printf("8\n"); fflush(stdout); --- > printf("8\n"); 1548c1566 < printf("8.2\n"); fflush(stdout); --- > printf("8.2\n"); 1557c1575 < printf("Sleep %d\n", i); fflush(stdout); --- > printf("Sleep %d\n", i); git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1811 232f8b59-042b-4e1e-8c03-345bb8c30851
* ../jogl.logSven Gothel2008-11-273-0/+2105
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1810 232f8b59-042b-4e1e-8c03-345bb8c30851
* KD Fix: Use EGL AttributeList directlySven Gothel2008-11-271-32/+16
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1809 232f8b59-042b-4e1e-8c03-345bb8c30851
* Newt-KD: working inc. events. Screen size can be set w/ property ↵Sven Gothel2008-11-273-72/+68
| | | | | | newt.ws.swidth newt.ws.sheight git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1807 232f8b59-042b-4e1e-8c03-345bb8c30851
* Newt-KD: window working, pointer event buggySven Gothel2008-11-261-37/+39
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1806 232f8b59-042b-4e1e-8c03-345bb8c30851
* Newt WindowSven Gothel2008-11-263-2/+342
| | | | | | | | | | | | | | | | | | | - Uses GLCapabilities for window creation - Note: This is implemented in the new KDWindow only, for now. - FIXME: Respect GLCapabilities for other implementations (X11, MacOS, Windows) visualID shall be determined by GLCapabilities, and set to 0 if not implemented. - New OpenKODE KDWindow - Compile native code at with 'ant -DuseKD=true' - Use KD in newt with the Java property set newt.ws.name=KD - API change: NewtFactory.createWindow() takes GLCapabilities insteast of a fake visualID git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1804 232f8b59-042b-4e1e-8c03-345bb8c30851
* add Mac filesGerard Ziemski2008-10-201-0/+51
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1780 232f8b59-042b-4e1e-8c03-345bb8c30851
* rename setCurrentContextOpacity to setContextOpacityGerard Ziemski2008-10-171-1/+1
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1776 232f8b59-042b-4e1e-8c03-345bb8c30851
* add ability to set opacity on GL context: setCurrentContextOpacity takes 0 or 1Gerard Ziemski2008-10-171-0/+6
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1775 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixes for building with Visual C++ 6.0 (VC98)Kenneth Russel2008-09-161-2/+2
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1771 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixed loading of GLES and EGL libraries, and error reporting when none Kenneth Russel2008-07-312-14/+25
| | | | | | | | | | available. Fixed building with -Djogl.cdcfp, in particular nested building of gluegen. Took out call to SHFullScreen, which doesn't seem to be available on the NVidia APX 2500 any more. Fixed #includes in InternalBufferUtils.c. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1738 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixed:Sven Gothel2008-07-111-40/+89
| | | | | | | | | | | | | | | | - NEWT: - X11: Fullscreen toggle: (un)decorated window and resize event - CloseNative: Use copied display/window handle to close after invalidate - Cleanup/validations - GLDrawableHelper: Removed 'optimization' path - no sense and too complicated - GL, GLContextImpl, GLContextShareSet: - Activated: registerForBufferObjectSharing - Working BufferSizeTracker - GLBufferStateTracker: Activated: PBO state for GL2 - GL2/GLES1/GLES2: Activated VBO/PBO validation code git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1720 232f8b59-042b-4e1e-8c03-345bb8c30851
* GL Unification 2nd round.Sven Gothel2008-07-042-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Terminology: ARB Extensions: "GL2", "ARB", "OES", "OML" Vendor Extensions: "EXT", "NV", "ATI", "SGI", "SGIS", "SGIX", "HP", "IBM", "WIN" Pass-1 Unify ARB extensions with the same value Pass-2 Unify vendor extensions, if exist as an ARB extension with the same value. Pass-3 Emit Done: - Unification of GL enumerates - Unification of GL functions - dynamic extension lookup - .. TODO: - Break down GL.java: GL + GL2ES1ES2 (for future GL3, etc) - Add a GL2 small implementation, to only support the GL2ES2 subset, 'GL2SubES2' .. +++ - Fixed X11 build breakage of 'jawt' linkage. - Fixed NEWT native code mouse- and keyevent id's, missed sync while moving them from the bitfield notation. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1708 232f8b59-042b-4e1e-8c03-345bb8c30851
* Refactored more C compiler setup into gluegen-cpptasks.xml to make itKenneth Russel2008-06-301-0/+2
| | | | | | | | | | | | | | | | | | | | | easier to build native sources via Ant. Provided new gluegen.cpptasks.setup.compiler target which sets up platform-independent compiler and linker IDs and other properties which can be used in other projects' build files. Refactored JOGL build to use some of these new properties and eliminate duplication; more code savings possible. Added new GLWindow class to Newt implementing GLAutoDrawable to increase code sharing, and supporting making OpenGL calls inside of EventListener callbacks. Moved repaint() method from GLAutoDrawable to AWTGLAutoDrawable. Added WindowEvent and WindowListener interfaces to Newt, currently implemented on Windows and AWT backends (X11 backend would need to support and watch for window resizes -- FIXME added). Refactored common functionality into Newt Event class. Renumbered event IDs to avoid collisions. Fixed potential problems with removing event listeners inside of EventListener callbacks. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1702 232f8b59-042b-4e1e-8c03-345bb8c30851
* Mac OS X port of new JOGL and Newt. Currently leverages the AWT; willKenneth Russel2008-06-271-1/+1
| | | | | | | | | | | | | | | | re-host Newt on lower level code when a port to an AWT-less Mac OS X-based mobile device is done. Added support to NativeWindow and Newt for wrapping a Java-based window from a toolkit like the AWT, and added appropriate code to the GLDrawableFactory implementations to recognize and handle these NativeWindows. Fixed naming of native method for JAWT_DrawingSurfaceInfo.platformInfo0(). Fixed linker definition on Mac and cleaned up Windows variants. Fixed intptr_t definitions in ES1 and ES2 native code. Added workaround for GLU type reference in com.sun.opengl.util.texture.Texture. Fixed bugs in Newt event dispatching. Tested with RedSquare demo on Mac OS X. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1698 232f8b59-042b-4e1e-8c03-345bb8c30851
* Added getSurfaceHandle() to NativeWindow abstraction in support of Kenneth Russel2008-06-261-0/+33
| | | | | | | | | | | | Windows platform where there is a distinction between the window handle (HWND) and window surface (HDC). WGL implementation now refers to window surface instead of window handle. JAWT implementation returns same value for both window handle and window surface. Newt creates window surface on demand; unneeded for EGL binding. RedSquare demo now runs on Windows with Newt + GL2. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1695 232f8b59-042b-4e1e-8c03-345bb8c30851
* GLES1 NEWT X11 - RedSquare - workingSven Gothel2008-06-251-5/+6
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1683 232f8b59-042b-4e1e-8c03-345bb8c30851
* Native Compilation: Partitioning and X11 cleanSven Gothel2008-06-255-0/+0
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1680 232f8b59-042b-4e1e-8c03-345bb8c30851
* 2nd big refactoring.Sven Gothel2008-06-212-39/+182
| | | | | | | | | | | | | | | | | | | | | | Goals are orthogonal components for: - OS Windowing system - NEWT, X11, Windows, MacOsX - GL Windowing GLUE - EGL, GLX, WGL, CGL - GL profiles - core and util packages - generate all Java components from any platform All above goals are achieved. TODO: - Native compilation fix and test - Check/Fix Win32, MacOSX and the mobile devices - .. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1670 232f8b59-042b-4e1e-8c03-345bb8c30851
* *** empty log message ***Sven Gothel2008-06-211-0/+9
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1669 232f8b59-042b-4e1e-8c03-345bb8c30851
* Added Immediate Mode Sink (ImmModeSInk)Sven Gothel2008-06-031-0/+2
| | | | | | | | | | | | | | | to allow ES 1.1 to use immediate mode rendering. It uses VBO which can also be cached, see GLUquadric 'hack'. GLUquadrics are now enabled for ES 1. Added Sync to Newt's X11Window setVisible, to make sure the window is established for the GLdrawable. TODO: proper distinguishing of GL profiles and ImmModeSink usage .. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1661 232f8b59-042b-4e1e-8c03-345bb8c30851
* wipSven Gothel2008-06-011-22/+1
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1658 232f8b59-042b-4e1e-8c03-345bb8c30851
* Ported Newt event handling to Windows. Minor bug fixes to Windows Kenneth Russel2008-06-011-28/+123
| | | | | | | | platform related to recent code refactoring. Unicode correctness in Windows native code. Cosmetic fixes. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1657 232f8b59-042b-4e1e-8c03-345bb8c30851
* refactoring .. wip ..Sven Gothel2008-06-011-28/+22
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1656 232f8b59-042b-4e1e-8c03-345bb8c30851
* Refactoring JOGL to partition core windowing, AWT, GL, ES1 and ES2 .. WIPSven Gothel2008-06-011-49/+178
| | | | | | | | Compile Clean: X11, noAWT, ES1, no *.impl.x11/win/macosx See jogl/make/build.xml for new build properties. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1654 232f8b59-042b-4e1e-8c03-345bb8c30851
* Completing com.sun.javafx.newt.* package, WIP, working under X11/ES1.1.Sven Gothel2008-05-301-72/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Fixed: - EGLDrawable[Factory] - Object target is a 'long[3]' with [display, screen, window] native handles. Depending on the platform, display and screen handles may be 0. - Moved EGL.eglGetDisplay and EGL.eglInitialize from EGLDrawableFactory -> EGLDrawable, since the factory has no notion of the native handles, but the display is necessary. - newt.*: - Added Display and Screen abstraction - Added 'long[] Window.getHandles()', to feed EGLDrawableFactory.getGLDrawable() with the 3 native handles. - MouseEvent: - Java: Clicked and Dragged working - native/X11: SelectInput with proper args - KeyEvent: - native/X11: added XSetInputFocus and XLookupString git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1652 232f8b59-042b-4e1e-8c03-345bb8c30851
* Completing com.sun.javafx.newt.* package, WIP, compile clean, but untested.Sven Gothel2008-05-304-14/+389
| | | | | | | | | - Input Event Handling: Mouse and Keyboard. - X11 port - Using the VisualID to construct the native window. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1651 232f8b59-042b-4e1e-8c03-345bb8c30851
* Changes to WindowsWindow.c to compile on Windows CE. Slight changes to Kenneth Russel2008-05-301-2/+14
| | | | | | | config selection to match C code -- no semantic difference, however. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1649 232f8b59-042b-4e1e-8c03-345bb8c30851
* Made call to ByteOrder.nativeOrder() in BufferUtil reflective so it Kenneth Russel2008-05-291-1/+5
| | | | | | | | | can be done when running on Java SE even if the code is compiled on CDC/FP. Fixed bug in WindowsWindow.c where upcalls from native WndProc were not being made. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1647 232f8b59-042b-4e1e-8c03-345bb8c30851
* Various bug fixes. Incorporated minimal window abstraction to Kenneth Russel2008-05-291-0/+299
| | | | | | | | | bootstrap EGL subsystem. Added back in GLU generation for ES 2. This code creates and shows the window for the demos.es1.RedSquare demo, but nothing is rendered yet. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1645 232f8b59-042b-4e1e-8c03-345bb8c30851
* Refactorings to support building JOGL for OpenGL ES 1 and OpenGL ES 2. Kenneth Russel2008-05-132-0/+518
| | | | | | | | | | | | | | | | | | | | | "ant -Djogl.es1=1" builds JOGL for OpenGL ES 1. "ant -Djogl.es2=1" builds JOGL for OpenGL ES 2. "ant" builds JOGL for desktop OpenGL (2.1). Building desktop OpenGL is currently broken (FIXME) -- more refactorings are necessary. When compiling, it is currently necessary to specify -Djogl.noglnatives=1 on the ant command line as well, because the generated native code does not link properly since we do not have OpenGL ES libraries on the desktop. Building the generated native code using a cross-compiler is not yet hooked up into the ant build mechanism. It is necessary to build the generated native code with external tools. Also incorporated spatialized audio framework using Windows waveOut device; this is a temporary measure until a different workspace can be found for this code. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1630 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixed Issue 341: JNI Global Reference in native code prevents clean applet ↵Kenneth Russel2008-02-031-30/+1
| | | | | | | | | | | | | | | | termination Simplified the native code in JAWT_DrawingSurfaceInfo.c to only fabricate the direct ByteBuffer wrapping the JAWT "platformInfo" struct, moving the construction of the wrapping JAWT_PlatformInfo up to Java. Verified fix with reloading of JOGL applets via the new JNLP applet launching support in the new Java Plug-In. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@1512 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixed Issue 259: need a copy context Kenneth Russel2007-01-071-0/+6
| | | | | | | | | | Added and specified GLContext.copy() and supplied implementations on Windows, X11 and Mac OS X platforms. New code is untested at this time. May need to make subsequent changes on X11 and Mac platforms where new code has not been compiled yet. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@1075 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixes for building with Visual Studio .NET 2003 (Service Pack 1)Kenneth Russel2007-01-031-2/+2
| | | | git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@1063 232f8b59-042b-4e1e-8c03-345bb8c30851
* Added parameter validation for stereo bit in particular to fix problemKenneth Russel2006-12-201-31/+25
| | | | | | | | | | | with Java 3D QueryProperties demo; unclear, however, if that demo is returning correct results, as it always seems to report that stereo is available when it seems it isn't. Probably need to use new getChosenGLCapabilities() method to implement this more correctly in the Java 3D/JOGL pipeline. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@1035 232f8b59-042b-4e1e-8c03-345bb8c30851
* Removed native code for DRIHack and replaced it with code using theKenneth Russel2006-11-241-59/+0
| | | | | | | | | | | | | | | | | | | | | GlueGen runtime library (specifically the NativeLibrary class). Updated the build.xml, in particular the dist targets, to no longer build or copy this native library. Updated the NativeLibrary class to allow specification of the full path to the library. Removed the GlueGen runtime classes from jogl.jar; these are now expected to reside in gluegen-rt.jar and it is expected that developers will have this on their CLASSPATH. Updated the dist target to include the gluegen-rt native library and jar file. Updated the JOGLAppletLauncher to download and unpack the gluegen-rt-natives jar as well as the jogl-natives jar. Updated the HowToBuild, user guide, and JOGLAppletLauncher documentation for this restructuring. Fixed bug in gluegen-cpptasks.xml in detection of Solaris/SPARCv9 and refactored targets further. Tested on Solaris/x86 so far; further testing and debugging of the nightly builds and applet launcher, and update of the JOGL applet test, to follow. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@993 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixed Issue 213: Expose GLCaps from GLDrawable Kenneth Russel2006-11-191-61/+101
| | | | | | | | | | | | | | | | | | | Added getChosenGLCapabilities() to the GLDrawable interface. Implemented on Windows, Unix and Mac OS X platforms with various techniques. Attempts to provide correct answers in all cases, even when the GLCapabilitiesChooser mechanism is not supported. Required addition of new platform-specific Java code in most cases to either re-convert existing PIXELFORMATDESCRIPTORS / XVisualInfos, or to query the pixel format or visual chosen for drawables like pbuffers for which the chooser mechanism is not (yet) implemented. Tested on Windows, Solaris/x86, and Mac OS X with on-screen, off-screen and pbuffer drawables. (Full support for the Java2D/JOGL bridge is not yet in place; the answer returned from the GLJPanel in this case is currently the default GLCapabilities, and it is likely that "external" GLDrawables will return null.) git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@989 232f8b59-042b-4e1e-8c03-345bb8c30851
* Fixed build problems on Solaris with Xinerama support for Issue 216;Kenneth Russel2006-05-281-7/+5
| | | | | | | now builds and runs on Linux and Solaris at least on non-Xinerama setups git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@783 232f8b59-042b-4e1e-8c03-345bb8c30851
* Preliminary fix forKenneth Russel2006-05-286-0/+992
| | | | | | | | | | | | Issue 216: Cannot create GLCanvas on non-default GraphicsDevice Made JOGL Xinerama-aware; now uses screen 0 rather than the screen reported from the AWT GraphicsDevice when Xinerama is enabled. So far only compiled and tested on non-Xinerama configuration on Linux; more testing needed on Xinerama setups and on Solaris. git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@782 232f8b59-042b-4e1e-8c03-345bb8c30851