]> git.sesse.net Git - vlc/blobdiff - modules/gui/beos/AudioOutput.cpp
Fix input deadlocks in macosx gui
[vlc] / modules / gui / beos / AudioOutput.cpp
index 34db378c532e34600b83b4ff041e2dc9a4282895..0f2300ead756e69b1fb84903839c94ceac8cfa4b 100644 (file)
@@ -1,8 +1,8 @@
 /*****************************************************************************
  * AudioOutput.cpp: BeOS audio output
  *****************************************************************************
- * Copyright (C) 1999, 2000, 2001 VideoLAN
- * $Id: AudioOutput.cpp,v 1.29 2003/05/08 10:40:31 titer Exp $
+ * Copyright (C) 1999, 2000, 2001 the VideoLAN team
+ * $Id$
  *
  * Authors: Jean-Marc Dressler <polux@via.ecp.fr>
  *          Samuel Hocevar <sam@zoy.org>
@@ -12,7 +12,7 @@
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
@@ -20,7 +20,7 @@
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
 /*****************************************************************************
@@ -36,7 +36,7 @@
 
 
 #include <vlc/vlc.h>
-#include <vlc/aout.h>
+#include <vlc_aout.h>
 extern "C"
 {
     #include <aout_internal.h>
@@ -50,7 +50,7 @@ typedef struct aout_sys_t
 {
     BSoundPlayer * p_player;
     mtime_t        latency;
-    
+
 } aout_sys_t;
 
 /*****************************************************************************
@@ -69,7 +69,7 @@ int E_(OpenAudio) ( vlc_object_t * p_this )
     p_aout->output.p_sys = (aout_sys_t*) malloc( sizeof( aout_sys_t ) );
     if( p_aout->output.p_sys == NULL )
     {
-        msg_Err( p_aout, "Not enough memory" );
+        msg_Err( p_aout, "out of memory" );
         return -1;
     }
     aout_sys_t * p_sys = p_aout->output.p_sys;
@@ -84,13 +84,13 @@ int E_(OpenAudio) ( vlc_object_t * p_this )
         p_aout->output.output.i_physical_channels
             = AOUT_CHAN_LEFT | AOUT_CHAN_RIGHT;
     }
+
     media_raw_audio_format * p_format;
     p_format = (media_raw_audio_format*)
         malloc( sizeof( media_raw_audio_format ) );
-    
+
     p_format->channel_count = i_nb_channels;
-    p_format->frame_rate = p_aout->output.output.i_rate;    
+    p_format->frame_rate = p_aout->output.output.i_rate;
     p_format->format = media_raw_audio_format::B_AUDIO_FLOAT;
 #ifdef WORDS_BIGENDIAN
     p_format->byte_order = B_MEDIA_BIG_ENDIAN;
@@ -151,23 +151,23 @@ static void Play( void * _p_aout, void * _p_buffer, size_t i_size,
 
     if( p_aout_buffer != NULL )
     {
-        p_aout->p_vlc->pf_memcpy( p_buffer, p_aout_buffer->p_buffer,
+        p_aout->p_libvlc->pf_memcpy( p_buffer, p_aout_buffer->p_buffer,
                                   MIN( i_size, p_aout_buffer->i_nb_bytes ) );
         if( p_aout_buffer->i_nb_bytes < i_size )
         {
-            p_aout->p_vlc->pf_memset( p_buffer + p_aout_buffer->i_nb_bytes,
+            p_aout->p_libvlc->pf_memset( p_buffer + p_aout_buffer->i_nb_bytes,
                                       0, i_size - p_aout_buffer->i_nb_bytes );
         }
         aout_BufferFree( p_aout_buffer );
     }
     else
     {
-        p_aout->p_vlc->pf_memset( p_buffer, 0, i_size );
+        p_aout->p_libvlc->pf_memset( p_buffer, 0, i_size );
     }
 }
 
 /*****************************************************************************
- * DoNothing 
+ * DoNothing
  *****************************************************************************/
 static void DoNothing( aout_instance_t *p_aout )
 {