Commit Graph

17743 Commits

Author SHA1 Message Date
Michael Niedermayer
838c5f3df7 avformat/utils: Redesign scoring in av_find_default_stream_index()
This avoids empty streams from being selected if a equivalent non empty one is available
The new system is also clearer and more systematic
This may need finetuning, which should be easy to do ...

Fixes Ticket2687

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 22:51:48 +02:00
Paul B Mahol
5165c600eb avformat/rtmpproto: increase hardcoded url/path lengths
Fixes #4103.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-07-01 20:03:26 +00:00
John Adlum
811008b8ee avformat/asfdec_f: Assert that packet positions match in asf_read_pts()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 18:47:59 +02:00
John Adlum
28206b75e8 avformat/asfdec_f: Correct skip to key code
Fixes Ticket3978

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 18:47:54 +02:00
Vadim Belov
db64af6395 avformat/concatdec: copy stream metadata when using concat
Reviewed-by: Nicolas George <george@nsup.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 14:43:31 +02:00
Michael Niedermayer
60ec3007e6 avformat/nutdec: Check ff_gen_search() for failure
Fixes assertion failure

Found-by: durandal_1707
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 14:28:41 +02:00
Michael Niedermayer
2f8c81637c avformat/matroskadec: Fix undefined shift in read_sint()
Fixes: asan_heap-oob_17212bc_2243_cov_594210248_h264_TTA.mkv

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 12:00:43 +02:00
Michael Niedermayer
55a04a5d7a Merge commit 'a1e2caa93e4f8102666a21222f01b74838b6497f'
* commit 'a1e2caa93e4f8102666a21222f01b74838b6497f':
  mov: Log format rather than fourcc in stsd in trace mode

Conflicts:
	libavformat/mov.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 04:15:27 +02:00
Michael Niedermayer
35c8dda5c2 Merge commit '2eef75fd7e1ac96ab9ca63bb4523078c908bc9b1'
* commit '2eef75fd7e1ac96ab9ca63bb4523078c908bc9b1':
  mov: Adjust variable types to fix format warnings

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 04:06:42 +02:00
Michael Niedermayer
a8e137a322 Merge commit 'df22e30172b09cda4d6f7d4f43508284be65848a'
* commit 'df22e30172b09cda4d6f7d4f43508284be65848a':
  dump: Use the correct abs() version

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-07-01 03:51:56 +02:00
Vittorio Giovara
a1e2caa93e mov: Log format rather than fourcc in stsd in trace mode
This will fix remaining format warnings.
2015-07-01 00:13:58 +01:00
Vittorio Giovara
2eef75fd7e mov: Adjust variable types to fix format warnings 2015-07-01 00:13:58 +01:00
Vittorio Giovara
df22e30172 dump: Use the correct abs() version
Fix warning from clang "absolute value function 'abs' given an argument
of type 'long long' but has parameter of type 'int' which may cause
truncation of value [-Wabsolute-value]".
2015-07-01 00:13:58 +01:00
Michael Niedermayer
cfcb9f5e36 Merge commit 'e95c7a61852cc5b9ce5445ff034b87553e61958a'
* commit 'e95c7a61852cc5b9ce5445ff034b87553e61958a':
  mov: Preserve the metadata even when bit-exactness is requested

Conflicts:
	libavformat/movenc.c
	tests/ref/vsynth/vsynth1-mpeg4
	tests/ref/vsynth/vsynth2-mpeg4

See: a17ee4117d
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-30 21:47:58 +02:00
Luca Barbato
e95c7a6185 mov: Preserve the metadata even when bit-exactness is requested
Make sure to not write the custom `encoder` string in that case.

Bug-Id: 845
CC: libav-stable@libav.org
2015-06-30 15:34:38 +02:00
John Högberg
42bc768e52 mpegts: Add jpeg2000 stream type
Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
2015-06-30 10:08:16 +02:00
Michael Niedermayer
088b410ea2 Merge commit '42bc768e5240ec01237ad2eb7c69b917158de258'
* commit '42bc768e5240ec01237ad2eb7c69b917158de258':
  mpegts: Add jpeg2000 stream type

Conflicts:
	libavformat/mpegts.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-30 13:08:26 +02:00
Michael Niedermayer
6d9dfb1267 Merge commit '1b4c468477f3b8d372da8ef4e5405539ad9c1501'
* commit '1b4c468477f3b8d372da8ef4e5405539ad9c1501':
  riff: Validate the wav header size before trying to parse it

Conflicts:
	libavformat/riffdec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-30 12:59:16 +02:00
Michael Niedermayer
3cd6b6aa0f Merge commit '5bdfc17189e4ea63c6b46b6d5256852fcb409d68'
* commit '5bdfc17189e4ea63c6b46b6d5256852fcb409d68':
  asf: Do not skip data streams

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-30 12:48:11 +02:00
Michael Niedermayer
0d5a27c2b5 Rename asfdec-o.c to asfdec_o.c
Most files use _ instead of - as spacer, so this is more consistent

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-30 12:23:44 +02:00
Michael Niedermayer
8f9c39b3e8 avformat: rename asfdec.c to asfdec_f.c
leaving it as asfdec.c confuses git

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-30 12:23:12 +02:00
Michael Niedermayer
e55e5be982 Merge remote-tracking branch 'cehoyos/master'
* cehoyos/master:
  lavf/msnwc: Return 0 if the probe function does not detect msnwc-tcp.
  lavf/mpegts: Return 0 if the probe function does not detect mpegts.
  lavf/img2dec: Improve detection of valid Quickdraw images.
  lavf/asfdec: Reduce minimum header size.
  Changelog: Add jpeg 2000 improvements before they get forgotten.
  lavf/img2dec: Autodetect dds frames.

Conflicts:
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29 17:29:13 +02:00
Michael Niedermayer
da8b228977 avformat/avio: Move avio_delete() avio_move() to avpriv_ namespace
This was suggested in the discussion about these functions

With this change the functions are available internally but are not
part of the public API

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29 16:30:43 +02:00
Carl Eugen Hoyos
4b920d7b4a lavf/msnwc: Return 0 if the probe function does not detect msnwc-tcp.
Reduces console spamming on debug level.
2015-06-29 16:29:07 +02:00
Carl Eugen Hoyos
77c0b149be lavf/mpegts: Return 0 if the probe function does not detect mpegts.
Reduces console spamming on debug level.
2015-06-29 16:27:36 +02:00
Carl Eugen Hoyos
dee7943819 lavf/img2dec: Improve detection of valid Quickdraw images.
Detect Quickdraw images without application header with
lower score.
2015-06-29 16:25:11 +02:00
Carl Eugen Hoyos
5a458420e2 lavf/asfdec: Reduce minimum header size.
Fixes GipsyGuitar.wmv mentioned in ticket #1477.
2015-06-29 16:23:15 +02:00
Carl Eugen Hoyos
a876a4da4a lavf/img2dec: Autodetect dds frames. 2015-06-29 16:13:26 +02:00
Michael Niedermayer
4ccd2b31f0 avformat/asfdec: Allow packet_obj_size == 0
Fixes Ticket3521

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29 04:57:51 +02:00
Michael Niedermayer
be4e1f28fd avformat/asfdec: Print packet_obj_size in case it is invalid
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29 04:55:06 +02:00
Ludmila Glinskih
ca3b274552 api-h264-test: build with another api test
Location of api-h264-test changed to special directory for api tests.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-29 02:49:32 +02:00
Michael Niedermayer
a5f617e9ec avformat/asfdec: Print a warning if data is skiped due to less than a frame header being left
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-28 23:22:31 +02:00
Michael Niedermayer
4b0a475846 avformat/asfdec: Reduce FRAME_HEADER_SIZE to 11
This fixes demuxing of screen_codec.wmv

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-28 23:22:31 +02:00
Luca Barbato
1b4c468477 riff: Validate the wav header size before trying to parse it 2015-06-28 17:32:40 +02:00
Luca Barbato
5bdfc17189 asf: Do not skip data streams 2015-06-28 17:10:54 +02:00
Michael Niedermayer
a57ee6cca1 Merge commit '8a26ae5f94e613dbf7eb8e3c60462e966e409cdc'
* commit '8a26ae5f94e613dbf7eb8e3c60462e966e409cdc':
  mpjpeg: Check stream allocation

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-28 13:41:44 +02:00
Michael Niedermayer
30b8f3e7dc Merge commit 'b08569a23948db107e5e6175cd4c695427d5339d'
* commit 'b08569a23948db107e5e6175cd4c695427d5339d':
  lavf: Replace the ASF demuxer

Conflicts:
	Changelog
	libavformat/asf.h
	libavformat/asfdec.c
	libavformat/version.h
	tests/ref/fate/wmv8-drm-nodec
	tests/ref/seek/lavf-asf

The rewritten demuxer is placed in a new file, the current demuxer is
left as default. Carl has tested both and the one working better is
default.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-28 13:36:54 +02:00
Michael Niedermayer
da06169850 avformat/riffdec: Forward error code from avio_read() in ff_get_guid()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-28 13:04:47 +02:00
Luca Barbato
8a26ae5f94 mpjpeg: Check stream allocation
Bug-Id: CID 1308152
2015-06-28 10:27:19 +02:00
Alexandra Hájková
b08569a239 lavf: Replace the ASF demuxer
The old one is the result of the reverse engineering and guesswork.
The new one has been written following the now-available specification.

This work is part of Outreach Program for Women Summer 2014 activities
for the Libav project.

The fate references had to be changed because the old demuxer truncates
the last frame in some cases, the new one handles it properly.
The seek-test reference is changed because seeking works differently
in the new demuxer. When seeking, the packet is not read from the stream
directly, but it is rather constructed by the demuxer. That is why
position is -1 now in the reference.

Signed-off-by: Anton Khirnov <anton@khirnov.net>
2015-06-28 10:16:40 +02:00
Andreas Cadhalpun
6b9fdf7f4f nutdec: check maxpos in read_sm_data before returning success
Otherwise sm_size can be larger than size, which results in a negative
packet size.

Reviewed-by: Michael Niedermayer <michaelni@gmx.at>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
2015-06-27 19:22:27 +02:00
Rodger Combs
68f00fb40b lavf/brstm: if the file lies about the last block's size, correct it
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-27 14:15:12 +02:00
schenk michael
b9161ef052 avformat/hls: do not iterate to next sequence number if interruption is requested
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-26 14:36:25 +02:00
Rodger Combs
0643b4bf74 lavf/brstm: expose the loop point when present
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-25 19:17:01 +02:00
Peter Ross
803bdc5469 electronicarts: demux alpha stream
Electronic Arts VP6 files may contain two video streams: one for the
primary video stream and another for the alpha mask. The file format
uses identical data structures for both streams.

Signed-off-by: Peter Ross <pross@xvid.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-25 12:45:09 +02:00
Peter Ross
a2517fca1e electronicarts: move video stream properties into dedicated structure
This is required for the alpha stream demux patch.

Signed-off-by: Peter Ross <pross@xvid.org>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-25 12:45:00 +02:00
Ludmila Glinskih
b04c630a3d libavformat: Add H264 API test
Result differs in pkt_duration and time_base.den for some reason.
Right now it tests only one example (adjusted to match the output).

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-25 04:09:51 +02:00
Michael Niedermayer
4107092349 Merge commit 'ded5957d75def70d2f1fc1c1eae079230004974b'
* commit 'ded5957d75def70d2f1fc1c1eae079230004974b':
  segafilm: Remove deplanarization hack

Conflicts:
	libavformat/segafilm.c
	libavformat/version.h

See: 42b8f5fba1
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-06-24 20:51:22 +02:00
James Almer
58d7dde081 brstm: fix use of uninitialized variables
Fixes valgrind complaining about "Conditional jump or move depends on uninitialised value(s)"

Signed-off-by: James Almer <jamrial@gmail.com>
2015-06-24 14:31:54 -03:00
Paul B Mahol
ded5957d75 segafilm: Remove deplanarization hack
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-06-24 14:45:09 +01:00