]> git.sesse.net Git - ffmpeg/log
ffmpeg
8 years agoavcodec/takdec: Skip last p2 sample (which is unused)
Michael Niedermayer [Sun, 15 Nov 2015 00:22:31 +0000 (01:22 +0100)]
avcodec/takdec: Skip last p2 sample (which is unused)

Fixes out of array read
Fixes: cb3f38b08b4541523974667c7d1eee9e/asan_heap-oob_2659e18_9838_021fd5cd635bf76cede6398cd9ecbcdd.tak
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/dxtory: Fix input size check in dxtory_decode_v1_410()
Michael Niedermayer [Sat, 14 Nov 2015 23:25:11 +0000 (00:25 +0100)]
avcodec/dxtory: Fix input size check in dxtory_decode_v1_410()

Fixes potential out of array read

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/dxtory: Fix input size check in dxtory_decode_v1_420()
Michael Niedermayer [Sat, 14 Nov 2015 23:25:11 +0000 (00:25 +0100)]
avcodec/dxtory: Fix input size check in dxtory_decode_v1_420()

Fixes out of array read
Fixes: c50c4aa6cefda71b19a31ea12302980c/asan_heap-oob_12be5fd_7011_33ebd015a74976215934add72b9c8352.avi
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/error_resilience: avoid accessing previous or next frames tables beyond height
Michael Niedermayer [Sat, 14 Nov 2015 20:11:52 +0000 (21:11 +0100)]
avcodec/error_resilience: avoid accessing previous or next frames tables beyond height

The height of tables can be rounded up for MBAFF but this does not imply that is also true
for the previous frames

Fixes out of array reads
Fixes: c106b36fa36db8ff8f3ed0c82be7bea2/asan_heap-oob_32699f0_6321_467b9a1d7e03d7cfd310b7e65dc53bcc.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agodds: disable palette flag for compressed dds
Andreas Cadhalpun [Fri, 13 Nov 2015 20:48:27 +0000 (21:48 +0100)]
dds: disable palette flag for compressed dds

Having both is not valid and can cause a NULL pointer dereference of
frame->data[1] later.

Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
8 years agoavcodec/pgssubdec: Check dimensions for 0
Michael Niedermayer [Sat, 14 Nov 2015 17:06:37 +0000 (18:06 +0100)]
avcodec/pgssubdec: Check dimensions for 0

Fixes division by 0
Fixes: b293a6479bb4b5286cff24d356bfd955/asan_generic_225c3c9_7819_cc526b657450c6cdef1371b526499626.mkv
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/rscc: Check input size for raw mode
Michael Niedermayer [Sat, 14 Nov 2015 16:59:56 +0000 (17:59 +0100)]
avcodec/rscc: Check input size for raw mode

Fixes out of array read
Fixes: 7fcd09eadd046e326d8ea0af66f166c8/asan_heap-oob_4a52e5_2273_fa6078a10dd575df266fb1e0b4114cd5.avi
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/simple_idct: use predefined M_SQRT2
Ganesh Ajjanagadde [Sat, 14 Nov 2015 15:55:10 +0000 (10:55 -0500)]
avcodec/simple_idct: use predefined M_SQRT2

M_SQRT2 is defined in math.h, or in avutil/mathematics.h for
compatibility hacks. This uses this value instead of a floating literal.

Fixed point values produced by C_FIX(), R_FIX() remain identical.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
8 years agoavcodec/mpegaudio: use predefined M_SQRT2
Ganesh Ajjanagadde [Sat, 14 Nov 2015 15:52:30 +0000 (10:52 -0500)]
avcodec/mpegaudio: use predefined M_SQRT2

M_SQRT2 is defined in math.h, or in avutil/mathematics.h for
compatibility hacks. This uses this value instead of an ad-hoc define.

Fixed point values produced by FIX() remain identical.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
8 years agoavcodec/mpegvideo: use predefined M_PI
Ganesh Ajjanagadde [Sat, 14 Nov 2015 15:49:45 +0000 (10:49 -0500)]
avcodec/mpegvideo: use predefined M_PI

M_PI is defined in math.h, or in avutil/mathematics.h for compatibility
hacks. This uses this value instead of an ad-hoc floating literal.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
8 years agoavcodec/ratecontrol: use predefined M_E
Ganesh Ajjanagadde [Wed, 11 Nov 2015 03:26:25 +0000 (22:26 -0500)]
avcodec/ratecontrol: use predefined M_E

M_E is defined in math.h, or in avutil/mathematics.h for compatibility
hacks. This uses this value instead of an ad-hoc define.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
8 years agoavcodec/dpx: Move need_align to act per line
Michael Niedermayer [Sat, 14 Nov 2015 13:29:02 +0000 (14:29 +0100)]
avcodec/dpx: Move need_align to act per line

Fixes out of array read
Fixes: 61cf123c081ee2bb774d307c75bdb99e/asan_heap-oob_1224f76_5546_bee833ffae73f752b489b9eeaac52db7.dpx
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavformat: implement SChannel SSP TLS protocol
Hendrik Leppkes [Sun, 4 Oct 2015 12:48:49 +0000 (14:48 +0200)]
avformat: implement SChannel SSP TLS protocol

This implementation does not support TLS listen sockets and loading
CA/Certs from files.

The Windows API does not support loading PEM certs, and would either
require a manual loader or instead be limited to loading Windows PFX
certificates

TLS listen sockets would have to be implemented quite separately, as many
of the APIs are different for server-mode (as opposed to client mode).

8 years agoavcodec/flashsv: Check size before updating it
Michael Niedermayer [Sat, 14 Nov 2015 12:34:02 +0000 (13:34 +0100)]
avcodec/flashsv: Check size before updating it

Fixes out of array read
Fixes: 3c857d4d90365731524716e6d051e43a/signal_sigsegv_7f4f59bcc29e_1386_20abd2c8e655cb9c75b24368e65fe3b1.flv
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/ffv1dec: Clear quant_table_count if its invalid
Michael Niedermayer [Sat, 14 Nov 2015 12:21:58 +0000 (13:21 +0100)]
avcodec/ffv1dec: Clear quant_table_count if its invalid

Fixes deallocation of corrupted pointer
Fixes: 343dfbe142a38b521ed069dc4ea7c03b/signal_sigsegv_421427_4074_ffb11959610278cd40dbc153464aa254.avi
No releases affected

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/avrndec: Use the AVFrame format instead of the context
Michael Niedermayer [Sat, 14 Nov 2015 12:04:54 +0000 (13:04 +0100)]
avcodec/avrndec: Use the AVFrame format instead of the context

Fixes out of array read
Fixes: 20dd01398dee0f6d83d7e5410a2ae8eb/signal_sigsegv_39eeb1f_4001_62efbdf1c60748dabf1ec310b59525fd.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavutil/common: add av_rint64_clip
Ganesh Ajjanagadde [Sun, 1 Nov 2015 14:33:29 +0000 (09:33 -0500)]
avutil/common: add av_rint64_clip

The rationale for this function is reflected in the documentation for
it, and is copied here:

Clip a double value into the long long amin-amax range.
This function is needed because conversion of floating point to integers when
it does not fit in the integer's representation does not necessarily saturate
correctly (usually converted to a cvttsd2si on x86) which saturates numbers
> INT64_MAX to INT64_MIN. The standard marks such conversions as undefined
behavior, allowing this sort of mathematically bogus conversions. This provides
a safe alternative that is slower obviously but assures safety and better
mathematical behavior.
API:
@param a value to clip
@param amin minimum value of the clip range
@param amax maximum value of the clip range
@return clipped value

Note that a priori if one can guarantee from the calling side that the
double is in range, it is safe to simply do an explicit/implicit cast,
and that will be far faster. However, otherwise this function should be
used.

avutil minor version is bumped.

Reviewed-by: Ronald S. Bultje <rsbultje@gmail.com>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
8 years agoavcodec/ivi: Check image dimensions
Michael Niedermayer [Sat, 14 Nov 2015 01:36:22 +0000 (02:36 +0100)]
avcodec/ivi: Check image dimensions

Fixes integer overflow
Fixes: 1e32c6c591d940337c20b197ec1c4d3d/asan_heap-oob_4a52e5_8946_0bb0d9e863def56005e49f1d89bdc94d.avi
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/utils: Better check for channels in av_get_audio_frame_duration()
Michael Niedermayer [Sat, 14 Nov 2015 00:35:08 +0000 (01:35 +0100)]
avcodec/utils: Better check for channels in av_get_audio_frame_duration()

Fixes integer overflow
Fixes: 0c2625f236ced104d402b4a03c0d65c7/asan_generic_274e1ce_5990_9314e7a67c26aecf011b178ade9f217c.avi
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/jpeg2000dec: Check for duplicate SIZ marker
Michael Niedermayer [Fri, 13 Nov 2015 23:51:56 +0000 (00:51 +0100)]
avcodec/jpeg2000dec: Check for duplicate SIZ marker

Fixes: 0231a17345734228011c6f35a64e4594/asan_heap-oob_1d92a72_3218_1213809a9e3affec77e4c191fdfdc0a9.mov
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavformat/async: Fix bug where async could not recover after seek to eof
Bryan Huh [Wed, 11 Nov 2015 10:00:21 +0000 (02:00 -0800)]
avformat/async: Fix bug where async could not recover after seek to eof

When async issues its inner seek via ffurl_seek, it treats failures as
EOF being reached. This is not consistent with the behavior of other
protocols (e.g. http, cache) which continue to tolerate reads after
failed seeks, and therefore does not interact correctly with them.

A common pattern where this manifests itself is where avio_seek is
called with pos to be the end-of-file - the http range-request would
fail here, and async would set io_eof_reached to 1. The background
thread would then refuse to read more bytes, and subsequent reads would
only empty the fifo and end in an error.

Presumably the code may have expected subsequent seeks to unset the
io_eof_reached but this is not guaranteed to be true - a subsequent seek
that lands in the AVIOContext's buffer (the fact that the
previously-failed avio_seek leaves the AVIOContext's buffer intact also
suggests that follow-up reads are expected to be tolerated) would not be
issued to the async_seek function, and when that buffer is drained only
async_read calls would follow, leading to the same error just described.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavformat/segafilm: Fix current_sample after seeking and avio_seek return type
Michael Niedermayer [Thu, 12 Nov 2015 22:37:21 +0000 (23:37 +0100)]
avformat/segafilm: Fix current_sample after seeking and avio_seek return type

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavformat/mux: Rename compute_pkt_fields2(), the name is absolutely terrible
Michael Niedermayer [Thu, 12 Nov 2015 22:06:32 +0000 (23:06 +0100)]
avformat/mux: Rename compute_pkt_fields2(), the name is absolutely terrible

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoos2threads: Add pthread_once()
KO Myung-Hun [Thu, 12 Nov 2015 03:31:51 +0000 (12:31 +0900)]
os2threads: Add pthread_once()

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agohevc: Fix a53 caption extraction
Will Kelleher [Wed, 11 Nov 2015 21:37:29 +0000 (15:37 -0600)]
hevc: Fix a53 caption extraction

Just realized my previous patch doesn't work quite right.  I uploaded a better
sample file that actually has visible captions to /incoming/hevc_cc.ts.  I
tested with that file doing hevc->x264 and it works.

This is basically an exact copy of the existing h264 logic.

Signed-off-by: Will Kelleher <wkelleher@gogoair.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavutil/x86/intmath: Fix intrinsic header include when using newer gcc with older...
Matt Oliver [Thu, 12 Nov 2015 05:54:08 +0000 (16:54 +1100)]
avutil/x86/intmath: Fix intrinsic header include when using newer gcc with older icc.

Signed-off-by: Matt Oliver <protogonoi@gmail.com>
8 years agoavutil/x86/bswap: Add msvc bswap instrinsics.
Matt Oliver [Mon, 9 Nov 2015 09:19:32 +0000 (20:19 +1100)]
avutil/x86/bswap: Add msvc bswap instrinsics.

This adds msvc optimisations as well as fixing an error in icl whereby it will generate invalid code otherwise.

Signed-off-by: Matt Oliver <protogonoi@gmail.com>
8 years agodds: add missing newline to log messages
Andreas Cadhalpun [Tue, 10 Nov 2015 23:37:32 +0000 (00:37 +0100)]
dds: add missing newline to log messages

Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
8 years agodds: validate compressed source buffer size
Andreas Cadhalpun [Tue, 10 Nov 2015 23:20:18 +0000 (00:20 +0100)]
dds: validate compressed source buffer size

A too small buffer will cause segfaults somewhere below
decompress_texture_thread.

Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
8 years agodds: validate source buffer size before copying
Andreas Cadhalpun [Tue, 10 Nov 2015 23:05:02 +0000 (00:05 +0100)]
dds: validate source buffer size before copying

If it is too small av_image_copy_plane segfaults.

Reviewed-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
8 years agoaacsbr_fixed: check for envelope scalefactors overflowing
Andreas Cadhalpun [Mon, 9 Nov 2015 19:41:16 +0000 (20:41 +0100)]
aacsbr_fixed: check for envelope scalefactors overflowing

This prevents various values from getting an insanely huge exponent.
If someone knows a cleaner solution, thats welcome!

This is similar to commit 8978c74 for aacsbr.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
8 years agoffserver: Replace one malloc(AVStream) by avformat_new_stream()
Michael Niedermayer [Wed, 11 Nov 2015 20:04:01 +0000 (21:04 +0100)]
ffserver: Replace one malloc(AVStream) by avformat_new_stream()

This fixes a null pointer dereference from the recently introduced
AVStream->internal

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoswresample/resample: increase precision for compensation
Michael Niedermayer [Wed, 11 Nov 2015 15:49:21 +0000 (16:49 +0100)]
swresample/resample: increase precision for compensation

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoffmpeg: Fix integer overflow with cur_dts being AV_NOPTS_VALUE
Michael Niedermayer [Wed, 11 Nov 2015 16:19:12 +0000 (17:19 +0100)]
ffmpeg: Fix integer overflow with cur_dts being AV_NOPTS_VALUE

Since de0e219a8aba72de201e85385c746cd1c04be1a2 cur_dts is sometimes invalid

8 years agoffserver: Do not add or rescale AV_NOPTS_VALUE from the demuxer
Michael Niedermayer [Sun, 1 Nov 2015 12:44:59 +0000 (13:44 +0100)]
ffserver: Do not add or rescale AV_NOPTS_VALUE from the demuxer

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoffmpeg: Print a warning if a pkt duration is already set before using the frame rate
Michael Niedermayer [Tue, 10 Nov 2015 21:53:30 +0000 (22:53 +0100)]
ffmpeg: Print a warning if a pkt duration is already set before using the frame rate

I didnt find any case that triggers this but if it gets triggered it needs to be
investigated

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoffmpeg: set muxer packet duration based on framerate only for CFR
Michael Niedermayer [Tue, 10 Nov 2015 21:53:29 +0000 (22:53 +0100)]
ffmpeg: set muxer packet duration based on framerate only for CFR

a set ost->frame_rate does not imply CFR in ffmpeg

The changed fate tests had all wrong packet durations
(like 1/1000 or 1/90000)

There might be more cases in which is_cfr could be set

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoMerge commit '8ad5124b7ecf7f727724e270a7b4bb8c7bcbf6a4'
Hendrik Leppkes [Wed, 11 Nov 2015 14:03:36 +0000 (15:03 +0100)]
Merge commit '8ad5124b7ecf7f727724e270a7b4bb8c7bcbf6a4'

* commit '8ad5124b7ecf7f727724e270a7b4bb8c7bcbf6a4':
  movenc: Automatically flush after writing the initial moov

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'db9b7321d5dfcbaf521d46beec44cf724776c70d'
Hendrik Leppkes [Wed, 11 Nov 2015 14:02:32 +0000 (15:02 +0100)]
Merge commit 'db9b7321d5dfcbaf521d46beec44cf724776c70d'

* commit 'db9b7321d5dfcbaf521d46beec44cf724776c70d':
  vsrc_color: implement frame rate

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '1339009c4924a20e872aa62897097bf5d071157c'
Hendrik Leppkes [Wed, 11 Nov 2015 14:01:15 +0000 (15:01 +0100)]
Merge commit '1339009c4924a20e872aa62897097bf5d071157c'

* commit '1339009c4924a20e872aa62897097bf5d071157c':
  vf_showinfo: show timebase & framerate too

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '11f87ca71e9c7b917f594194f827fd040d1df5ca'
Hendrik Leppkes [Wed, 11 Nov 2015 13:59:23 +0000 (14:59 +0100)]
Merge commit '11f87ca71e9c7b917f594194f827fd040d1df5ca'

* commit '11f87ca71e9c7b917f594194f827fd040d1df5ca':
  vf_frei0r: also set AVFilterLink.frame_rate

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '7d12cba95ca15198a930c05458dc414ac00c578b'
Hendrik Leppkes [Wed, 11 Nov 2015 13:58:33 +0000 (14:58 +0100)]
Merge commit '7d12cba95ca15198a930c05458dc414ac00c578b'

* commit '7d12cba95ca15198a930c05458dc414ac00c578b':
  vf_framepack: Check and update frame_rate

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '65e73bc60f98dc7b26c687e145dfb755d3f2ccfa'
Hendrik Leppkes [Wed, 11 Nov 2015 13:57:32 +0000 (14:57 +0100)]
Merge commit '65e73bc60f98dc7b26c687e145dfb755d3f2ccfa'

* commit '65e73bc60f98dc7b26c687e145dfb755d3f2ccfa':
  vf_interlace: implement frame rate

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '018bdaed37d2f1735dbecfc58309a1a164abadd5'
Hendrik Leppkes [Wed, 11 Nov 2015 13:56:32 +0000 (14:56 +0100)]
Merge commit '018bdaed37d2f1735dbecfc58309a1a164abadd5'

* commit '018bdaed37d2f1735dbecfc58309a1a164abadd5':
  setpts: add FRAME_RATE constant

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '5e91a5c5cf1db88f254b4c358eb1b06ff6ca274f'
Hendrik Leppkes [Wed, 11 Nov 2015 13:52:27 +0000 (14:52 +0100)]
Merge commit '5e91a5c5cf1db88f254b4c358eb1b06ff6ca274f'

* commit '5e91a5c5cf1db88f254b4c358eb1b06ff6ca274f':
  testsrc: set output framerate

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '9df477e03ef74068f3de130adc4dd34349a16ef2'
Hendrik Leppkes [Wed, 11 Nov 2015 13:50:33 +0000 (14:50 +0100)]
Merge commit '9df477e03ef74068f3de130adc4dd34349a16ef2'

* commit '9df477e03ef74068f3de130adc4dd34349a16ef2':
  yadif: update frame rate

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '1062880d69a4fdc8d8929dd5c22bb447182f1c41'
Hendrik Leppkes [Wed, 11 Nov 2015 13:49:30 +0000 (14:49 +0100)]
Merge commit '1062880d69a4fdc8d8929dd5c22bb447182f1c41'

* commit '1062880d69a4fdc8d8929dd5c22bb447182f1c41':
  vf_fps: set frame_rate.

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '61fb67dcb2e71a268c422fc19d366040e59fb337'
Hendrik Leppkes [Wed, 11 Nov 2015 13:48:34 +0000 (14:48 +0100)]
Merge commit '61fb67dcb2e71a268c422fc19d366040e59fb337'

* commit '61fb67dcb2e71a268c422fc19d366040e59fb337':
  buffersrc: accept the frame rate as argument.

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '48ff6683ba5d40b629428673b1028e8ec542a9fa'
Hendrik Leppkes [Wed, 11 Nov 2015 13:45:24 +0000 (14:45 +0100)]
Merge commit '48ff6683ba5d40b629428673b1028e8ec542a9fa'

* commit '48ff6683ba5d40b629428673b1028e8ec542a9fa':
  lavfi: add a frame_rate field to AVFilterLink.

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '79f5347a983342e2711ca8ba19ec3d8d151183f0'
Hendrik Leppkes [Wed, 11 Nov 2015 13:41:49 +0000 (14:41 +0100)]
Merge commit '79f5347a983342e2711ca8ba19ec3d8d151183f0'

* commit '79f5347a983342e2711ca8ba19ec3d8d151183f0':
  avcodec: fix doxy placement

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '8de1ee9f725aa3c550f425bd3120bcd95d5b2ea8'
Hendrik Leppkes [Wed, 11 Nov 2015 13:37:48 +0000 (14:37 +0100)]
Merge commit '8de1ee9f725aa3c550f425bd3120bcd95d5b2ea8'

* commit '8de1ee9f725aa3c550f425bd3120bcd95d5b2ea8':
  lavf: deprecate compute_pkt_fields2

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoavformat/utils: re-factor freeing AVStreams
Hendrik Leppkes [Wed, 11 Nov 2015 13:31:10 +0000 (14:31 +0100)]
avformat/utils: re-factor freeing AVStreams

This matches the Libav signature and simplifies merging future changes.

8 years agoavformat/rsd: XMA2 is actually stored, not XMA1
Paul B Mahol [Tue, 10 Nov 2015 20:29:25 +0000 (21:29 +0100)]
avformat/rsd: XMA2 is actually stored, not XMA1

Signed-off-by: Paul B Mahol <onemda@gmail.com>
8 years agoffmpeg_filter: remove redundant null ptr check
Michael Niedermayer [Wed, 11 Nov 2015 00:51:52 +0000 (01:51 +0100)]
ffmpeg_filter: remove redundant null ptr check

Fixes: CID1338331
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavfilter/avf_showcqt: Fix uninitialized return code
Michael Niedermayer [Wed, 11 Nov 2015 00:07:45 +0000 (01:07 +0100)]
avfilter/avf_showcqt: Fix uninitialized return code

Fixes CID1322329

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/webvttdec: Fix uninitialized use of variable "again"
Michael Niedermayer [Tue, 10 Nov 2015 23:28:28 +0000 (00:28 +0100)]
avcodec/webvttdec: Fix uninitialized use of variable "again"

Fixes CID1338336
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agodvdsubdec: validate offset2 similar to offset1
Andreas Cadhalpun [Tue, 10 Nov 2015 21:14:39 +0000 (22:14 +0100)]
dvdsubdec: validate offset2 similar to offset1

If it is negative, it causes segmentation faults in decode_rle.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
8 years agoavutil/x86/intmath: Disable use of tzcnt on older intel compilers.
Matt Oliver [Tue, 10 Nov 2015 13:13:42 +0000 (00:13 +1100)]
avutil/x86/intmath: Disable use of tzcnt on older intel compilers.

ICC versions older than atleast 12.1.6 dont have the tzcnt intrinsics.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Matt Oliver <protogonoi@gmail.com>
8 years agoavformat/mov: Add option to ignore chapters during parsing
Bryan Huh [Tue, 10 Nov 2015 19:11:26 +0000 (11:11 -0800)]
avformat/mov: Add option to ignore chapters during parsing

Chapter-indexing can be expensive since chapters may be interspersed
throughout the entire file and may require many seeks - especially
costly when consuming a video over a remote protocol like http.
Furthermore it is often unnecessary, especially when only trying to get
video info (e.g. via ffprobe).

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavformat/mxfenc: Only store user comment related tags when needed
Michael Niedermayer [Mon, 9 Nov 2015 13:24:26 +0000 (14:24 +0100)]
avformat/mxfenc: Only store user comment related tags when needed

Also support disabling them as they seem to cause problems to some
Users. They are also not allowed in IRT D-10 thus the default for
mxf_d10 is not to write them

This also decreases the filesize when no user comment are stored

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/gifdec: skip the data lzw consumed
Ni Hui [Tue, 10 Nov 2015 14:03:36 +0000 (22:03 +0800)]
avcodec/gifdec: skip the data lzw consumed

this fixes the return code of avcodec_decode_video2 for gif decoding
and the gif frame data buffer is skipped properly

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavcodec/lzw: ff_lzw_decode_tail() now returns the consumed bytes in lzw decompress
Ni Hui [Tue, 10 Nov 2015 14:03:36 +0000 (22:03 +0800)]
avcodec/lzw: ff_lzw_decode_tail() now returns the consumed bytes in lzw decompress

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agobrstm: reject negative sample rate
Andreas Cadhalpun [Tue, 10 Nov 2015 19:10:23 +0000 (20:10 +0100)]
brstm: reject negative sample rate

A negative sample rate causes assertion failures in av_rescale_rnd.

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
8 years agoavcodec/wmaprodec: XMA1 actually have packet sequence numbers
Paul B Mahol [Tue, 10 Nov 2015 20:24:30 +0000 (21:24 +0100)]
avcodec/wmaprodec: XMA1 actually have packet sequence numbers

Signed-off-by: Paul B Mahol <onemda@gmail.com>
8 years agomovenc: Automatically flush after writing the initial moov
Martin Storsjö [Fri, 6 Nov 2015 23:18:05 +0000 (01:18 +0200)]
movenc: Automatically flush after writing the initial moov

In most other cases when writing fragmented mp4 files, the output
IO context is flushed after each fragment. Also flush it after
writing the initial moov, to have it behave in the same way.

Signed-off-by: Martin Storsjö <martin@martin.st>
8 years agoaviflter/vf_waveform: speed up non-color filters
Paul B Mahol [Tue, 10 Nov 2015 18:39:23 +0000 (19:39 +0100)]
aviflter/vf_waveform: speed up non-color filters

Remove loops, output is also more interesting.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
8 years agoavformat/wavdec: allow data chunk to be before fmt/xma2 chunk
Paul B Mahol [Sun, 8 Nov 2015 11:27:42 +0000 (12:27 +0100)]
avformat/wavdec: allow data chunk to be before fmt/xma2 chunk

Signed-off-by: Paul B Mahol <onemda@gmail.com>
8 years agoavformat/wavdec: parse XMA2 tag
Paul B Mahol [Sat, 7 Nov 2015 16:32:19 +0000 (17:32 +0100)]
avformat/wavdec: parse XMA2 tag

Signed-off-by: Paul B Mahol <onemda@gmail.com>
8 years agoMerge commit 'aeda1121c91395d1f0d434bc7f227423aa2ff97d'
Hendrik Leppkes [Tue, 10 Nov 2015 17:42:08 +0000 (18:42 +0100)]
Merge commit 'aeda1121c91395d1f0d434bc7f227423aa2ff97d'

* commit 'aeda1121c91395d1f0d434bc7f227423aa2ff97d':
  lavf: factor out freeing an AVStream

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '3efd71b4d0b4a73ccbbbdc092e6bbd54d92633f4'
Hendrik Leppkes [Tue, 10 Nov 2015 17:25:51 +0000 (18:25 +0100)]
Merge commit '3efd71b4d0b4a73ccbbbdc092e6bbd54d92633f4'

* commit '3efd71b4d0b4a73ccbbbdc092e6bbd54d92633f4':
  avconv: set packet duration for CFR video streams

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'a0c71a575109f123978e345fa7eb4ac03cd4d3c3'
Hendrik Leppkes [Tue, 10 Nov 2015 17:23:22 +0000 (18:23 +0100)]
Merge commit 'a0c71a575109f123978e345fa7eb4ac03cd4d3c3'

* commit 'a0c71a575109f123978e345fa7eb4ac03cd4d3c3':
  lavf: initialize cur_dts to AV_NOPTS_VALUE for muxing

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'cc96018c79cd4dc823e0cef938da2131e4660fe5'
Hendrik Leppkes [Tue, 10 Nov 2015 17:19:15 +0000 (18:19 +0100)]
Merge commit 'cc96018c79cd4dc823e0cef938da2131e4660fe5'

* commit 'cc96018c79cd4dc823e0cef938da2131e4660fe5':
  libopenh264enc: Set AVOption data type

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'fcc49924db6c5530a3346c45a6999244d92eaf48'
Hendrik Leppkes [Tue, 10 Nov 2015 17:18:17 +0000 (18:18 +0100)]
Merge commit 'fcc49924db6c5530a3346c45a6999244d92eaf48'

* commit 'fcc49924db6c5530a3346c45a6999244d92eaf48':
  vdpau: Remove a spurious CONFIG_H263_VDPAU_HWACCEL

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '563e6d860391bac0511984e5c0842320b5c94d2d'
Hendrik Leppkes [Tue, 10 Nov 2015 17:18:05 +0000 (18:18 +0100)]
Merge commit '563e6d860391bac0511984e5c0842320b5c94d2d'

* commit '563e6d860391bac0511984e5c0842320b5c94d2d':
  segafilm: drop the "song and dance" for cinepak

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '1e791ee3aae63122afb10cbabe86a747aea58992'
Hendrik Leppkes [Tue, 10 Nov 2015 17:17:02 +0000 (18:17 +0100)]
Merge commit '1e791ee3aae63122afb10cbabe86a747aea58992'

* commit '1e791ee3aae63122afb10cbabe86a747aea58992':
  segafilm: set video and audio stream duration

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'c012c6f1a8b34828a7870dc1854422934f14b79a'
Hendrik Leppkes [Tue, 10 Nov 2015 17:16:11 +0000 (18:16 +0100)]
Merge commit 'c012c6f1a8b34828a7870dc1854422934f14b79a'

* commit 'c012c6f1a8b34828a7870dc1854422934f14b79a':
  segafilm: implement seeking

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '2ec112f71cd03ccab1b6f9a00d29199a57bcc7a5'
Hendrik Leppkes [Tue, 10 Nov 2015 17:13:46 +0000 (18:13 +0100)]
Merge commit '2ec112f71cd03ccab1b6f9a00d29199a57bcc7a5'

* commit '2ec112f71cd03ccab1b6f9a00d29199a57bcc7a5':
  vf_pad: fix x, y option expression evaluation

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'e2854e731f843906d9a9a5b882bed872341999fd'
Hendrik Leppkes [Tue, 10 Nov 2015 17:07:41 +0000 (18:07 +0100)]
Merge commit 'e2854e731f843906d9a9a5b882bed872341999fd'

* commit 'e2854e731f843906d9a9a5b882bed872341999fd':
  avresample: Document avresample_open() a little better

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'f128b8e19ac7f702adae899ab91cc1e80f238761'
Hendrik Leppkes [Tue, 10 Nov 2015 17:01:36 +0000 (18:01 +0100)]
Merge commit 'f128b8e19ac7f702adae899ab91cc1e80f238761'

* commit 'f128b8e19ac7f702adae899ab91cc1e80f238761':
  mov: detect cover art pictures by content

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '50d2a3b5f34e6f99e5ffe17f2be5eb1815555960'
Hendrik Leppkes [Tue, 10 Nov 2015 17:00:51 +0000 (18:00 +0100)]
Merge commit '50d2a3b5f34e6f99e5ffe17f2be5eb1815555960'

* commit '50d2a3b5f34e6f99e5ffe17f2be5eb1815555960':
  flashsv: Initialize the block array

Not merged, blocks are already zeroed when appropriate.

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'de41b555cdea2dcacbe98ee9edc83a8c15c73c4c'
Hendrik Leppkes [Tue, 10 Nov 2015 16:58:14 +0000 (17:58 +0100)]
Merge commit 'de41b555cdea2dcacbe98ee9edc83a8c15c73c4c'

* commit 'de41b555cdea2dcacbe98ee9edc83a8c15c73c4c':
  truemotion2: Fix the buffer check

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '4a326923381f2bc0fb7d960c8f8366a5456bc4ab'
Hendrik Leppkes [Tue, 10 Nov 2015 16:56:48 +0000 (17:56 +0100)]
Merge commit '4a326923381f2bc0fb7d960c8f8366a5456bc4ab'

* commit '4a326923381f2bc0fb7d960c8f8366a5456bc4ab':
  mimic: Always return on failure

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '452d659aa4a742106c70ffe9ef3df47ef5b81ea6'
Hendrik Leppkes [Tue, 10 Nov 2015 16:56:14 +0000 (17:56 +0100)]
Merge commit '452d659aa4a742106c70ffe9ef3df47ef5b81ea6'

* commit '452d659aa4a742106c70ffe9ef3df47ef5b81ea6':
  msnwc_tcp: Use the correct return values

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit 'f8d10511fef0bb3265f2d7bdfd38f90f60731d80'
Hendrik Leppkes [Tue, 10 Nov 2015 16:55:25 +0000 (17:55 +0100)]
Merge commit 'f8d10511fef0bb3265f2d7bdfd38f90f60731d80'

* commit 'f8d10511fef0bb3265f2d7bdfd38f90f60731d80':
  cosmetics: msnwc_tcp: Reformat

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '4dfbc7a7559ccab666a8fd39de4224eb4b02c768'
Hendrik Leppkes [Tue, 10 Nov 2015 16:54:06 +0000 (17:54 +0100)]
Merge commit '4dfbc7a7559ccab666a8fd39de4224eb4b02c768'

* commit '4dfbc7a7559ccab666a8fd39de4224eb4b02c768':
  msnwc_tcp: Correctly report failure

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '60f50374f1955442dc987abc4a6c61c2109620c2'
Hendrik Leppkes [Tue, 10 Nov 2015 16:50:12 +0000 (17:50 +0100)]
Merge commit '60f50374f1955442dc987abc4a6c61c2109620c2'

* commit '60f50374f1955442dc987abc4a6c61c2109620c2':
  rpza: Check the blocks left before processing one

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '0b699920f3c0b2e30969b38ce59226653f9d80ec'
Hendrik Leppkes [Tue, 10 Nov 2015 16:43:17 +0000 (17:43 +0100)]
Merge commit '0b699920f3c0b2e30969b38ce59226653f9d80ec'

* commit '0b699920f3c0b2e30969b38ce59226653f9d80ec':
  lagarith: Correctly compute hash_shift

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoMerge commit '1e7ff5ac6923996f7292c82f102c68384fbc9d97'
Hendrik Leppkes [Tue, 10 Nov 2015 16:38:09 +0000 (17:38 +0100)]
Merge commit '1e7ff5ac6923996f7292c82f102c68384fbc9d97'

* commit '1e7ff5ac6923996f7292c82f102c68384fbc9d97':
  nut: Use the correct codec_tag when multiple are available

Not merged since ffnutenc handles the codec_tag differently

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
8 years agoavutil/softfloat: use abort() instead of av_assert0(0)
James Almer [Tue, 10 Nov 2015 02:16:17 +0000 (23:16 -0300)]
avutil/softfloat: use abort() instead of av_assert0(0)

Fixes compilation of host tool aacps_fixed_tablegen.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
8 years agoavcodec/g729postfilter: Avoid function calls in FFMAX() arguments
Michael Niedermayer [Tue, 10 Nov 2015 13:35:08 +0000 (14:35 +0100)]
avcodec/g729postfilter: Avoid function calls in FFMAX() arguments

This avoid double calling functions

Found-by: Muhammad Faiz <mfcc64@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agommaldec: send only a single EOS packet on flushing
wm4 [Tue, 10 Nov 2015 12:47:01 +0000 (13:47 +0100)]
mmaldec: send only a single EOS packet on flushing

Fixes apparent mmal_port_disable() freezes in ffmmal_stop_decoder() when
calling ffmmal_decode() with flush semantics a large number of times in
a row.

8 years agoavcodec/aacsbr_fixed: Try to initialize sum[0..1] differently to fix build with VS2012
Michael Niedermayer [Tue, 10 Nov 2015 12:33:38 +0000 (13:33 +0100)]
avcodec/aacsbr_fixed: Try to initialize sum[0..1] differently to fix build with VS2012

Found-by: Hendrik Leppkes <h.leppkes@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoavformat: Add v210[x] demuxer
Timothy Gu [Sat, 7 Nov 2015 23:59:01 +0000 (15:59 -0800)]
avformat: Add v210[x] demuxer

Allows one to do:

    ffmpeg -s 1920x1080          -i blah.v210 ...
    ffmpeg -s 1920x1080 -f v210x -i blah.yuv10 ...

Fixes #1869.

Reviewed-by: James Almer <jamrial@gmail.com>
Reviewed-by: Kieran Kunhya <kierank@obe.tv>
8 years agotests/fate/avformat: Fix fate-lavf
Michael Niedermayer [Tue, 10 Nov 2015 03:14:55 +0000 (04:14 +0100)]
tests/fate/avformat: Fix fate-lavf

The CMP variable seems to have been inherited from fate-api-seek which set it to null

the mxf reference needed a change due to c7e14a279fa7348db10ec824bb2d67858cb1c1ca

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoaacdec: don't return frames without data from aac_decode_er_frame
Andreas Cadhalpun [Mon, 9 Nov 2015 21:16:01 +0000 (22:16 +0100)]
aacdec: don't return frames without data from aac_decode_er_frame

This is similar to commit ec38a1b for aac_decode_frame_int.

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
8 years agoaacps: avoid division by zero in stereo_processing
Andreas Cadhalpun [Sun, 8 Nov 2015 21:04:08 +0000 (22:04 +0100)]
aacps: avoid division by zero in stereo_processing

This fixes a SIGFPE crash in the aac_fixed decoder.

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Reviewed-by: Rostislav Pehlivanov <atomnuker@gmail.com>
8 years agoffserver: fix incorrect strlcpy usage
Ganesh Ajjanagadde [Fri, 6 Nov 2015 20:47:37 +0000 (15:47 -0500)]
ffserver: fix incorrect strlcpy usage

Somewhat ironic that this "safe" interface is actually being used
unsafely here. This fixes the usage preventing potential null pointer
dereference, where the old code was doubly broken: ctime can return
NULL, and ctime can return an arbitrarily long buffer.

Reviewed-by: Mark Harris <mark.hsj@gmail.com>
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
8 years agoswresample/resample: speed up Blackman Nuttall filter
Ganesh Ajjanagadde [Mon, 9 Nov 2015 05:38:45 +0000 (00:38 -0500)]
swresample/resample: speed up Blackman Nuttall filter

This may be a slightly surprising optimization, but is actually based on
an understanding of how math libraries compute trigonometric functions.
Explanation is given here so that future development uses libm more effectively
across the codebase.

All libm's essentially compute transcendental functions via some kind of
polynomial approximation, be it Taylor-Maclaurin or Chebyshev.
Correction terms are added via polynomial correction factors when needed
to squeeze out the last bits of accuracy. Lookup tables are also
inserted strategically.

In the case of trigonometric functions, periodicity is exploited via
first doing a range reduction to an interval around zero, and then using
some polynomial approximation.

This range reduction is the most natural way of doing things - else one
would need polynomials for ranges in different periods which makes no
sense whatsoever.

To avoid the need for the range reduction, it is helpful to feed in
arguments as close to the origin as possible for the trigonometric
functions. In fact, this also makes sense from an accuracy point of view:
IEEE floating point has far more resolution for small numbers than big ones.

This patch does this for the Blackman-Nuttall filter, and yields a
non-negligible speedup.

Sample benchmark (x86-64, Haswell, GNU/Linux)
test: fate-swr-resample-dblp-2626-44100
old:
18893514 decicycles in build_filter (loop 1000),     256 runs,      0 skips
18599863 decicycles in build_filter (loop 1000),     512 runs,      0 skips
18445574 decicycles in build_filter (loop 1000),    1000 runs,     24 skips

new:
16290697 decicycles in build_filter (loop 1000),     256 runs,      0 skips
16267172 decicycles in build_filter (loop 1000),     512 runs,      0 skips
16251105 decicycles in build_filter (loop 1000),    1000 runs,     24 skips

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
8 years agoswresample/resample: speed up upsampling by precomputing sines
Ganesh Ajjanagadde [Mon, 9 Nov 2015 02:39:32 +0000 (21:39 -0500)]
swresample/resample: speed up upsampling by precomputing sines

When upsampling, factor is set to 1 and sines need to be evaluated only
once for each phase, and the complexity should not depend on the number
of filter taps. This does the desired precomputation, yielding
significant speedups. Hard guarantees on the gain are not possible, but gains
themselves are obvious and are illustrated below.

Sample benchmark (x86-64, Haswell, GNU/Linux)
test: fate-swr-resample-dblp-2626-44100
old:
29161085 decicycles in build_filter (loop 1000),     256 runs,      0 skips
28821467 decicycles in build_filter (loop 1000),     512 runs,      0 skips
28668201 decicycles in build_filter (loop 1000),    1000 runs,     24 skips

new:
14351936 decicycles in build_filter (loop 1000),     256 runs,      0 skips
14306652 decicycles in build_filter (loop 1000),     512 runs,      0 skips
14299923 decicycles in build_filter (loop 1000),    1000 runs,     24 skips

Note that this does not statically allocate the sin lookup table. This
may be done for the default 1024 phases, yielding a 512*8 = 4kB array
which should be small enough.
This should yield a small improvement. Nevertheless, this is separate from
this patch, is more ambiguous due to the binary increase, and requires a
lut to be generated offline.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
8 years agodoc/ffmpeg: Clarify that the sdp_file option requires an rtp output.
Simon Thelen [Mon, 2 Nov 2015 14:57:50 +0000 (15:57 +0100)]
doc/ffmpeg: Clarify that the sdp_file option requires an rtp output.

Signed-off-by: Simon Thelen <ffmpeg-dev@c-14.de>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>