Build Fix -- Remove some duplicate symbol defs to appease ld.
[sxemacs] / src / media / sound.c
index 1eca185..0678fc2 100644 (file)
@@ -46,7 +46,7 @@ Lisp_Object Vsound_alist;
 Lisp_Object Vsynchronous_sounds;
 Lisp_Object Vnative_sound_only_on_console;
 Lisp_Object Q_volume, Q_pitch, Q_duration, Q_sound;
-Lisp_Object Q_device, Q_server, Q_client, Q_keep_open;
+Lisp_Object Q_server, Q_client, Q_keep_open;
 Lisp_Object Qplay_sound;
 
 #ifdef HAVE_AO_SOUND
@@ -75,6 +75,9 @@ Lisp_Object Qplay_sound;
 #include "sound-oss.h"
 #endif
 
+/* for CHECK_NUMBER and COMPARABLEP */
+#include "ent/ent.h"
+
 Lisp_Object Qaudio_devicep;
 Lisp_Object Qaudio_jobp;
 Lisp_Object Vdefault_audio_device;
@@ -405,8 +408,8 @@ make_audio_job(Lisp_Object stream, Lisp_Object device, Lisp_Object sentinel)
 
        aj->state = MTSTATE_UNKNOWN;
        aj->play_state = MTPSTATE_UNKNOWN;
-#ifdef EF_USE_ASYNEQ
        SXE_MUTEX_INIT(&aj->mtx);
+#ifdef EF_USE_ASYNEQ
        audio_job_queue(aj) = NULL;
 #endif
 
@@ -416,7 +419,9 @@ make_audio_job(Lisp_Object stream, Lisp_Object device, Lisp_Object sentinel)
        aj->buffer = NULL;
        aj->buffer_alloc_size = 0;
 
-       SOUND_DEBUG_AJ("created: 0x%lx\n", (long unsigned int)aj);
+       SOUND_DEBUG_AJ("created: 0x%lx stream 0x%lx device 0x%lx sentinel 0x%lx\n",
+                      (long unsigned int)aj, (long unsigned int)stream,
+                       (long unsigned int)device, (long unsigned int) sentinel);
        return aj;
 }
 
@@ -539,7 +544,7 @@ the playback volume.
        aj->queue = NULL;
 #endif
 
-       SOUND_DEBUG_AJ("calling play meth\n");
+       SOUND_DEBUG_AJ("sync calling play meth\n");
        XAUDIO_DEVICE(device)->meths->play(aj);
 
        if (!NILP(sentinel)) {
@@ -1134,6 +1139,16 @@ Valid keywords for Pulse are:
 :sink - the name of the sink to connect to (e.g. "output")
 :source - the name of the source to record from (e.g. "mic_in")
 :client - how to call the client on the server (default "SXEmacs")
+:role - a one-word description of the "type" of media to be played
+  on the server. It can be one of:
+          "video" - for movie/video streams
+          "music" - for music streams (like mp3's, oga's etc)
+           "game" - for audio from games
+          "event" - for event sounds (this is the default)
+          "phone" - for VoIP and Instant Messaging audio
+      "animation" - for animations
+     "production" - for audio production applications
+           "a11y" - for accessibility applications
 :stream - how to call the stream on the server (e.g. "fancy-sound")
 :immediate - connect to sink immediately and keep the connection
   alive as long as the audio device exists (default `t')