Commit 79ec524f authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit 'ec444c84'

* commit 'ec444c84':
  mpegaudiodec: Fix buffer handling on random access
  mpegaudio: Refactor mp3on4 flush function
  fate: Add dependencies for audio tests
  fate: cosmetics: Group idct8x8 test together with all other libavcodec tests
  fate: More fine-grained dependencies for libavcodec test programs

Conflicts:
	tests/fate/audio.mak
Merged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents 35ce42e0 ec444c84
...@@ -1713,11 +1713,15 @@ static int decode_frame(AVCodecContext * avctx, void *data, int *got_frame_ptr, ...@@ -1713,11 +1713,15 @@ static int decode_frame(AVCodecContext * avctx, void *data, int *got_frame_ptr,
return buf_size; return buf_size;
} }
static void mp_flush(MPADecodeContext *ctx)
{
memset(ctx->synth_buf, 0, sizeof(ctx->synth_buf));
ctx->last_buf_size = 0;
}
static void flush(AVCodecContext *avctx) static void flush(AVCodecContext *avctx)
{ {
MPADecodeContext *s = avctx->priv_data; mp_flush(avctx->priv_data);
memset(s->synth_buf, 0, sizeof(s->synth_buf));
s->last_buf_size = 0;
} }
#if CONFIG_MP3ADU_DECODER || CONFIG_MP3ADUFLOAT_DECODER #if CONFIG_MP3ADU_DECODER || CONFIG_MP3ADUFLOAT_DECODER
...@@ -1908,11 +1912,8 @@ static void flush_mp3on4(AVCodecContext *avctx) ...@@ -1908,11 +1912,8 @@ static void flush_mp3on4(AVCodecContext *avctx)
int i; int i;
MP3On4DecodeContext *s = avctx->priv_data; MP3On4DecodeContext *s = avctx->priv_data;
for (i = 0; i < s->frames; i++) { for (i = 0; i < s->frames; i++)
MPADecodeContext *m = s->mp3decctx[i]; mp_flush(s->mp3decctx[i]);
memset(m->synth_buf, 0, sizeof(m->synth_buf));
m->last_buf_size = 0;
}
} }
......
...@@ -75,7 +75,6 @@ include $(SRC_PATH)/tests/fate/audio.mak ...@@ -75,7 +75,6 @@ include $(SRC_PATH)/tests/fate/audio.mak
include $(SRC_PATH)/tests/fate/bmp.mak include $(SRC_PATH)/tests/fate/bmp.mak
include $(SRC_PATH)/tests/fate/cdxl.mak include $(SRC_PATH)/tests/fate/cdxl.mak
include $(SRC_PATH)/tests/fate/cover-art.mak include $(SRC_PATH)/tests/fate/cover-art.mak
include $(SRC_PATH)/tests/fate/dct.mak
include $(SRC_PATH)/tests/fate/demux.mak include $(SRC_PATH)/tests/fate/demux.mak
include $(SRC_PATH)/tests/fate/dfa.mak include $(SRC_PATH)/tests/fate/dfa.mak
include $(SRC_PATH)/tests/fate/dpcm.mak include $(SRC_PATH)/tests/fate/dpcm.mak
......
FATE_BINKAUDIO += fate-binkaudio-dct FATE_BINKAUDIO-$(call DEMDEC, BINK, BINKAUDIO_DCT) += fate-binkaudio-dct
fate-binkaudio-dct: CMD = pcm -i $(SAMPLES)/bink/binkaudio_dct.bik fate-binkaudio-dct: CMD = pcm -i $(SAMPLES)/bink/binkaudio_dct.bik
fate-binkaudio-dct: REF = $(SAMPLES)/bink/binkaudio_dct.pcm fate-binkaudio-dct: REF = $(SAMPLES)/bink/binkaudio_dct.pcm
fate-binkaudio-dct: FUZZ = 2 fate-binkaudio-dct: FUZZ = 2
FATE_BINKAUDIO += fate-binkaudio-rdft FATE_BINKAUDIO-$(call DEMDEC, BINK, BINKAUDIO_RDFT) += fate-binkaudio-rdft
fate-binkaudio-rdft: CMD = pcm -i $(SAMPLES)/bink/binkaudio_rdft.bik fate-binkaudio-rdft: CMD = pcm -i $(SAMPLES)/bink/binkaudio_rdft.bik
fate-binkaudio-rdft: REF = $(SAMPLES)/bink/binkaudio_rdft.pcm fate-binkaudio-rdft: REF = $(SAMPLES)/bink/binkaudio_rdft.pcm
fate-binkaudio-rdft: FUZZ = 2 fate-binkaudio-rdft: FUZZ = 2
$(FATE_BINKAUDIO): CMP = oneoff $(FATE_BINKAUDIO-yes): CMP = oneoff
FATE_SAMPLES_AUDIO += $(FATE_BINKAUDIO) FATE_SAMPLES_AUDIO += $(FATE_BINKAUDIO-yes)
fate-binkaudio: $(FATE_BINKAUDIO) fate-binkaudio: $(FATE_BINKAUDIO-yes)
FATE_SAMPLES_AUDIO += fate-bmv-audio FATE_SAMPLES_AUDIO-$(call DEMDEC, BMV, BMV_AUDIO) += fate-bmv-audio
fate-bmv-audio: CMD = framecrc -i $(SAMPLES)/bmv/SURFING-partial.BMV -vn fate-bmv-audio: CMD = framecrc -i $(SAMPLES)/bmv/SURFING-partial.BMV -vn
FATE_SAMPLES_AUDIO += fate-delphine-cin-audio FATE_SAMPLES_AUDIO-$(call DEMDEC, DSICIN, DSICINAUDIO) += fate-delphine-cin-audio
fate-delphine-cin-audio: CMD = framecrc -i $(SAMPLES)/delphine-cin/LOGO-partial.CIN -vn fate-delphine-cin-audio: CMD = framecrc -i $(SAMPLES)/delphine-cin/LOGO-partial.CIN -vn
FATE_SAMPLES_AUDIO += fate-dts FATE_SAMPLES_AUDIO-$(call DEMDEC, MPEGTS, DCA) += fate-dts
fate-dts: CMD = pcm -i $(SAMPLES)/dts/dts.ts fate-dts: CMD = pcm -i $(SAMPLES)/dts/dts.ts
fate-dts: CMP = oneoff fate-dts: CMP = oneoff
fate-dts: REF = $(SAMPLES)/dts/dts.pcm fate-dts: REF = $(SAMPLES)/dts/dts.pcm
FATE_SAMPLES_AUDIO += fate-imc FATE_SAMPLES_AUDIO-$(call DEMDEC, AVI, IMC) += fate-imc
fate-imc: CMD = pcm -i $(SAMPLES)/imc/imc.avi fate-imc: CMD = pcm -i $(SAMPLES)/imc/imc.avi
fate-imc: CMP = oneoff fate-imc: CMP = oneoff
fate-imc: REF = $(SAMPLES)/imc/imc.pcm fate-imc: REF = $(SAMPLES)/imc/imc.pcm
FATE_SAMPLES_AUDIO += fate-nellymoser FATE_SAMPLES_AUDIO-$(call DEMDEC, FLV, NELLYMOSER) += fate-nellymoser
fate-nellymoser: CMD = pcm -i $(SAMPLES)/nellymoser/nellymoser.flv fate-nellymoser: CMD = pcm -i $(SAMPLES)/nellymoser/nellymoser.flv
fate-nellymoser: CMP = oneoff fate-nellymoser: CMP = oneoff
fate-nellymoser: REF = $(SAMPLES)/nellymoser/nellymoser.pcm fate-nellymoser: REF = $(SAMPLES)/nellymoser/nellymoser.pcm
...@@ -46,16 +46,16 @@ fate-nellymoser-aref-encode: SIZE_TOLERANCE = 268 ...@@ -46,16 +46,16 @@ fate-nellymoser-aref-encode: SIZE_TOLERANCE = 268
FATE_SAMPLES_AUDIO += fate-paf-audio FATE_SAMPLES_AUDIO += fate-paf-audio
fate-paf-audio: CMD = framecrc -i $(SAMPLES)/paf/hod1-partial.paf -vn fate-paf-audio: CMD = framecrc -i $(SAMPLES)/paf/hod1-partial.paf -vn
FATE_SAMPLES_AUDIO += fate-sierra-vmd-audio FATE_SAMPLES_AUDIO-$(call DEMDEC, VMD, VMDAUDIO) += fate-sierra-vmd-audio
fate-sierra-vmd-audio: CMD = framecrc -i $(SAMPLES)/vmd/12.vmd -vn fate-sierra-vmd-audio: CMD = framecrc -i $(SAMPLES)/vmd/12.vmd -vn
FATE_SAMPLES_AUDIO += fate-smacker-audio FATE_SAMPLES_AUDIO-$(call DEMDEC, SMACKER, SMACKAUD) += fate-smacker-audio
fate-smacker-audio: CMD = framecrc -i $(SAMPLES)/smacker/wetlogo.smk -vn fate-smacker-audio: CMD = framecrc -i $(SAMPLES)/smacker/wetlogo.smk -vn
FATE_SAMPLES_AUDIO += fate-vima FATE_SAMPLES_AUDIO += fate-vima
fate-vima: CMD = framecrc -i $(SAMPLES)/smush/ronin_part.znm -vn fate-vima: CMD = framecrc -i $(SAMPLES)/smush/ronin_part.znm -vn
FATE_SAMPLES_AUDIO += fate-ws_snd FATE_SAMPLES_AUDIO-$(call DEMDEC, WSVQA, WS_SND1) += fate-ws_snd
fate-ws_snd: CMD = md5 -i $(SAMPLES)/vqa/ws_snd.vqa -f s16le fate-ws_snd: CMD = md5 -i $(SAMPLES)/vqa/ws_snd.vqa -f s16le
FATE_SAMPLES_FFMPEG += $(FATE_SAMPLES_AUDIO) FATE_SAMPLES_FFMPEG += $(FATE_SAMPLES_AUDIO)
......
FATE-yes += fate-idct8x8
fate-idct8x8: libavcodec/dct-test$(EXESUF)
fate-idct8x8: CMD = run libavcodec/dct-test -i
fate-idct8x8: REF = /dev/null
fate-idct8x8: CMP = null
FATE_LIBAVCODEC += fate-golomb FATE_LIBAVCODEC-$(CONFIG_GOLOMB) += fate-golomb
fate-golomb: libavcodec/golomb-test$(EXESUF) fate-golomb: libavcodec/golomb-test$(EXESUF)
fate-golomb: CMD = run libavcodec/golomb-test fate-golomb: CMD = run libavcodec/golomb-test
fate-golomb: REF = /dev/null fate-golomb: REF = /dev/null
FATE_LIBAVCODEC += fate-iirfilter FATE_LIBAVCODEC-yes += fate-idct8x8
fate-idct8x8: libavcodec/dct-test$(EXESUF)
fate-idct8x8: CMD = run libavcodec/dct-test -i
fate-idct8x8: CMP = null
fate-idct8x8: REF = /dev/null
FATE_LIBAVCODEC-yes += fate-iirfilter
fate-iirfilter: libavcodec/iirfilter-test$(EXESUF) fate-iirfilter: libavcodec/iirfilter-test$(EXESUF)
fate-iirfilter: CMD = run libavcodec/iirfilter-test fate-iirfilter: CMD = run libavcodec/iirfilter-test
FATE_LIBAVCODEC += fate-rangecoder FATE_LIBAVCODEC-$(CONFIG_RANGECODER) += fate-rangecoder
fate-rangecoder: libavcodec/rangecoder-test$(EXESUF) fate-rangecoder: libavcodec/rangecoder-test$(EXESUF)
fate-rangecoder: CMD = run libavcodec/rangecoder-test fate-rangecoder: CMD = run libavcodec/rangecoder-test
fate-rangecoder: CMP = null fate-rangecoder: CMP = null
fate-rangecoder: REF = /dev/null fate-rangecoder: REF = /dev/null
FATE-$(CONFIG_AVCODEC) += $(FATE_LIBAVCODEC) FATE-$(CONFIG_AVCODEC) += $(FATE_LIBAVCODEC-yes)
fate-libavcodec: $(FATE_LIBAVCODEC) fate-libavcodec: $(FATE_LIBAVCODEC-yes)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment