aboutsummaryrefslogtreecommitdiffstats
path: root/src/java/com/jogamp
Commit message (Collapse)AuthorAgeFilesLines
* Fix FunctionTask's run()/eval(..) return value assignment: Ensure it's done ↵Sven Gothel2013-02-143-34/+38
| | | | | | before syncObject.notifyAll() ; Make methods final Fixes commit b387d012103a02eb7d5eb919306583295ef09a38.
* Adding Function and FunctionTask extending RunnableTask functionalitySven Gothel2013-02-134-118/+379
| | | | | Function allows passing arguments and having a return value in contrast to Runnable, where FunctionTask allows a Function to be invoked and waited for.
* Bug 681: Add Elf Parsing for other OS than Linux, if ARM and !ANDROID using ↵Sven Gothel2013-02-091-14/+40
| | | | | | | | /proc/self/exe (Linux) or a found java/jvm native lib. - PlatformPropsImpl.queryABITypeImpl: Check Elf Header for ARM + !ANDROID (i.e. add other OS than Linux, use native java/jmv lib) - NativeLibrary.enumerateLibraryPaths: Add 'sun.boot.library.path' to enumeration! - TestElfReader01: Add test for finding java/jvm native lib and parse it
* IOUtil.copyStream2ByteBuffer: Turns out on Android, no -1 (EOS) is returned ↵Sven Gothel2013-02-011-2/+2
| | | | - relax loop-condition (hope thats ok)
* IOUtil.copyStream2ByteBuffer: read while numRead > -1 ; add variant w/ ↵Sven Gothel2013-02-011-4/+19
| | | | initialCapcity
* Cleanup GlueGen config 'ExtendedInterfaceSymbols*'Sven Gothel2013-01-311-17/+64
| | | | | | | | | | | | | | | | | | | Semantics Change: ExtendedInterfaceSymbolsOnly was used for implementation generation only, which is considered a bug! - ExtendedInterfaceSymbolsIgnore C.java - Ignore symbols in C.java for interface generation - ExtendedInterfaceSymbolsOnly C.java - Only use symbols in C.java for interface generation - ExtendedImplementationSymbolsIgnore C.java - Ignore symbols in C.java for implementation generation - ExtendedImplementationSymbolsOnly C.java - Only use symbols in C.java for implementation generation - ExtendedIntfAndImplSymbolsIgnore C.java - Ignore symbols in C.java for interface and implementation generation - ExtendedIntfAndImplSymbolsOnly C.java - Only use symbols in C.java for interface and implementation generation
* GlueGen: NativeLibrary Fix, JNILibLoaderBase EnhancementSven Gothel2013-01-302-81/+135
| | | | | | | | | | | | | | | | | | | - NativeLibrary Fix - enumerateLibraryPaths(..): - Properly iterate through all prefix _and_ suffix. - Make public for JNILibLoaderBase.loadLibraryInternal(..) - isValidNativeLibraryName(..): - Stop iterating through prefix, if previously found but suffix doesn't match. - JNILibLoaderBase.loadLibraryInternal(..) Enhancement - Mark customLibLoader FIXME: remove (we will get rid of jnlp.launcher.class) - If System.load(TempJarCache) and System.loadLibrary(plainLibName) fails, use NativeLibrary.enumerateLibraryPaths() w/ System.load(..) as last resort. Tested on Linux x86_64 Java6 and OSX Java7 manually, no regressions expected.
* Modified Java 1.5 Buffers patch 2b7d1b1d25cb2cd73311ec9159b465f0391bf5e0 - ↵Sven Gothel2013-01-193-21/+43
| | | | | | | | | | | | | | May break GCJ/ECJ .. needs to be revised. - Adding JAVA_6 in PlatformPropsImpl - Buffers.isDirect() chooses fast-path iff JAVA_6, otherwise using reflection (GCJ/ECJ) - Adding JAVA_6 info in VersionUtil - API doc: Refine JAVA_SE and JAVA_6 spec. TODO: In case GCJ etc is unable to compile the JAVA_6 code even though it uses a static condition (probably not), We have to wrap isStatic in an own class, one for JAVA_6 and one for <= 1.5. This will be a good exercise for further issues we may have w/ Java <= 1.5.
* Merge remote-tracking branch 'xranby/gcj-gij'Sven Gothel2013-01-181-3/+17
|\
| * Buffer.isDirect() operation is undefined w/ Eclipse ecj and GCJ gij JRE.Xerxes Rånby2013-01-181-3/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix for the runtime error using GCJ gij JRE: java.lang.NoSuchMethodError: method java.nio.Buffer.isDirect with signature ()Z was not found. at com.jogamp.common.nio.Buffers.isDirect(Buffers.java:363) Also Eclipse ecj refuses to compile code using java.nio.Buffer.isDirect(). ---------- 1. ERROR ... return ((Buffer) buf).isDirect(); ^^^^^^^^ The method isDirect() is undefined for the type Buffer Signed-off-by: Xerxes Rånby <[email protected]>
* | RecursiveLock.getHoldCount(): Fix API doc formattingSven Gothel2013-01-181-4/+7
| |
* | Buffers: Fix typoSven Gothel2013-01-181-2/+2
|/
* PrimitiveStack: Add 'void position(int)' to set new position. Add test case ↵Sven Gothel2012-12-312-6/+22
| | | | w/ initialSizeElem:=0.
* Add com.jogamp.common.util.PrimitiveStack (FloatStack and IntegerStack), a ↵Sven Gothel2012-12-302-0/+229
| | | | | | | | | | | | simple primitive stack implementation. Currently only FILO put/get operations are implemented using either primitive arrays as I/O itself or <Type>Buffer. Unit tests are included.. Note: Only FloatStack is implemented in a manual, where others (IntegerStack) is derived (generated) from it. Same goes w/ unit tests.
* Fix Bug625: StructAccessor missing setShortsAt() and getShortsAt() methods ↵Sven Gothel2012-12-301-0/+13
| | | | | | | | | | for short[] For short[] Java code gets emitted for an StructAccessor object that uses: void setShortsAt(int i, short[] shorts) short[] getShortsAt(int i, short[] shorts) Problem was that StructAccessor.java had no such methods - added.
* IntIntHashMap: Add privileged for 'getDeclaredMethod(..)'; Add StringBuilder ↵v2.0-rc11Sven Gothel2012-10-311-42/+75
| | | | toString(..); Add more generics coding.
* IntBitfield: Add API doc; Enhance put() method, return previous value to be ↵Sven Gothel2012-10-271-7/+27
| | | | used more versatile and write only if value changed.
* Adding com.jogamp.common.util.IntBitfield: Simple bitfield holder class ↵Sven Gothel2012-10-271-0/+71
| | | | | | | using an int[] storage. IntBitfield comes in handy to store bit states of a wide value range w/o being a memory hog an O(1) access, e.g. keyCode -> isPressed maps etc.
* Fix Bug 608: Push down TempJarCache.findLibrary(..) from ↵Sven Gothel2012-10-252-16/+15
| | | | | | | JNILibLoaderBase.loadLibraryInternal() to NativeLibrary.findLibrary(..) This allows using TempJarCache (if used/initialized) for native 'tool' libraries as well. This is the case of JOAL's attempt to load the provided 'libopenal.so'
* VersionNumber: API doc fixSven Gothel2012-10-241-1/+1
|
* VersionNumber: Add API doc for string parsingSven Gothel2012-10-241-0/+7
|
* VersionNumber: Remove printing Exception (was added for debugging purposes)Sven Gothel2012-10-241-1/+1
|
* Fix VersionNumber: Non digits cut off pattern was '\D.*' and cut off digits ↵Sven Gothel2012-10-241-43/+41
| | | | | | | | | | | | | | | | | | | in case leading non digits appear. '\D.*' matches a leading non-digit and then any character. First the string is tokenized by delim: "OpenGL ES GLSL ES 1.0.16" -> "OpenGL ES GLSL ES 1", "0", "16" Enhance pattern as follows and access collected group if matching: // group1: \D* == leading non digits, optional // group2: \d* == digits // group3: .* == any pending chars, optional final java.util.regex.Pattern nonDigitsCutOff = java.util.regex.Pattern.compile("(\\D*)(\\d*)(.*)"); Reorganized storage from atomic values to int[3] array, allowing simple pattern matching loop. Added unit test.
* Revert "Minor revert of clone replacement w/ copt-ctor of commit ↵Sven Gothel2012-10-183-7/+4
| | | | | | | | | | | | | | | d7fb6a7bcfbd2d5ac452abdcdd31fb4d71441c70" This reverts commit 73e8828566404e864170688dfb4fd530a83f8add. Convinced after discussing semantics w/ Harvey Harrison: "the copy-constructor is way for predictable (as in branch-predictable) and has better cache behavior, it can issue almost all the writes in parallel, and has no exception catching. So, the copy-constructor actually ends up being more efficient, and you get typechecking to boot."
* Fix Buffers.copy<Type>Buffer[asByteBuffer](..): Reset position of the passed ↵Sven Gothel2012-10-181-14/+15
| | | | | | | | | buffer (was missing). This is an API regression as introduced in commit 25cc744f6bd5ca97e0ae58fa7e1c35f7b0f3046d where JOGL's BufferUtil and GlueGen's were merged and API doc elaborated. The latter states the desired fact that the source passed buffer's position shall remain unchanged, however no code was added to take care of this detail.
* Minor revert of clone replacement w/ copt-ctor of commit ↵Sven Gothel2012-10-173-4/+7
| | | | | | d7fb6a7bcfbd2d5ac452abdcdd31fb4d71441c70 clone of ArrayList is more shallow than it's clone operation (?)
* Merge remote-tracking branch 'hharrison/RFC'Sven Gothel2012-10-176-20/+6
|\
| * gluegen: remove two fast-path tests that can never triggerHarvey Harrison2012-10-161-14/+0
| | | | | | | | | | | | | | | | ignores and unimplemented are both Set<Pattern>, they cannot contain a String, immediately after these 'fast paths' we loop over the patterns calling .matches() which makes sense, so remove the misleading tests. Signed-off-by: Harvey Harrison <[email protected]>
| * gluegen: generics annotations for various ArrayList/List useHarvey Harrison2012-10-155-6/+6
| | | | | | | | | | | | | | - Use the copy constructor rather than ArrayList.clone() - constrain listsEqual so the compiler will warn about comparing lists of different types Signed-off-by: Harvey Harrison <[email protected]>
* | Buffers: Add normalized put methods, i.e. incl. value range conversion; New ↵Sven Gothel2012-10-172-2/+269
|/ | | | util. ValueConv for primitive type value conversion
* ProcAddressEmitter: Remove 'guessing' argument names from types, since they ↵Sven Gothel2012-10-162-18/+2
| | | | are ambiguous - better use default generic ones to avoid confusion.
* Reducing Type's equalsSven Gothel2012-10-161-32/+0
|
* Intermediate revised Type.java edit before reducingSven Gothel2012-10-161-8/+34
|
* gluegen: conditional cleanup in Type.equals()Harvey Harrison2012-10-141-12/+7
| | | | | | | | - instanceof includes null checking - simplify comparison of name, either they are the same object (possibly null) or they compare equal as strings Signed-off-by: Harvey Harrison <[email protected]>
* gluegen: simplify expression comparing against Boolean.TRUEHarvey Harrison2012-10-131-7/+2
| | | | | | | | | As a last resort we can just return the boolean value directly here, also no need to try/catch as valueOf does not throw any exceptions. Pointed out by Findbugs. Signed-off-by: Harvey Harrison <[email protected]>
* gluegen: remove trailing whitespace from psuedo-C parserHarvey Harrison2012-10-131-5/+5
| | | | Signed-off-by: Harvey Harrison <[email protected]>
* gluegen: break apart a complex conditional in Type.equals() for readabilityHarvey Harrison2012-10-131-2/+15
| | | | | | - move the cheap integer compares earlier before the String comparisons Signed-off-by: Harvey Harrison <[email protected]>
* gluegen: fix equals comparison in cgrammer Type classHarvey Harrison2012-10-131-1/+1
| | | | | | | name was being compared to itself, rather than the name of the type we are comparing, looks like a simple typo. Signed-off-by: Harvey Harrison <[email protected]>
* gluegen: remove trailing whitespace from cgrammer Type classHarvey Harrison2012-10-131-10/+10
| | | | Signed-off-by: Harvey Harrison <[email protected]>
* gluegen: small cleanup and type annotation in GlueGenTaskHarvey Harrison2012-10-131-37/+23
| | | | | | | | - remove an unused import - annotate includesList with type information - small code cleanup now that the type information is present Signed-off-by: Harvey Harrison <[email protected]>
* gluegen: trim trailing whitespace from GlueGenTaskHarvey Harrison2012-10-131-64/+64
| | | | Signed-off-by: Harvey Harrison <[email protected]>
* Buffers.toString(): Add optional format string for single elementSven Gothel2012-10-101-8/+39
|
* Buffers: Add convenient "public static StringBuilder toString(StringBuilder ↵Sven Gothel2012-10-101-1/+63
| | | | | | sb, Buffer buffer)" Sometimes we need to see details of a Buffer w/ it's content, e.g. for debugging purposes.
* Fix NPE in Buffers.slice2Float(), regression of commit ↵Sven Gothel2012-10-091-3/+12
| | | | 86e8c3a8d9f430700e07c485127130da68618e9d
* Buffers.slice2Float(): Reset position and limit of host bufferSven Gothel2012-10-091-22/+25
|
* Refine API doc of Buffers, fix API doc Platform.NEWLINE.Sven Gothel2012-10-032-1/+9
|
* SingletonInstanceServerSocket: Add unit tests; Create new server Thread @ ↵Sven Gothel2012-09-211-5/+8
| | | | start, otherwise we may collide w/ a failed start. Misc: Cleanup / reuse strings.
* Platform: Slight reorder of initialization reducing one PrivilegedAction block.Sven Gothel2012-09-071-42/+41
|
* JNILibLoaderBase: Fix NPE in DEBUG mode if null == stripBasenameSuffixes (JOCL)Sven Gothel2012-08-261-1/+1
|
* Change/Lower ARM Requierements for GNU/Linux & Android-GNU/Linux ARM: ↵Sven Gothel2012-08-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ARMv7hf -> ARMv6hf, ARMv7-soft -> ARMv5te/ARMV6 (soft) platform build config files: lib/gluegen-cpptasks-linux-armv7.xml -> lib/gluegen-cpptasks-linux-armv6.xml lib/gluegen-cpptasks-linux-armv7hf.xml -> lib/gluegen-cpptasks-linux-armv6hf.xml properties: isLinuxARMv7 -> isLinuxARMv6 isLinuxARMv7Armel -> isLinuxARMv6Armel isLinuxARMv7Armhf -> isLinuxARMv6Armhf isAndroidARMv7 -> isAndroidARMv6 isAndroidARMv7Armel -> isAndroidARMv6Armel isAndroidARMv7Armhf -> isAndroidARMv6Armhf targets: compiler.cfg.linux.armv7 -> compiler.cfg.linux.armv6 linker.cfg.linux.armv7 -> linker.cfg.linux.armv6 compiler.cfg.linux.armv6: <compilerarg value="-fpic" /> <compilerarg value="-march=armv5te" /> <compilerarg value="-marm" /> <compilerarg value="-mfloat-abi=softfp" /> <linkerarg value="-fpic" /> <linkerarg value="-march=armv5te" /> <linkerarg value="-marm" /> <linkerarg value="-mfloat-abi=softfp" /> <linkerarg value="-nostdlib" /> <linkerarg value="-Bdynamic" /> compiler.cfg.linux.armv6hf: <compilerarg value="-fpic" /> <compilerarg value="-march=armv6" /> <compilerarg value="-marm" /> <compilerarg value="-mfloat-abi=hard" /> <linkerarg value="-fpic" /> <linkerarg value="-march=armv6" /> <linkerarg value="-marm" /> <linkerarg value="-mfloat-abi=hard" /> <linkerarg value="-nostdlib" /> <linkerarg value="-Bdynamic" /> gluegen-cpptasks-android-armv6.xml: <compilerarg value="-fpic" /> <compilerarg value="-march=armv6" /> <compilerarg value="-mfloat-abi=softfp" /> <compilerarg value="-marm" /> <linkerarg value="-march=armv6" /> <linkerarg value="-mfloat-abi=softfp" /> <linkerarg value="-marm" /> <linkerarg value="-nostdlib" /> <linkerarg value="-Bdynamic" />