Index: Makefile =================================================================== RCS file: /cvsroot/mplayer/main/Makefile,v retrieving revision 1.295 diff -u -r1.295 Makefile --- Makefile 9 Jul 2004 17:32:17 -0000 1.295 +++ Makefile 26 Jul 2004 17:07:58 -0000 @@ -32,7 +32,7 @@ VO_LIBS = $(AA_LIB) $(X_LIB) $(SDL_LIB) $(GGI_LIB) $(MP1E_LIB) $(MLIB_LIB) $(SVGA_LIB) $(DIRECTFB_LIB) $(CACA_LIB) AO_LIBS = $(ARTS_LIB) $(ESD_LIB) $(JACK_LIB) $(NAS_LIB) $(SGIAUDIO_LIB) -CODEC_LIBS = $(AV_LIB) $(FAME_LIB) $(MAD_LIB) $(VORBIS_LIB) $(THEORA_LIB) $(FAAD_LIB) $(LIBLZO_LIB) $(DECORE_LIB) $(XVID_LIB) $(PNG_LIB) $(Z_LIB) $(JPEG_LIB) $(ALSA_LIB) $(XMMS_LIB) $(MATROSKA_LIB) +CODEC_LIBS = $(AV_LIB) $(FAME_LIB) $(MAD_LIB) $(VORBIS_LIB) $(THEORA_LIB) $(FAAD_LIB) $(LIBLZO_LIB) $(DECORE_LIB) $(XVID_LIB) $(DTS_LIB) $(PNG_LIB) $(Z_LIB) $(JPEG_LIB) $(ALSA_LIB) $(XMMS_LIB) $(MATROSKA_LIB) COMMON_LIBS = libmpcodecs/libmpcodecs.a mp3lib/libMP3.a liba52/liba52.a libmpeg2/libmpeg2.a $(W32_LIB) $(DS_LIB) libaf/libaf.a libmpdemux/libmpdemux.a input/libinput.a postproc/libswscale.a osdep/libosdep.a $(DVDREAD_LIB) $(CODEC_LIBS) $(FREETYPE_LIB) $(TERMCAP_LIB) $(CDPARANOIA_LIB) $(MPLAYER_NETWORK_LIB) $(WIN32_LIB) $(GIF_LIB) $(MACOSX_FRAMEWORKS) $(SMBSUPPORT_LIB) $(FRIBIDI_LIB) $(FONTCONFIG_LIB) $(ENCA_LIB) CFLAGS = $(OPTFLAGS) -Ilibmpdemux -Iloader -Ilibvo $(FREETYPE_INC) $(EXTRA_INC) $(CDPARANOIA_INC) $(SDL_INC) $(X11_INC) $(FRIBIDI_INC) $(DVB_INC) $(XVID_INC) $(FONTCONFIG_INC) $(CACA_INC) # -Wall Index: configure =================================================================== RCS file: /cvsroot/mplayer/main/configure,v retrieving revision 1.887 diff -u -r1.887 configure --- configure 17 Jul 2004 09:53:35 -0000 1.887 +++ configure 26 Jul 2004 17:08:03 -0000 @@ -215,6 +215,7 @@ --enable-xmms build with XMMS inputplugin support [disabled] --disable-mp3lib disable builtin mp3lib [enabled] --disable-liba52 disable builtin liba52 [enabled] + --enable-libdts enable libdts support [autodetect] --disable-libmpeg2 disable builtin libmpeg2 [enabled] Video output: @@ -320,6 +321,8 @@ --with-xvmclib=PATH path to adapter specific XvMCxxxxx.so (e.g. NVIDIA) --with-xvidlibdir=DIR libxvidcore (XviD) in DIR --with-xvidincdir=DIR XviD header in DIR + --with-dtslibdir=DIR libdts library in DIR + --with-dtsincdir=DIR libdts header in DIR --with-livelibdir=DIR path to LIVE.COM Streaming Media libraries --with-xmmsplugindir=DIR path to XMMS plugins --with-xmmslibdir=DIR path to libxmms.so.1 @@ -1191,6 +1194,7 @@ _theora=auto _mp3lib=yes _liba52=yes +_libdts=auto _libmpeg2=yes _matroska_internal=yes _matroska_external=auto @@ -1369,6 +1373,8 @@ --disable-mp3lib) _mp3lib=no ;; --enable-liba52) _liba52=yes ;; --disable-liba52) _liba52=no ;; + --enable-libdts) _libdts=yes ;; + --disable-libdts) _libdts=no ;; --enable-libmpeg2) _libmpeg2=yes ;; --disable-libmpeg2) _libmpeg2=no ;; --enable-internal-matroska) _matroska_internal=yes _matroska_external=no ;; @@ -1635,6 +1641,12 @@ --with-xvidincdir=*) _inc_xvid=-I`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -I,g'` ;; + --with-dtslibdir=*) + _ld_libdts=-L`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'` + ;; + --with-dtsincdir=*) + _inc_libdts=-I`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -I,g'` + ;; --with-sdl-config=*) _sdlconfig=`echo $ac_option | cut -d '=' -f 2` ;; @@ -4831,6 +4843,26 @@ fi echores "$_liba52" +echocheck "libdts support" +if test "$_libdts" = auto ; then + _libdts=no + cat > $TMPC << EOF +#include +#include +int main(void) { dts_init (0); return 0; } +EOF + cc_check $_inc_libdts $_ld_libdts -ldts -lm && _libdts=yes +fi +if test "$_libdts" = yes ; then + _def_libdts='#define CONFIG_DTS 1' + _ld_libdts="$_ld_libdts -ldts -lm" + _codecmodules="libdts $_codecmodules" +else + _def_libdts='#undef CONFIG_DTS' + _nocodecmodules="libdts $_nocodecmodules" +fi +echores "$_libdts" + echocheck "libmpeg2 support" if test "$_libmpeg2" = yes ; then _def_libmpeg2='#define USE_LIBMPEG2 1' @@ -6204,6 +6236,9 @@ XVID = $_xvid XVID_INC = $_inc_xvid XVID_LIB = $_ld_xvid +CONFIG_DTS = $_libdts +DTS_INC = $_inc_libdts +DTS_LIB = $_ld_libdts DECORE_LIB = $_ld_decore $_ld_mp3lame MENCODER = $_mencoder ENCORE_LIB = $_ld_encore $_ld_mp3lame @@ -6545,6 +6580,7 @@ /* Use codec libs included in mplayer CVS / source dist: */ $_def_mp3lib $_def_liba52 +$_def_libdts $_def_libmpeg2 /* Use libfame encoder filter */ Index: etc/codecs.conf =================================================================== RCS file: /cvsroot/mplayer/main/etc/codecs.conf,v retrieving revision 1.351 diff -u -r1.351 codecs.conf --- etc/codecs.conf 15 Jul 2004 20:36:03 -0000 1.351 +++ etc/codecs.conf 26 Jul 2004 17:08:05 -0000 @@ -2216,6 +2216,13 @@ driver libac3 dll "libac3" +audiocodec ffdts + info "DTS" + status working + format 0x2001 + driver ffmpeg + dll "dts" + audiocodec voxware info "VoxWare" status working @@ -2254,6 +2261,12 @@ fourcc dnet driver hwac3 +audiocodec hwdts + info "DTS through SPDIF" + status working + format 0x2001 + driver hwac3 + audiocodec vorbis info "OggVorbis Audio Decoder" status working Index: libmpdemux/demuxer.c =================================================================== RCS file: /cvsroot/mplayer/main/libmpdemux/demuxer.c,v retrieving revision 1.164 diff -u -r1.164 demuxer.c --- libmpdemux/demuxer.c 16 Jul 2004 20:31:17 -0000 1.164 +++ libmpdemux/demuxer.c 26 Jul 2004 17:08:07 -0000 @@ -1308,7 +1308,8 @@ switch(d_audio->id & 0xE0){ // 1110 0000 b (high 3 bit: type low 5: id) case 0x00: sh_audio->format=0x50;break; // mpeg case 0xA0: sh_audio->format=0x10001;break; // dvd pcm - case 0x80: sh_audio->format=0x2000;break; // ac3 + case 0x80: if((d_audio->id & 0xF8) == 0x88) sh_audio->format=0x2001;//dts + else sh_audio->format=0x2000;break; // ac3 default: sh_audio=NULL; // unknown type } } @@ -1328,7 +1329,8 @@ switch(d_audio->id & 0xE0){ // 1110 0000 b (high 3 bit: type low 5: id) case 0x00: sh_audio->format=0x50;break; // mpeg case 0xA0: sh_audio->format=0x10001;break; // dvd pcm - case 0x80: sh_audio->format=0x2000;break; // ac3 + case 0x80: if((d_audio->id & 0xF8) == 0x88) sh_audio->format=0x2001;//dts + else sh_audio->format=0x2000;break; // ac3 default: sh_audio=NULL; // unknown type } }