# HG changeset patch # User rtognimp # Date 1110131731 0 # Node ID ed06939c521720ef16048eb5c4ce72de1071d4f4 # Parent 1f82d63df1cd6f5379ff896c9b966577707b938b alac support via lavc decoder diff -r 1f82d63df1cd -r ed06939c5217 etc/codecs.conf --- a/etc/codecs.conf Sun Mar 06 17:31:55 2005 +0000 +++ b/etc/codecs.conf Sun Mar 06 17:55:31 2005 +0000 @@ -2166,6 +2166,13 @@ driver ffmpeg dll "flac" +audiocodec ffalac + info "FFmpeg ALAC audio decoder" + status working + fourcc alac + driver ffmpeg + dll "alac" + audiocodec pcm info "Uncompressed PCM" status working diff -r 1f82d63df1cd -r ed06939c5217 libmpcodecs/ad_ffmpeg.c --- a/libmpcodecs/ad_ffmpeg.c Sun Mar 06 17:31:55 2005 +0000 +++ b/libmpcodecs/ad_ffmpeg.c Sun Mar 06 17:55:31 2005 +0000 @@ -66,6 +66,7 @@ lavc_context->sample_rate = sh_audio->wf->nSamplesPerSec; lavc_context->bit_rate = sh_audio->wf->nAvgBytesPerSec * 8; lavc_context->block_align = sh_audio->wf->nBlockAlign; + lavc_context->bits_per_sample = sh_audio->wf->wBitsPerSample; } lavc_context->codec_tag = sh_audio->format; //FOURCC lavc_context->codec_id = lavc_codec->id; // not sure if required, imho not --A'rpi diff -r 1f82d63df1cd -r ed06939c5217 libmpdemux/demux_mov.c --- a/libmpdemux/demux_mov.c Sun Mar 06 17:31:55 2005 +0000 +++ b/libmpdemux/demux_mov.c Sun Mar 06 17:55:31 2005 +0000 @@ -988,6 +988,15 @@ #endif } } break; + case MOV_FOURCC('a','l','a','c'): { + mp_msg(MSGT_DEMUX, MSGL_INFO, "MOV: Found alac atom (%d)!\n", atom_len); + if(atom_len > 8) { + // copy all the atom (not only payload) for lavc alac decoder + sh->codecdata_len = atom_len; + sh->codecdata = (unsigned char *)malloc(sh->codecdata_len); + memcpy(sh->codecdata, &trak->stdata[28], sh->codecdata_len); + } + } break; default: mp_msg(MSGT_DEMUX, MSGL_INFO, "MOV: Found unknown audio atom %c%c%c%c (%d)!\n", trak->stdata[32+adjust],trak->stdata[33+adjust],trak->stdata[34+adjust],trak->stdata[35+adjust],