Fix Bug 866 - Frequent IndexOutOfBoundsException in jogamp.opengl.egl.EGLGraphicsConfigurationFactory: Add missing 'else' in branch
MacOSXJAWTWindow.CALayer DEBUG: Only Dump AWT location-on-screen if property DEBUG_CALAYER_POS_CRITICAL is explicitly set.

- DEBUG_CALAYER_POS_CRITICAL = nativewindow.debug.JAWT.OSXCALayerPos

Since AWT's location-on-screen query can cause an AWT deadlock,
which is the sole purpose of our custom lock-free impl,
don't enable it's DEBUG output w/ default DEBUG flags.
GLContext CTX_IMPL_* bits: Use 10 cached bits (+1), and 6 uncached (-1) ; CTX_IMPL_FP32_COMPAT_API: "FP32 compat-api" -> "FP32 compat"
jogl: add generic annotations to the packed rectangle utility package

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
jogl: add generics annotations to lists in the waveout code

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Bug 867 - OSX 10.9: Recognize OpenGL Core Profile > 3.0 - Add GLRendererQuirks: Quirk GL4NeedsGL3Request and 'sticky device quirks'

The 'sticky device quirks' are required to share quirks among devices
as collected while mapping the GL versions (audit).

Those are context independent and may only be detected for certain contexts.

They can be pushed/added to the context's quirks, but also queried at context
creation (after mapping) - before the local quirks are being created.
Bug 871 - Add optional xcode.clang support for all modules (Extends Bug 837 w/ xcode's xcrun) - Remove abs. include path.

#include </usr/include/machine/types.h> -> #include <machine/types.h>
Bug 867 - OSX: Allow core >=4 if isMavericksOrLater; Use [kCGLOGLPVersion_GL4_Core, kCGLOGLPVersion_GL3_Core] for major==4 depending on sticky GLRendererQuirks.GL4NeedsGL3Request
Bug 867 OSX [Common Code]: Trigger GLRendererQuirks.GL4NeedsGL3Request and 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.
Use org.junit.Assert instead of deprecated junit.framework.Assert
Fix GLContext: getGLProfile() add missing GLES3; getAvailableGLProfile(device, ..) shall use GLProfile.get(device, ..)
JoglVersion: "Default Profiles on device" -> "GLProfiles on device" - Since we do use the named device
GLProfile: Fix native profile mapping, i.e. use actual mapped profile-impl 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.
Merge remote-tracking branch 'hharrison/master'
Fix regression of commit 34b35c5a0a379a6b4c0b23b9d347a0b1338f0239 - GLContextImpl.createContextARBVersions(..) erroneous upper bounds check.
Fix Bug 872: ES3 and ES3-GLSL Version not properly Handled

GLContext:
  - Proper API doc for Version* fields

  - getStaticGLSLVersionNumber(): ES3 -> Version300

  - hasGLSL(): Add ES3

ShaderCode:
  - addDefaultShaderPrecision():
    - ES2 default precision: Don't 'tune up' default precision for fragment shader, use 'mediump'
    - Add ES3 default precision (equal to ES2 default precision)

  - requiresDefaultPrecision(): Shall returns 'true' for ES3 as well!
TestGLProfile00NEWT: Dump Desktop's and EGL's default-device GLProfiles
API doc: GLStateKeeper (wording), GLAutoDrawable (enh. init desc.), GLDrawable (Shared Context)
spec-overview.html: Shared OpenGL context must be supported .. (GL spec)
Bug 776 GLContext Sharing: Refine API for relaxed and lazy GLContext sharing ; 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