]> git.sesse.net Git - vlc/blobdiff - src/audio_output/common.c
* src/audio_output/common.c: added error message upon invalid initialisation.
[vlc] / src / audio_output / common.c
index 239ba1f0b487b32e2fa9a8e6bc0d234a1bfd50d9..7c31d0733ae89b8e5604dd12a135788ca6cc82c6 100644 (file)
@@ -1,7 +1,7 @@
 /*****************************************************************************
  * common.c : audio output management of common data structures
  *****************************************************************************
- * Copyright (C) 2002-2004 VideoLAN
+ * Copyright (C) 2002-2005 the VideoLAN team
  * $Id$
  *
  * Authors: Christophe Massiot <massiot@via.ecp.fr>
@@ -18,7 +18,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.
  *****************************************************************************/
 
 /*****************************************************************************
@@ -129,12 +129,20 @@ void aout_FormatPrepare( audio_sample_format_t * p_format )
         i_result = 2;
         break;
 
+    case VLC_FOURCC('u','2','4','l'):
+    case VLC_FOURCC('s','2','4','l'):
+    case VLC_FOURCC('u','2','4','b'):
+    case VLC_FOURCC('s','2','4','b'):
+        i_result = 3;
+        break;
+
     case VLC_FOURCC('f','l','3','2'):
     case VLC_FOURCC('f','i','3','2'):
         i_result = 4;
         break;
 
     case VLC_FOURCC('s','p','d','i'):
+    case VLC_FOURCC('s','p','d','b'): /* Big endian spdif output */
     case VLC_FOURCC('a','5','2',' '):
     case VLC_FOURCC('d','t','s',' '):
     case VLC_FOURCC('m','p','g','a'):
@@ -416,6 +424,11 @@ void aout_FifoDestroy( aout_instance_t * p_aout, aout_fifo_t * p_fifo )
  *****************************************************************************/
 void aout_DateInit( audio_date_t * p_date, uint32_t i_divider )
 {
+    if( i_divider == 0 )
+    {
+        msg_Err( p_aout, "initialising date with zero divider" );
+    }
+
     p_date->date = 0;
     p_date->i_divider = i_divider;
     p_date->i_remainder = 0;