Commit Graph

1383 Commits

Author SHA1 Message Date
Anton Khirnov
4ee5aed122 ffmpeg: do packet ts rescaling in write_packet()
This will be useful in the following commit, after which the muxer
timebase is not always available when encoding.

This merges Libav commit 3e265ca. It was previously skipped.

There are some changes with how/when the mux_timebase field is set,
because the Libav approach often causes a too imprecise time base
to be set. This is hard, because the muxer's write_header function
can readjust the timebase, at which point we might already have
encoded packets buffered. (It might be better to buffer them after
the encoder, instead of after all the timestamp handling logic
before muxing.)

The two FATE tests change because the output time base is raised
for subtitles. (Needed to avoid certain rounding issues in other
cases.)

Includes a minor merge fix by Mark Thompson, and

    avconv: Move rescale to stream timebase before monotonisation

also by Mark Thompson <sw@jkqxz.net>.

Signed-off-by: wm4 <nfxjfg@googlemail.com>
2017-03-03 08:45:43 +01:00
Micah Galizia
489c09ad4b add locale month names to av_small_strptime
Signed-off-by: Micah Galizia <micahgalizia@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-02-26 17:16:22 +01:00
Paul B Mahol
3a003cc381 fate: update ffprobe stuff after dbc7f02a72
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-02-26 17:05:43 +01:00
Paul B Mahol
dbc7f02a72 avfilter/aeval: trim last frame's number of samples to match requested duration
Fixes #6181.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-02-25 19:53:14 +01:00
Michael Niedermayer
d34bf886e9 avcodec/vp56: Implement very basic error concealment
This should fix the fate failure due to a truncated last frame.
Alternatively the frame could be dropped.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-02-25 13:09:50 +01:00
Michael Niedermayer
513a349439 avcodec/vp56: Fix sign typo
Fixes: 664/clusterfuzz-testcase-4917047475568640

The change to fate is due to a truncated last frames which is now detected as damaged.

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-02-24 22:23:53 +01:00
Michael Niedermayer
ed69cb83f8 fate/source: Check for cases that could use av_clip_uintp2() and av_clip_intp2()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-02-21 00:40:20 +01:00
Paul B Mahol
72864547f9 avfilter/vf_lut: do not always explicitly clip pixels
Old behaviour was not useful at all. New behaviour only emulate
old behaviour with default options.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-02-13 22:54:20 +01:00
erankor
37557b28b9 mov: add fate test for decryption with edit list
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-02-01 15:09:38 +01:00
Paul B Mahol
d1df72a702 fate: add SCC test
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-01-27 17:06:42 +01:00
Marton Balint
977fd88419 avfilter/formats: do not allow unknown layouts in ff_parse_channel_layout if nret is not set
Current code returned the number of channels as channel layout in that case,
and if nret is not set then unknown layouts are typically not supported.

Also use the common parsing code. Use a temporary workaround to parse an
unknown channel layout such as '13c', after a 1 year grace period only '13C'
will work.

Signed-off-by: Marton Balint <cus@passwd.hu>
2017-01-24 23:51:36 +01:00
Clément Bœsch
7448019890 Merge commit '38efff92f1ef81f3de20ff0460ec7b70c253d714'
* commit '38efff92f1ef81f3de20ff0460ec7b70c253d714':
  FATE: add a test for H.264 with two fields per packet
  h264: fix decoding multiple fields per packet with slice threads

This merge includes two commits because the FATE test was useful in
order to make proper testing.

The merge gets rid of the now unused:
- SLICE_SINGLETHREAD and SLICE_SKIPED macros
- max_contexts
- "again" label in decode_nal_units()

This commit also includes the fix from d3e4d406b.

Thanks to wm4 and Michael Niedermayer for their testing.

Merged-by: Clément Bœsch <u@pkh.me>
Merged-by: Matthieu Bouron <matthieu.bouron@gmail.com>
2017-01-24 16:13:03 +01:00
Carl Eugen Hoyos
c723108e25 lavf/matroskaenc: Do not write two CodecID elements for rawvideo.
Fixes ticket #6068.
2017-01-14 06:06:05 +01:00
Martin Vignali
1412e5a004 fate/psd : add test for bitmap and duotone
The duotone file is interpreted as gray

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-01-14 04:52:43 +01:00
Martin Vignali
682769d3d3 fate/psd : add test for 256 color
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-01-11 22:25:21 +01:00
Paul B Mahol
49abd5dbb8 avfilter/avf_aphasemeter: make video output optional
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2016-12-28 17:03:57 +01:00
Thomas Turner
8dcb28cf6d avutil/tests: Improved code coverage for random_seed
Signed-off-by: Thomas Turner <thomastdt@googlemail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-23 02:57:20 +01:00
Pavel Koshevoy
47cd8effea fate: Add test for ticket 6024, truncated decoding mode
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-22 20:35:27 +01:00
Thomas Turner
9f76ad2a46 avutil: Added selftest for libavutil/audio_fifo.c
Signed-off-by: Thomas Turner <thomastdt@googlemail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-21 03:37:54 +01:00
Martin Vignali
6672a49e5a fate/psd: add tests for uncompress and rle samples
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-16 02:07:20 +01:00
Derek Buitenhuis
b7e4ea0c80 fate: Add h264 test for frame num gaps
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-12-12 13:33:52 +00:00
Michael Niedermayer
2f07830e69 avcodec: Add max_pixels options
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-10 22:24:10 +01:00
Michael Niedermayer
1b39a30247 fate: add av_image_check_size() test
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-12-10 22:24:10 +01:00
James Almer
06c62ce09c fate: add a monoscopic spherical matroska test
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-09 11:19:38 -03:00
Vittorio Giovara
0c0da45f0f fate: Add a monoscopic spherical mov test 2016-12-07 14:41:02 -05:00
James Almer
b5a0b85721 fate: rename fate-mov-init-nonkeyframe ref file
Fixes the test. Regression since 059a786c20

Signed-off-by: James Almer <jamrial@gmail.com>
2016-12-02 20:06:17 -03:00
Paul B Mahol
6427c9ffee swscale: add gbr(a)p16 output support 2016-12-01 21:37:25 +01:00
Vittorio Giovara
115b834dcf fate: Add test for mov displaymatrix 2016-11-30 12:19:30 -05:00
Paul B Mahol
94d3d98246 fate: update after addition of gray10 to lavc/raw
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2016-11-30 00:08:05 +01:00
Martin Vignali
c9d1f4883d fate/exr: add test for pxr24 with half and uint32 channel
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2016-11-25 00:58:07 +01:00
James Almer
42ae9c6654 fate: update fate-source ref file
Signed-off-by: James Almer <jamrial@gmail.com>
2016-11-23 00:55:01 -03:00
Hendrik Leppkes
127cc6dd3d Merge commit '8d07e941b04d63fc4443dd986e3dc7b69cdcca43'
* commit '8d07e941b04d63fc4443dd986e3dc7b69cdcca43':
  FATE: add a test of H.264 SEI recovery in an intra refresh stream

Our H264 decoder drops 3 frames from the beginning of the stream, but
all frames after those match, hence the difference in the fate test.

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2016-11-18 11:32:10 +01:00
Hendrik Leppkes
9e1ddc0820 Merge commit '390b95b88b2b896b63f257f69e434dfc0111e076'
* commit '390b95b88b2b896b63f257f69e434dfc0111e076':
  fate: Add a mixed NAL coding sample

Merged-by: Hendrik Leppkes <h.leppkes@gmail.com>
2016-11-18 10:16:54 +01:00
Vittorio Giovara
00c8079816 fate: Add h264 extradata reload tests
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-16 02:43:19 +01:00
Carl Eugen Hoyos
b5177c7051 lsws: Add GRAY10 conversion.
Based on 19be5fb7 by Luca Barbato.
2016-11-14 10:35:06 +01:00
Nicolas George
22aa649c13 fate/colorkey: disable audio stream.
The test is not supposed to cover audio.
Also, using -vframes along with an audio stream depends on
the exact order the frames are processed by filters, it is
too much constraint to guarantee.
2016-11-13 10:41:16 +01:00
Sasi Inguva
c8dc11bb9e lavf/mov.c: Fallback to finding non-keyframe in fix_index, if keyframe search fails.
Signed-off-by: Sasi Inguva <isasi@google.com>
Reviewed-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-10 17:44:47 +01:00
Steven Liu
863ebe6f83 avformat/flvenc: add add_keyframe_index option
Add keyframe index metadata
Used to facilitate seeking; particularly for HTTP pseudo streaming.
 1. read live streaming or file by sequence
 2. if use add_keyframe_index option, add a mark flag at the position,
    use to insert new context at the last step.
 3. add the keyframes *offset* and *timestamp* into a list
 4. if use add_keyframe_index option, shift the metadata data from
    mark flag offset
 5. insert the keyframes *offset* and *timestamp* from the list by
    sequence
 6. free the list
 7. end.

Add FATE test case;

Reviewed-by: Lou Logan <lou@lrcd.com>
Signed-off-by: Steven Liu <liuqi@gosun.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-10 10:30:48 +08:00
Michael Niedermayer
2bc66d9e43 nut: add gray12 support
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-10 01:18:43 +01:00
Luca Barbato
19be5fb728 swscale: Add GRAY12
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-10 00:49:29 +01:00
Michael Niedermayer
b828788d58 swscale: Add GBRAP10 output
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-10 00:33:12 +01:00
Luca Barbato
2c7d8cbd66 swscale: Add the GBRAP12 output
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-10 00:33:12 +01:00
James Almer
e8a39f584a avformat/framehash: also print channel layout as a string
This should be more useful for users since numerical values for channel
layout can be confusing and unintuitive.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-11-05 22:42:22 -03:00
Michael Niedermayer
26e9efab1e fate: Remove show_formats for fate-mov-zombie test
This includes the absolute path

Found-by: jamrial
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-05 15:26:31 +01:00
Michael Niedermayer
5dc237aaaa fate: add zombie test
This test tests some odd sample with odd aspect ratio

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-05 10:24:48 +01:00
James Almer
7e603fb322 fate: add bsf tests for ticket 5927
Tested-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2016-11-04 22:13:44 -03:00
Rodger Combs
d401c37ef5
tests/fate/avformat: add segment.c tests 2016-11-02 01:16:26 -05:00
Martin Vignali
584f509a4b fate filter metadata : add test for aphasemeter - Test a mono file (in phase) -> 1. as result - Test a out of phase 1000 Hz -> -1. as result
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2016-11-01 17:13:02 +01:00
Sasi Inguva
5e965582d5 lavf/mov.c: Use the correct timescale when seeking for audio.
Signed-off-by: Sasi Inguva <isasi@google.com>
Reviewed-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-10-31 13:43:43 +00:00
James Almer
eabbc64728 avformat/matroskaenc: fix cue relative position values when CRC32 is enabled
The dynamic buffer does not contain the CRC32 element so calls to avio_tell()
don't take it into account. This resulted in CueRelativePosition values being
six bytes short.
This is a regression since 6724525a15

Instead of adding yet another custom check for CRC32 to fix a size or an offset,
remove the existing ones and reserve the six bytes in the dynamic buffer.

Signed-off-by: James Almer <jamrial@gmail.com>
2016-10-26 16:28:59 -03:00