Permalink
Browse files

Merge remote-tracking branch 'qatar/master'

* qatar/master: (29 commits)
  lavfi: reclassify showfiltfmts as a TESTPROG
  graph2dot: fix printf format specifier
  swscale: yuv2planeX 8bit >=sse2 functions need aligned stack on x86-32.
  vp8: loopfilter >=sse2 functions need aligned stack on x86-32.
  amr: remove shift out of the AMR_BIT() macro.
  dsputilenc: group yasm and inline asm function pointer assignment.
  mov: use forward declaration of a function instead of a table.
  Clarify Doxygen comment for FF_API_* #defines.
  configure: simplify get_version()
  Create version.h headers for libraries that lack them
  gitignore: Use full path instead of relative path to specify patterns
  mpegvideo: remove VLAs
  Add XTEA encryption support in libavutil
  Add Blowfish encryption support in libavutil
  eval: Add the isinf() function and tests for it
  flacdec: move lpc filter to flacdsp
  flacdec: split off channel decorrelation as flacdsp
  avplay: Add an option for not limiting the input buffer size
  FATE: add a test for WMA cover art.
  FATE: add a test for apetag cover art
  ...

Conflicts:
	.gitignore
	configure
	ffplay.c
	libavcodec/Makefile
	libavcodec/error_resilience.c
	libavcodec/mpegvideo.c
	libavcodec/ratecontrol.c
	libavdevice/avdevice.h
	libavfilter/Makefile
	libavfilter/filtfmts.c
	libavfilter/version.h
	libavformat/mov.c
	libavformat/version.h
	libavutil/Makefile
	libavutil/avutil.h
	libavutil/version.h
	libswscale/swscale.h
	libswscale/x86/swscale_mmx.c
	tests/fate/libavutil.mak
	tests/lavfi-regression.sh
	tools/graph2dot.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
  • Loading branch information...
2 parents 8b421fa + 7c29377 commit 039e9fe01ca27606a0ec1a944d51041541e10aab @michaelni michaelni committed Jul 4, 2012
Showing with 1,635 additions and 389 deletions.
  1. +42 −48 .gitignore
  2. +20 −9 configure
  3. +2 −0 doc/eval.texi
  4. +5 −2 ffplay.c
  5. +1 −1 libavcodec/Makefile
  6. +1 −1 libavcodec/amr.h
  7. +1 −1 libavcodec/amrnbdata.h
  8. +1 −1 libavcodec/amrwbdata.h
  9. +3 −5 libavcodec/error_resilience.c
  10. +2 −1 libavcodec/flac.c
  11. +4 −4 libavcodec/flac.h
  12. +45 −105 libavcodec/flacdec.c
  13. +94 −0 libavcodec/flacdsp.c
  14. +34 −0 libavcodec/flacdsp.h
  15. +86 −0 libavcodec/flacdsp_template.c
  16. +14 −11 libavcodec/flacenc.c
  17. +12 −1 libavcodec/mpegvideo.c
  18. +6 −0 libavcodec/mpegvideo.h
  19. +2 −5 libavcodec/ratecontrol.c
  20. +4 −2 libavcodec/version.h
  21. +1 −1 libavcodec/x86/dsputilenc_mmx.c
  22. +6 −0 libavcodec/x86/vp8dsp-init.c
  23. +2 −1 libavdevice/Makefile
  24. +2 −13 libavdevice/avdevice.h
  25. +48 −0 libavdevice/version.h
  26. +2 −4 libavfilter/Makefile
  27. +5 −0 tools/lavfi-showfiltfmts.c → libavfilter/filtfmts.c
  28. +4 −2 libavfilter/version.h
  29. +82 −82 libavformat/mov.c
  30. +4 −2 libavformat/version.h
  31. +3 −2 libavresample/version.h
  32. +6 −1 libavutil/Makefile
  33. +1 −31 libavutil/avutil.h
  34. +566 −0 libavutil/blowfish.c
  35. +76 −0 libavutil/blowfish.h
  36. +4 −5 libavutil/cpu.h
  37. +8 −1 libavutil/eval.c
  38. +37 −1 libavutil/version.h
  39. +165 −0 libavutil/xtea.c
  40. +61 −0 libavutil/xtea.h
  41. +2 −1 libswscale/Makefile
  42. +1 −28 libswscale/swscale.h
  43. +59 −0 libswscale/version.h
  44. +9 −6 libswscale/x86/swscale_mmx.c
  45. +3 −1 tests/Makefile
  46. +19 −0 tests/fate/cover-art.mak
  47. +19 −0 tests/fate/flac.mak
  48. +8 −0 tests/fate/libavutil.mak
  49. +1 −1 tests/lavfi-regression.sh
  50. +1 −0 tests/ref/fate/blowfish
  51. +12 −0 tests/ref/fate/eval
  52. +1 −0 tests/ref/fate/xtea
  53. +1 −1 tools/graph2dot.c
  54. +37 −8 tools/ismindex.c
View
@@ -1,5 +1,3 @@
-.config
-.version
*.a
*.o
*.d
@@ -15,49 +13,45 @@
*-example
*-test
*_g
-*.def
-*.dll
-*.lib
-*.exp
-config.*
-doc/*.1
-doc/*.html
-doc/*.pod
-doc/fate.txt
-doxy
-ffmpeg
-ffplay
-ffprobe
-ffserver
-avconv
-doc/avoptions_codec.texi
-doc/avoptions_format.texi
-doc/print_options
-doc/examples/decoding_encoding
-doc/examples/filtering_audio
-doc/examples/filtering_video
-doc/examples/metadata
-doc/examples/muxing
-libavcodec/*_tablegen
-libavcodec/*_tables.c
-libavcodec/*_tables.h
-libavcodec/codec_names.h
-libavutil/avconfig.h
-tests/audiogen
-tests/base64
-tests/data
-tests/rotozoom
-tests/tiny_psnr
-tests/videogen
-tests/vsynth1
-tools/aviocat
-tools/cws2fws
-tools/ffeval
-tools/graph2dot
-tools/ismindex
-tools/lavfi-showfiltfmts
-tools/pktdumper
-tools/probetest
-tools/qt-faststart
-tools/trasher
-version.h
+/.config
+/.version
+/ffmpeg
+/ffplay
+/ffprobe
+/ffserver
+/config.*
+/version.h
+/doc/*.1
+/doc/*.html
+/doc/*.pod
+/doc/avoptions_codec.texi
+/doc/avoptions_format.texi
+/doc/examples/decoding_encoding
+/doc/examples/filtering_audio
+/doc/examples/filtering_video
+/doc/examples/metadata
+/doc/examples/muxing
+/doc/fate.txt
+/doc/print_options
+/doxy/
+/libavcodec/*_tablegen
+/libavcodec/*_tables.c
+/libavcodec/*_tables.h
+/libavcodec/codec_names.h
+/libavutil/avconfig.h
+/tests/audiogen
+/tests/base64
+/tests/data/
+/tests/rotozoom
+/tests/tiny_psnr
+/tests/videogen
+/tests/vsynth1/
+/tools/aviocat
+/tools/cws2fws
+/tools/ffeval
+/tools/graph2dot
+/tools/ismindex
+/tools/pktdumper
+/tools/probetest
+/tools/qt-faststart
+/tools/trasher
View
@@ -3812,6 +3812,16 @@ NOREDZONE_FLAGS=$noredzone_flags
EOF
get_version(){
+ lcname=$1
+ name=$(toupper $lcname)
+ file=$source_path/$lcname/version.h
+ eval $(grep "#define ${name}_VERSION_M" "$file" | awk '{ print $2"="$3 }')
+ eval ${name}_VERSION=\$${name}_VERSION_MAJOR.\$${name}_VERSION_MINOR.\$${name}_VERSION_MICRO
+ eval echo "${lcname}_VERSION=\$${name}_VERSION" >> config.mak
+ eval echo "${lcname}_VERSION_MAJOR=\$${name}_VERSION_MAJOR" >> config.mak
+}
+
+get_version_old(){
name=$1
file=$source_path/$2
# This condition will be removed when we stop supporting old libpostproc versions
@@ -3824,15 +3834,16 @@ fi
eval echo "${lcname}_VERSION_MAJOR=\$${name}_VERSION_MAJOR" >> config.mak
}
-get_version LIBAVCODEC libavcodec/version.h
-get_version LIBAVDEVICE libavdevice/avdevice.h
-get_version LIBAVFILTER libavfilter/version.h
-get_version LIBAVFORMAT libavformat/version.h
-get_version LIBAVRESAMPLE libavresample/version.h
-get_version LIBAVUTIL libavutil/version.h
-get_version LIBPOSTPROC libpostproc/postprocess.h
-get_version LIBSWRESAMPLE libswresample/swresample.h
-get_version LIBSWSCALE libswscale/swscale.h
+get_version_old LIBPOSTPROC libpostproc/postprocess.h
+get_version_old LIBSWRESAMPLE libswresample/swresample.h
+
+get_version libavcodec
+get_version libavdevice
+get_version libavfilter
+get_version libavformat
+get_version libavresample
+get_version libavutil
+get_version libswscale
cat > $TMPH <<EOF
/* Automatically generated by configure - do not modify! */
View
@@ -34,6 +34,8 @@ The following functions are available:
@item abs(x)
@item squish(x)
@item gauss(x)
+@item isinf(x)
+Return 1.0 if @var{x} is +/-INFINITY, 0.0 otherwise.
@item isnan(x)
Return 1.0 if @var{x} is NAN, 0.0 otherwise.
View
@@ -281,6 +281,7 @@ static int exit_on_keydown;
static int exit_on_mousedown;
static int loop = 1;
static int framedrop = -1;
+static int infinite_buffer = 0;
static enum ShowMode show_mode = SHOW_MODE_NONE;
static const char *audio_codec_name;
static const char *subtitle_codec_name;
@@ -2504,10 +2505,11 @@ static int read_thread(void *arg)
}
/* if the queue are full, no need to read more */
- if ( is->audioq.size + is->videoq.size + is->subtitleq.size > MAX_QUEUE_SIZE
+ if (!infinite_buffer &&
+ (is->audioq.size + is->videoq.size + is->subtitleq.size > MAX_QUEUE_SIZE
|| ( (is->audioq .nb_packets > MIN_FRAMES || is->audio_stream < 0 || is->audioq.abort_request)
&& (is->videoq .nb_packets > MIN_FRAMES || is->video_stream < 0 || is->videoq.abort_request)
- && (is->subtitleq.nb_packets > MIN_FRAMES || is->subtitle_stream < 0 || is->subtitleq.abort_request))) {
+ && (is->subtitleq.nb_packets > MIN_FRAMES || is->subtitle_stream < 0 || is->subtitleq.abort_request)))) {
/* wait 10 ms */
SDL_Delay(10);
continue;
@@ -2994,6 +2996,7 @@ static const OptionDef options[] = {
{ "exitonmousedown", OPT_BOOL | OPT_EXPERT, { (void*)&exit_on_mousedown }, "exit on mouse down", "" },
{ "loop", OPT_INT | HAS_ARG | OPT_EXPERT, { (void*)&loop }, "set number of times the playback shall be looped", "loop count" },
{ "framedrop", OPT_BOOL | OPT_EXPERT, { (void*)&framedrop }, "drop frames when cpu is too slow", "" },
+ { "infbuf", OPT_BOOL | OPT_EXPERT, { (void*)&infinite_buffer }, "don't limit the input buffer size (useful with realtime streams)", "" },
{ "window_title", OPT_STRING | HAS_ARG, { (void*)&window_title }, "set window title", "window title" },
#if CONFIG_AVFILTER
{ "vf", OPT_STRING | HAS_ARG, { (void*)&vfilters }, "video filters", "filter list" },
View
@@ -179,7 +179,7 @@ OBJS-$(CONFIG_FFV1_ENCODER) += ffv1.o rangecoder.o
OBJS-$(CONFIG_FFVHUFF_DECODER) += huffyuv.o
OBJS-$(CONFIG_FFVHUFF_ENCODER) += huffyuv.o
OBJS-$(CONFIG_FFWAVESYNTH_DECODER) += ffwavesynth.o
-OBJS-$(CONFIG_FLAC_DECODER) += flacdec.o flacdata.o flac.o
+OBJS-$(CONFIG_FLAC_DECODER) += flacdec.o flacdata.o flac.o flacdsp.o
OBJS-$(CONFIG_FLAC_ENCODER) += flacenc.o flacdata.o flac.o vorbis_data.o
OBJS-$(CONFIG_FLASHSV_DECODER) += flashsv.o
OBJS-$(CONFIG_FLASHSV_ENCODER) += flashsvenc.o
View
@@ -61,7 +61,7 @@ static inline void ff_amr_bit_reorder(uint16_t *out, int size,
field <<= 1;
field |= data[bit >> 3] >> (bit & 7) & 1;
}
- out[field_offset] = field;
+ out[field_offset >> 1] = field;
}
}
View
@@ -71,7 +71,7 @@ typedef struct {
} AMRNBFrame;
/** The index of a frame parameter */
-#define AMR_BIT(field) (offsetof(AMRNBFrame, field) >> 1)
+#define AMR_BIT(field) (offsetof(AMRNBFrame, field))
/** The index of a subframe-specific parameter */
#define AMR_OF(frame_num, variable) AMR_BIT(subframe[frame_num].variable)
View
@@ -82,7 +82,7 @@ typedef struct {
} AMRWBFrame;
/** The index of a frame parameter */
-#define AMR_BIT(field) (offsetof(AMRWBFrame, field) >> 1)
+#define AMR_BIT(field) (offsetof(AMRWBFrame, field))
/** The index of a subframe-specific parameter */
#define AMR_OF(frame_num, variable) AMR_BIT(subframe[frame_num].variable)
@@ -408,7 +408,7 @@ static void v_block_filter(MpegEncContext *s, uint8_t *dst, int w, int h,
static void guess_mv(MpegEncContext *s)
{
- uint8_t *fixed = av_malloc(s->mb_stride * s->mb_height);
+ uint8_t *fixed = s->er_temp_buffer;
#define MV_FROZEN 3
#define MV_CHANGED 2
#define MV_UNCHANGED 1
@@ -470,7 +470,7 @@ static void guess_mv(MpegEncContext *s)
decode_mb(s, 0);
}
}
- goto end;
+ return;
}
for (depth = 0; ; depth++) {
@@ -722,7 +722,7 @@ static void guess_mv(MpegEncContext *s)
}
if (none_left)
- goto end;
+ return;
for (i = 0; i < s->mb_num; i++) {
int mb_xy = s->mb_index2xy[i];
@@ -731,8 +731,6 @@ static void guess_mv(MpegEncContext *s)
}
// printf(":"); fflush(stdout);
}
-end:
- av_free(fixed);
}
static int is_intra_more_likely(MpegEncContext *s)
View
@@ -55,8 +55,9 @@ int ff_flac_decode_frame_header(AVCodecContext *avctx, GetBitContext *gb,
if (fi->ch_mode < FLAC_MAX_CHANNELS) {
fi->channels = fi->ch_mode + 1;
fi->ch_mode = FLAC_CHMODE_INDEPENDENT;
- } else if (fi->ch_mode <= FLAC_CHMODE_MID_SIDE) {
+ } else if (fi->ch_mode < FLAC_MAX_CHANNELS + FLAC_CHMODE_MID_SIDE) {
fi->channels = 2;
+ fi->ch_mode -= FLAC_MAX_CHANNELS - 1;
} else {
av_log(avctx, AV_LOG_ERROR + log_level_offset,
"invalid channel mode: %d\n", fi->ch_mode);
View
@@ -37,10 +37,10 @@
#define FLAC_MIN_FRAME_SIZE 11
enum {
- FLAC_CHMODE_INDEPENDENT = 0,
- FLAC_CHMODE_LEFT_SIDE = 8,
- FLAC_CHMODE_RIGHT_SIDE = 9,
- FLAC_CHMODE_MID_SIDE = 10,
+ FLAC_CHMODE_INDEPENDENT = 0,
+ FLAC_CHMODE_LEFT_SIDE = 1,
+ FLAC_CHMODE_RIGHT_SIDE = 2,
+ FLAC_CHMODE_MID_SIDE = 3,
};
enum {
Oops, something went wrong.

0 comments on commit 039e9fe

Please sign in to comment.