From 70b648f9c8fa9c9cb302b9bbb06820a3cf23d71f Mon Sep 17 00:00:00 2001
From: Sven Gothel <sgothel@jausoft.com>
Date: Mon, 13 Dec 2010 12:28:06 +0100
Subject: Window Support added ; Win64 libs & license files

- plays on linux/window now
- ant build files fixed -> Windows support
- windows OpenAL 32/64 bit: see make/lib/FILES.txt make/lib/oalinst-license.txt)
- linux libs: added .1 to suffix
- added Debug impl
- catch EAX init exception (ie unsatisfied link error)
- EAX proper blocked init

TODO:
    - check on osx
    - joal-demos
---
 src/java/com/jogamp/openal/ALFactory.java | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

(limited to 'src/java/com/jogamp/openal/ALFactory.java')

diff --git a/src/java/com/jogamp/openal/ALFactory.java b/src/java/com/jogamp/openal/ALFactory.java
index 64da325..e7ec774 100644
--- a/src/java/com/jogamp/openal/ALFactory.java
+++ b/src/java/com/jogamp/openal/ALFactory.java
@@ -44,6 +44,8 @@ import com.jogamp.openal.impl.*;
  * @author Kenneth Russell
  */
 public class ALFactory {
+  public static final boolean DEBUG = Debug.debug("Factory");
+
   private static boolean initialized = false;
   private static AL al;
   private static ALC alc;
@@ -54,9 +56,12 @@ public class ALFactory {
     try {
       if (!initialized) {
         if(null == ALImpl.getALProcAddressTable()) {
-            throw new RuntimeException("AL not initialized (ProcAddressTable null)");
+            throw new ALException("AL not initialized (ProcAddressTable null)");
         }
         initialized = true;
+        if(DEBUG) {
+            System.err.println("AL initialized");
+        }
       }
     } catch (UnsatisfiedLinkError e) {
       throw new ALException(e);
@@ -72,7 +77,7 @@ public class ALFactory {
   public static AL getAL() throws ALException {
     initialize();
     if (al == null) {
-      al = new ALImpl();
+        al = new ALImpl();
     }
     return al;
   }
@@ -86,7 +91,7 @@ public class ALFactory {
   public static ALC getALC() throws ALException{
     initialize();
     if (alc == null) {
-      alc = new ALCImpl();
+        alc = new ALCImpl();
     }
     return alc;
   }
-- 
cgit v1.2.3