Commit Graph

1594 Commits

Author SHA1 Message Date
Clément Bœsch
95317821ea audioconvert: consistent use of FF_ARRAY_ELEMS for channel_layout_map. 2012-02-15 10:26:25 +01:00
Michael Niedermayer
04b53746ad Merge remote-tracking branch 'qatar/master'
* qatar/master:
  rtpdec: Use 4 byte startcodes for H.264
  matroskadec: Mark variable as av_unused.
  Move some conditionally used variables into the block where they are used.
  Drop some completely unnecessary av_unused attributes.
  swscale: Remove unused variable alpMmxFilter.
  Drop unnecessary av_uninit attributes from some variable declarations.
  movenc: Support muxing wmapro in ismv/isma
  mpegtsenc: Add an AVOption for forcing a new PAT/PMT/SDT to be written
  swscale: move YUV2PACKED16WRAPPER() macro down to where it is used.
  swscale: handle gray16 as a "planar" YUV format (Y-only, of course).
  swscale: use yuv2packed1() functions for unscaled chroma also.
  swscale: fix incorrect chroma bias in yuv2rgb48_1_c().
  swscale: fix invalid memory accesses in yuvpacked1() functions.
  Move PS2 MMI code below the mips subdirectory, where it belongs.
  mips: Move MMI function declarations to a header.
  build: Set correct dependencies for rtmp* protocols implemented by librtmp.

Conflicts:
	libavcodec/ac3enc_template.c
	libavformat/mpegtsenc.c
	libswscale/output.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-02-14 01:53:31 +01:00
Diego Biurrun
6df5c528ca Move some conditionally used variables into the block where they are used.
This allows dropping the av_unused argument from them.
2012-02-13 19:20:54 +01:00
Reimar Döffinger
b223035511 Detect and check for CMOV.
Some MMX-only CPUs do not have support for CMOV.
All SSE/MMX2 CPUs should be fine, thus no check was
added to those functions.
See also https://sourceforge.net/tracker/?func=detail&aid=3358347&group_id=205275&atid=992986

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-02-12 18:56:06 +01:00
Michael Niedermayer
8c6ebab747 Merge remote-tracking branch 'qatar/master'
* qatar/master: (26 commits)
  eac3dec: replace undefined 1<<31 with INT32_MIN in noise generation
  yadif: specify array size outside DECLARE_ALIGNED
  prores: specify array size outside DECLARE_ALIGNED brackets.
  WavPack demuxer: set packet duration
  tta: use skip_bits_long()
  mxfdec: Ignore the last entry in Avid's index table segments
  mxfdec: Sanity-check SampleRate
  mxfdec: Handle small EditUnitByteCount
  mxfdec: Consider OPAtom files that do not have exactly one EC to be OP1a
  mxfdec: Don't crash in mxf_packet_timestamps() if current_edit_unit overflows
  mxfdec: Zero nb_ptses in mxf_compute_ptses_fake_index()
  mxfdec: Sanity check PreviousPartition
  mxfdec: Never seek back in local sets and KLVs
  mxfdec: Move the current_partition check inside mxf_read_header()
  mxfdec: Fix infinite loop in mxf_packet_timestamps()
  mxfdec: Check eof_reached in mxf_read_local_tags()
  mxfdec: Check for NULL component
  mxfdec: Make sure mxf->nb_index_tables > 0 in mxf_packet_timestamps()
  mxfdec: Make sure x < index_table->nb_ptses
  build: Add missing directories to DIRS declarations.
  ...

Conflicts:
	doc/build_system.txt
	doc/fate.texi
	libavfilter/x86/yadif_template.c
	libavformat/mxfdec.c
	libavutil/Makefile
	tests/fate/audio.mak
	tests/fate/prores.mak
	tests/fate/screen.mak
	tests/fate/video.mak
	tests/ref/fate/bethsoft-vid
	tests/ref/fate/cscd
	tests/ref/fate/dfa4
	tests/ref/fate/nuv
	tests/ref/fate/vp8-sign-bias
	tests/ref/fate/wmv8-drm
	tests/ref/lavf/gxf

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-02-10 01:20:07 +01:00
Stefano Sabatini
c28e7af70d lavu: add timestamp.h header with convenience timestamp utilities 2012-02-09 18:37:58 +01:00
Diego Biurrun
f769cfedd8 build: Add missing directories to DIRS declarations. 2012-02-09 12:26:48 +01:00
Michael Niedermayer
f2b20b7a8b Merge remote-tracking branch 'qatar/master'
* qatar/master:
  pixdesc: mark pseudopaletted formats with a special flag.
  avconv: switch to avcodec_encode_video2().
  libx264: implement encode2().
  libx264: split extradata writing out of encode_nals().
  lavc: add avcodec_encode_video2() that encodes from an AVFrame -> AVPacket
  cmdutils: update copyright year to 2012.
  swscale: sign-extend integer function argument to qword on x86-64.
  x86inc: support yasm -f win64 flag also.
  h264: manually save/restore XMM registers for functions using INIT_MMX.
  x86inc: allow manual use of WIN64_SPILL_XMM.
  aacdec: Use correct speaker order for 7.1.
  aacdec: Remove incorrect comment.
  aacdec: Simplify output configuration.
  Remove Sun medialib glue code.
  dsputil: set STRIDE_ALIGN to 16 for x86 also.
  pngdsp: swap argument inversion.

Conflicts:
	cmdutils.c
	configure
	doc/APIchanges
	ffmpeg.c
	libavcodec/aacdec.c
	libavcodec/dsputil.h
	libavcodec/libx264.c
	libavcodec/mlib/dsputil_mlib.c
	libavcodec/utils.c
	libavfilter/vf_scale.c
	libavutil/avutil.h
	libswscale/mlib/yuv2rgb_mlib.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-02-09 01:27:12 +01:00
Anton Khirnov
38d5533228 pixdesc: mark pseudopaletted formats with a special flag.
This makes it possible to dintinguish them from PAL8.

Fixes an invalid write in avpicture_layout().
2012-02-08 21:01:31 +01:00
Haruhiko Yamagata
166f399377 x86inc: support yasm -f win64 flag also.
This sets __OUTPUT_FORMAT__ to win64 instead of win32, even though both
(through -m amd64) produce 64-bit binary code.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2012-02-08 10:31:14 -08:00
Henrik Gramner
9cf7385309 x86inc: allow manual use of WIN64_SPILL_XMM.
Functions using INIT_MMX may still access XMM registers through direct
means (xmm0-15). Therefore, they still need to be marked for clobber
so they can be properly saved/restored.

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2012-02-08 10:31:14 -08:00
Alex Converse
314af0ff94 aacdec: Use correct speaker order for 7.1.
The spec says the following speaker mapping is default:
center front speaker
left, right center front speakers,
left, right outside front speakers,
left surround, right surround rear speakers,
front low frequency effects speaker
2012-02-08 09:56:37 -08:00
Stefano Sabatini
70ffda3217 lavu: introduce av_parse_ratio() and use it in ffmpeg and lavfi/aspect
Factorize code and provide ratio parsing consistency.
2012-02-06 11:30:54 +01:00
Michael Niedermayer
d3f912c1f0 adler32: add comment for the SIMD code
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-02-04 20:27:02 +01:00
Michael Niedermayer
26585d2a7f adler32: rewrite using integer SIMD.
about twice as fast as before.
the not CONFIG_SMALL case is also droped as it is not faster than the
CONFIG_SMALL case.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-02-04 20:23:04 +01:00
Michael Niedermayer
7f8027b76f adler32: avoid "too big" check in the inner loop
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-02-04 05:39:01 +01:00
Michael Niedermayer
d77294c5e4 Merge remote-tracking branch 'qatar/master'
* qatar/master:
  libx264: fix indentation.
  vorbis: fix overflows in floor1[] vector and inverse db table index.
  win64: add a XMM clobber test configure option.
  movdec: Parse the dvc1 atom
  ARM: ac3: fix ac3_bit_alloc_calc_bap_armv6
  swscale: K&R formatting cosmetics for Blackfin code
  frwu: lowercase the FRWU codec name
  movdec: fix dts generation in fragmented files
  fate: make acodec-ac3_fixed test output raw AC3
  APIchanges: add missing commit hashes
  swscale: implement MMX, SSE2 and AVX functions for RGB32 input.
  ra144enc: drop pointless "encoder" from .long_name
  bethsoftvideo: fix palette reading.
  mpc7: use av_fast_padded_malloc()
  mpc7: simplify handling of packet sizes that are not a multiple of 4 bytes
  doc: decoding Forward Uncompressed is supported
  Fix a typo in the x86 asm version of ff_vector_clip_int32()
  pcmenc: Do not set avpkt->size.
  ff_alloc_packet: modify the size of the packet to match the requested size

Conflicts:
	doc/APIchanges
	libavcodec/libx264.c
	libavcodec/mpc7.c
	libavformat/isom.h
	libswscale/Makefile
	libswscale/bfin/yuv2rgb_bfin.c
	tests/ref/fate/bethsoft-vid
	tests/ref/seek/ac3_ac3

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-02-03 03:51:32 +01:00
Clément Bœsch
9477fa094b lavu/timecode: use @see for URL in doxygen. 2012-02-03 00:56:27 +01:00
Ronald S. Bultje
7e4d9d5d45 win64: add a XMM clobber test configure option.
This will be useful to test more aggressively for failures to mark XMM
registers as clobbered in Win64 builds, and prevent regressions thereof.

Based on a patch by Ramiro Polla <ramiro.polla@gmail.com>
2012-02-02 12:00:48 -08:00
Clément Bœsch
0eaa123b34 lavu: add public timecode API. 2012-02-02 14:30:28 +01:00
Michael Niedermayer
151ecc2aec Merge remote-tracking branch 'qatar/master'
* qatar/master: (26 commits)
  avconv: deprecate the -deinterlace option
  doc: Fix the name of the new function
  aacenc: make sure to encode enough frames to cover all input samples.
  aacenc: only use the number of input samples provided by the user.
  wmadec: Verify bitstream size makes sense before calling init_get_bits.
  kmvc: Log into a context at a log level constant.
  mpeg12: Pad framerate tab to 16 entries.
  kgv1dec: Increase offsets array size so it is large enough.
  kmvc: Check palsize.
  nsvdec: Propagate errors
  nsvdec: Be more careful with av_malloc().
  nsvdec: Fix use of uninitialized streams.
  movenc: cosmetics: Get rid of camelCase identifiers
  swscale: more generic check for planar destination formats with alpha
  doc: Document mov/mp4 fragmentation options
  build: Use order-only prerequisites for creating FATE reference file dirs.
  x86 dsputil: provide SSE2/SSSE3 versions of bswap_buf
  rtsp: Remove some unused variables from ff_rtsp_connect().
  avutil: make intfloat api public
  avformat_write_header(): detail error message
  ...

Conflicts:
	doc/APIchanges
	doc/ffmpeg.texi
	doc/muxers.texi
	ffmpeg.c
	libavcodec/kmvc.c
	libavcodec/x86/Makefile
	libavcodec/x86/dsputil_yasm.asm
	libavcodec/x86/pngdsp-init.c
	libavformat/movenc.c
	libavformat/movenc.h
	libavformat/mpegtsenc.c
	libavformat/nsvdec.c
	libavformat/utils.c
	libavutil/avutil.h
	libswscale/swscale.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-31 02:46:26 +01:00
Paul B Mahol
8b933129b9 avutil: make intfloat api public
The functions are already av_ prefixed and intfloat header is already provided.
Install libavutil/intfloat.h

Signed-off-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2012-01-30 07:41:31 +01:00
Michael Niedermayer
c065255bba Merge remote-tracking branch 'qatar/master'
* qatar/master:
  aacenc: Fix LONG_START windowing.
  aacenc: Fix a bug where deinterleaved samples were stored in the wrong place.
  avplay: use the correct array size for stride.
  lavc: extend doxy for avcodec_alloc_context3().
  APIchanges: mention avcodec_alloc_context()/2/3
  avcodec_align_dimensions2: set only 4 linesizes, not AV_NUM_DATA_POINTERS.
  aacsbr: ARM NEON optimised sbrdsp functions
  aacsbr: align some arrays
  aacsbr: move some simdable loops to function pointers
  cosmetics: Remove extra newlines at EOF

Conflicts:
	libavcodec/utils.c
	libavfilter/formats.c
	libavutil/mem.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-29 00:34:59 +01:00
Michael Niedermayer
e37f161e66 Merge remote-tracking branch 'qatar/master'
* qatar/master: (71 commits)
  movenc: Allow writing to a non-seekable output if using empty moov
  movenc: Support adding isml (smooth streaming live) metadata
  libavcodec: Don't crash in avcodec_encode_audio if time_base isn't set
  sunrast: Document the different Sun Raster file format types.
  sunrast: Add a check for experimental type.
  libspeexenc: use AVSampleFormat instead of deprecated/removed SampleFormat
  lavf: remove disabled FF_API_SET_PTS_INFO cruft
  lavf: remove disabled FF_API_OLD_INTERRUPT_CB cruft
  lavf: remove disabled FF_API_REORDER_PRIVATE cruft
  lavf: remove disabled FF_API_SEEK_PUBLIC cruft
  lavf: remove disabled FF_API_STREAM_COPY cruft
  lavf: remove disabled FF_API_PRELOAD cruft
  lavf: remove disabled FF_API_NEW_STREAM cruft
  lavf: remove disabled FF_API_RTSP_URL_OPTIONS cruft
  lavf: remove disabled FF_API_MUXRATE cruft
  lavf: remove disabled FF_API_FILESIZE cruft
  lavf: remove disabled FF_API_TIMESTAMP cruft
  lavf: remove disabled FF_API_LOOP_OUTPUT cruft
  lavf: remove disabled FF_API_LOOP_INPUT cruft
  lavf: remove disabled FF_API_AVSTREAM_QUALITY cruft
  ...

Conflicts:
	doc/APIchanges
	libavcodec/8bps.c
	libavcodec/avcodec.h
	libavcodec/libx264.c
	libavcodec/mjpegbdec.c
	libavcodec/options.c
	libavcodec/sunrast.c
	libavcodec/utils.c
	libavcodec/version.h
	libavcodec/x86/h264_deblock.asm
	libavdevice/libdc1394.c
	libavdevice/v4l2.c
	libavformat/avformat.h
	libavformat/avio.c
	libavformat/avio.h
	libavformat/aviobuf.c
	libavformat/dv.c
	libavformat/mov.c
	libavformat/utils.c
	libavformat/version.h
	libavformat/wtv.c
	libavutil/Makefile
	libavutil/file.c
	libswscale/x86/input.asm
	libswscale/x86/swscale_mmx.c
	libswscale/x86/swscale_template.c
	tests/ref/lavf/ffm

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-28 07:53:34 +01:00
Alex Converse
7181c4edee cosmetics: Remove extra newlines at EOF 2012-01-27 17:19:09 -08:00
Paul B Mahol
f9ca1ac796 sws/pixfmt/pixdesc: add support for yuva444p
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>

Conflicts:

	libavutil/avutil.h
	libavutil/pixfmt.h
2012-01-28 01:30:41 +01:00
Ronald S. Bultje
412b248edb x86inc.asm: fix typo.
Assemblers don't understand ! in %if statements.
2012-01-27 16:33:03 +08:00
Ronald S. Bultje
3b15a6d742 config.asm: change %ifdef directives to %if directives.
This allows combining multiple conditionals in a single statement.
2012-01-27 10:19:57 +08:00
Alex Converse
08628b6afb Revert "sws/pixfmt/pixdesc: add support for yuva444p"
This reverts commit fc115c80b7.

Tests are broken.
2012-01-26 18:06:57 -08:00
Paul B Mahol
fc115c80b7 sws/pixfmt/pixdesc: add support for yuva444p
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
2012-01-27 09:24:08 +08:00
Diego Biurrun
299ab0fd17 libavutil: Remove pointless file test program. 2012-01-26 22:44:37 +01:00
Michael Niedermayer
2bb7396bfd base64: 10l endian fix.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-22 23:06:04 +01:00
Reimar Döffinger
daa47fdd2c Optimized base64 decode by writing 3 bytes at once.
About 25% faster.
decode: 248852 -> 200385 decicycles
(syntax check unchanged)

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-01-22 14:41:15 +01:00
Reimar Döffinger
420719e141 Cosmetics: add do {} while 0 to macro.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-01-22 14:41:15 +01:00
Jean First
39bf7ffeb5 pixdesc: cosmetics
Signed-off-by: Jean First <jeanfirst@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-22 00:46:19 +01:00
Reimar Döffinger
def19c9036 Unroll base64 decode loop.
Around 50% faster.
decode:       374139 -> 248852 decicycles
syntax check: 236955 -> 123854 decicycles

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-01-21 16:35:11 +01:00
Reimar Döffinger
523f676b51 Use a full table for base64 decode.
Also encodes error or end marker into table.
About 20% faster.
decode:       466491 -> 374139 decicycles
syntax check: 236955 -> 161182 decicycles

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-01-21 14:52:05 +01:00
Reimar Döffinger
8650d5faf9 base64: more thorough decode tests.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-01-21 12:04:46 +01:00
Michael Niedermayer
bdd739e91c base64: Only run benchmark when "-t" is specified.
As the test is run during fate and the benchmark is useless for fate
this very slightly speeds up fate. Its also consistent with the other
tests.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-21 05:13:56 +01:00
Michael Niedermayer
57822f0660 base64: fix little typo
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-21 02:10:19 +01:00
Michael Niedermayer
01084336b7 base64: add a benchmark for a pure syntax check.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-21 00:32:52 +01:00
Michael Niedermayer
ea4da94895 base64: simplify end handling in av_base64_encode()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-21 00:24:10 +01:00
Michael Niedermayer
112bca91b0 base64: optimize av_base64_encode()
This makes the code 2-3 times as fast

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-21 00:24:10 +01:00
Michael Niedermayer
a41687c2d6 base64: add benchmark
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-21 00:24:10 +01:00
Reimar Döffinger
d60d718c49 Slightly optimize base64 encode.
Move handling of last byte outside of innermost loop.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-01-20 23:28:31 +01:00
Reimar Döffinger
6af4c9814a Optimize output buffer size check in base64 decode.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-01-20 23:28:26 +01:00
Reimar Döffinger
686ba5f4ea Minor optimization of base64 decode.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
2012-01-20 23:27:16 +01:00
Michael Niedermayer
2d9e2c6464 opt: Fix "libavutil/opt.c:811:20: warning: initialization discards ‘const’ qualifier from pointer target type [enabled by default]"
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-20 20:34:48 +01:00
Stefano Sabatini
24860a913c tools: add ffeval tool
The tool is useful for testing the internal arithmetic evaluation engine
(indeed I plan to use it in FATE), and provides a handy calculator when
you can't rely on bc ;-).
2012-01-17 12:10:07 +01:00
Stefano Sabatini
999495734b lavu/eval: add if() and ifnot() eval functions
They allow to implement the if/then/else logic, which cannot be
implemented otherwise.

For example the expression:
A*B + not(A)*C

always evaluates to NaN if B is NaN, even in the case where A is 0.
2012-01-17 12:03:30 +01:00