summaryrefslogtreecommitdiffstats
path: root/libmpdemux
diff options
context:
space:
mode:
authoralex <alex@b3059339-0415-0410-9bf9-f77b7e298cf2>2004-12-27 17:30:15 +0000
committeralex <alex@b3059339-0415-0410-9bf9-f77b7e298cf2>2004-12-27 17:30:15 +0000
commit507121f7fe2d170dd8db99d3112602036ddef718 (patch)
tree38b26e115cfadde356b005496286f78307839440 /libmpdemux
parent00f99a82a8f57573e3e6982cf9d014c9b9d8a68b (diff)
downloadmpv-507121f7fe2d170dd8db99d3112602036ddef718.tar.bz2
mpv-507121f7fe2d170dd8db99d3112602036ddef718.tar.xz
removing AFMT_ dependancy
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@14246 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r--libmpdemux/demuxer.c4
-rw-r--r--libmpdemux/tv.c32
-rw-r--r--libmpdemux/tvi_bsdbt848.c3
-rw-r--r--libmpdemux/tvi_v4l.c4
-rw-r--r--libmpdemux/tvi_v4l2.c4
5 files changed, 24 insertions, 23 deletions
diff --git a/libmpdemux/demuxer.c b/libmpdemux/demuxer.c
index a254c34a3e..503a46f5b2 100644
--- a/libmpdemux/demuxer.c
+++ b/libmpdemux/demuxer.c
@@ -18,7 +18,7 @@
#include "stheader.h"
#include "mf.h"
-#include "../libao2/afmt.h"
+#include "../libaf/af_format.h"
#include "../libvo/fastmemcpy.h"
// Should be set to 1 by demux module if ids it passes to new_sh_audio and
@@ -91,7 +91,7 @@ sh_audio_t* new_sh_audio(demuxer_t *demuxer,int id){
sh = demuxer->a_streams[id];
// set some defaults
sh->samplesize=2;
- sh->sample_format=AFMT_S16_NE;
+ sh->sample_format=AF_FORMAT_S16_NE;
sh->audio_out_minsize=8192;/* default size, maybe not enough for Win32/ACM*/
if (identify && !demux_aid_vid_mismatch)
mp_msg(MSGT_GLOBAL, MSGL_INFO, "ID_AUDIO_ID=%d\n", id);
diff --git a/libmpdemux/tv.c b/libmpdemux/tv.c
index 1bbbf8ca6f..706949b34b 100644
--- a/libmpdemux/tv.c
+++ b/libmpdemux/tv.c
@@ -29,8 +29,7 @@ int tv_param_on = 0;
#include "demuxer.h"
#include "stheader.h"
-#include "../libao2/afmt.h"
-#include "../libao2/audio_out.h"
+#include "../libaf/af_format.h"
#include "../libvo/img_format.h"
#include "../libvo/fastmemcpy.h"
@@ -516,6 +515,7 @@ int demux_open_tv(demuxer_t *demuxer)
{
int audio_format;
int sh_audio_format;
+ char buf[128];
/* yeah, audio is present */
@@ -527,24 +527,24 @@ int demux_open_tv(demuxer_t *demuxer)
switch(audio_format)
{
- case AFMT_U8:
- case AFMT_S8:
- case AFMT_U16_LE:
- case AFMT_U16_BE:
- case AFMT_S16_LE:
- case AFMT_S16_BE:
- case AFMT_S32_LE:
- case AFMT_S32_BE:
+ case AF_FORMAT_U8:
+ case AF_FORMAT_S8:
+ case AF_FORMAT_U16_LE:
+ case AF_FORMAT_U16_BE:
+ case AF_FORMAT_S16_LE:
+ case AF_FORMAT_S16_BE:
+ case AF_FORMAT_S32_LE:
+ case AF_FORMAT_S32_BE:
sh_audio_format = 0x1; /* PCM */
break;
- case AFMT_IMA_ADPCM:
- case AFMT_MU_LAW:
- case AFMT_A_LAW:
- case AFMT_MPEG:
- case AFMT_AC3:
+ case AF_FORMAT_IMA_ADPCM:
+ case AF_FORMAT_MU_LAW:
+ case AF_FORMAT_A_LAW:
+ case AF_FORMAT_MPEG2:
+ case AF_FORMAT_AC3:
default:
mp_msg(MSGT_TV, MSGL_ERR, "Audio type '%s (%x)' unsupported!\n",
- audio_out_format_name(audio_format), audio_format);
+ af_fmt2str(audio_format, &buf, 128), audio_format);
goto no_audio;
}
diff --git a/libmpdemux/tvi_bsdbt848.c b/libmpdemux/tvi_bsdbt848.c
index d4b1d6e639..ba2950844b 100644
--- a/libmpdemux/tvi_bsdbt848.c
+++ b/libmpdemux/tvi_bsdbt848.c
@@ -61,6 +61,7 @@
#endif
#endif
+#include "../libaf/af_format.h"
#include "../libvo/img_format.h"
#include "tv.h"
@@ -246,7 +247,7 @@ static int control(priv_t *priv, int cmd, void *arg)
case TVI_CONTROL_AUD_GET_FORMAT:
{
- (int)*(void **)arg = AFMT_S16_LE;
+ (int)*(void **)arg = AF_FORMAT_S16_LE;
return(TVI_CONTROL_TRUE);
}
case TVI_CONTROL_AUD_GET_CHANNELS:
diff --git a/libmpdemux/tvi_v4l.c b/libmpdemux/tvi_v4l.c
index 9d383a8c3c..397f63f20f 100644
--- a/libmpdemux/tvi_v4l.c
+++ b/libmpdemux/tvi_v4l.c
@@ -41,7 +41,7 @@
#endif
#include "mp_msg.h"
-#include "../libao2/afmt.h"
+#include "../libaf/af_format.h"
#include "../libvo/img_format.h"
#include "../libvo/fastmemcpy.h"
#include "../libvo/videodev_mjpeg.h"
@@ -1285,7 +1285,7 @@ static int control(priv_t *priv, int cmd, void *arg)
/* ========== AUDIO controls =========== */
case TVI_CONTROL_AUD_GET_FORMAT:
{
- *(int *)arg = AFMT_S16_LE;
+ *(int *)arg = AF_FORMAT_S16_LE;
return(TVI_CONTROL_TRUE);
}
case TVI_CONTROL_AUD_GET_CHANNELS:
diff --git a/libmpdemux/tvi_v4l2.c b/libmpdemux/tvi_v4l2.c
index 211ab83029..f2d431673f 100644
--- a/libmpdemux/tvi_v4l2.c
+++ b/libmpdemux/tvi_v4l2.c
@@ -43,7 +43,7 @@ known issues:
#include "videodev2.h"
#include "../mp_msg.h"
#include "../libvo/img_format.h"
-#include "../libao2/afmt.h"
+#include "../libaf/af_format.h"
#include "tv.h"
#include "audio_in.h"
@@ -731,7 +731,7 @@ static int control(priv_t *priv, int cmd, void *arg)
}
return TVI_CONTROL_TRUE;
case TVI_CONTROL_AUD_GET_FORMAT:
- *(int *)arg = AFMT_S16_LE;
+ *(int *)arg = AF_FORMAT_S16_LE;
mp_msg(MSGT_TV, MSGL_V, "%s: get audio format: %d\n",
info.short_name, *(int *)arg);
return TVI_CONTROL_TRUE;