Commit Graph

17159 Commits

Author SHA1 Message Date
Michael Niedermayer
09585e377c Merge commit '3041183677bda0a431b36e96a2c76617abaa8183'
* commit '3041183677bda0a431b36e96a2c76617abaa8183':
  dashenc: Heuristically fill in the duration of packets that need it

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-19 12:18:05 +01:00
Michael Niedermayer
76fef5cd27 Merge commit '2889c5e16711770437f380f1bead5f72c6a0b17a'
* commit '2889c5e16711770437f380f1bead5f72c6a0b17a':
  movenc: Heuristically set the duration of the last sample in a fragment if not set

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-19 12:09:51 +01:00
Michael Niedermayer
4f8540ba40 Merge commit '8dc72eeaf647736c287b59a3856a11904bedd58b'
* commit '8dc72eeaf647736c287b59a3856a11904bedd58b':
  udp: Fix crashes after adding AVOptions

See: aefed6ca87
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-19 11:22:39 +01:00
Martin Storsjö
3041183677 dashenc: Heuristically fill in the duration of packets that need it
This avoids that the mp4 muxer does a similar heuristic, adjusting
the timestamps in a way that the dash muxer doesn't know the actual
timestamps written to the file in the end. By making sure that the
mp4 muxer internal heuristic isn't applied, we know the exact
timestamps written to file, so that the timestamps in manifest match
the files.

Signed-off-by: Martin Storsjö <martin@martin.st>
2015-03-19 10:27:03 +02:00
Martin Storsjö
2889c5e167 movenc: Heuristically set the duration of the last sample in a fragment if not set
Even if this is a guess, it is way better than writing a zero duration
of the last sample in a fragment (because if the duration is zero,
the first sample of the next fragment will have the same timestamp
as the last sample in the previous one).

Since we normally don't require libavformat muxer users to set
the duration field in AVPacket, we probably can't strictly require
it here either, so don't log this as a strict warning, only as info.

Signed-off-by: Martin Storsjö <martin@martin.st>
2015-03-19 10:26:52 +02:00
Martin Storsjö
8dc72eeaf6 udp: Fix crashes after adding AVOptions
Add a missing AVClass member, check whether localaddr is null.
(Previously, localaddr was always a local stack buffer, while it
now also can be an avoption string which can be null.)

This fixes crashes when not passing any localaddr parameter, since
66028b7ba.

Signed-off-by: Martin Storsjö <martin@martin.st>
2015-03-19 10:25:22 +02:00
Andreas Cadhalpun
b61cb61ab8 mxfenc: don't try to write footer without header
This fixes a crash, when trying to mux h264 into mxf_opatom.

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Previous version reviewed-by: tomas.hardin@codemill.se
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-19 02:20:30 +01:00
Michael Niedermayer
c5c09501f9 avformat/aiffdec: do not fail if header parser hits EOF
Based on patch by Martin Vignali <martin.vignali@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-19 01:44:14 +01:00
Michael Niedermayer
ae81e8a9c5 avformat/aiffdec: Stop header parsing once a non header packet is reached
Fix Ticket3530

Based-on debuging work by Martin Vignali <martin.vignali@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-19 01:39:47 +01:00
Michael Niedermayer
ee648903f5 Merge remote-tracking branch 'cehoyos/master'
* cehoyos/master:
  lavf/mkv: Ignore ff_isom_write_hvcc() return value as the mov muxer does.
  lavc/dts: Do not set bitrate for DTS-HD Master and High Resolution.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-18 21:24:35 +01:00
Michael Niedermayer
b3818c47d8 Merge commit '8692d74b7364b405d7939c0ed347e8a2815193a7'
* commit '8692d74b7364b405d7939c0ed347e8a2815193a7':
  mov: Add option to keep exact packet sequence after seeking

Conflicts:
	libavformat/isom.h
	libavformat/mov.c
	libavformat/version.h

See: 414d6547f3
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-18 21:15:18 +01:00
Carl Eugen Hoyos
7a5356c728 lavf/mkv: Ignore ff_isom_write_hvcc() return value as the mov muxer does.
This change allows remuxing hevc from mpeg-ts to Matroska.
2015-03-18 20:35:26 +01:00
Micah Galizia
c59654d67d avformat/http: replace cookies with updated values instead of appending forever
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-18 19:53:26 +01:00
Derek Buitenhuis
414d6547f3 mov: Add option to keep exact packet sequence after seeking
The current behavior may produce a different sequence of packets
after seeking, compared to demuxing linearly from the beginning.
This is because the MOV demuxer seeks in each stream individually,
based on timestamp, which may set each stream at a slightly different
position than if the file would have been read sequentially.

This makes implementing certain operations, such as segmenting,
quite hard, and slower than need be.

Therefore, add an option which retains the same packet sequence
after seeking, as when a file is demuxed linearly.
2015-03-18 14:30:07 +00:00
Derek Buitenhuis
8692d74b73 mov: Add option to keep exact packet sequence after seeking
The current behavior may produce a different sequence of packets
after seeking, compared to demuxing linearly from the beginning.
This is because the MOV demuxer seeks in each stream individually,
based on timestamp, which may set each stream at a slightly different
position than if the file would have been read sequentially.

This makes implementing certain operations, such as segmenting,
quite hard, and slower than need be.

Therefore, add an option which retains the same packet sequence
after seeking, as when a file is demuxed linearly.
2015-03-18 14:28:56 +00:00
Michael Niedermayer
07ca090e81 Merge commit '4326bc364b58e97fc3d89417054a6b7610179a00'
* commit '4326bc364b58e97fc3d89417054a6b7610179a00':
  lavf: Do not list mov-only codecs in riff tags

Conflicts:
	libavformat/Makefile
	libavformat/avidec.c

See: 2e0b5f5c90
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-17 21:09:43 +01:00
Michael Niedermayer
59f687b73c Merge commit '02d76141d68e38c80f9a205a56b9af10d74f0995'
* commit '02d76141d68e38c80f9a205a56b9af10d74f0995':
  riff: Add 'tshd' FourCC for H.264

Conflicts:
	libavformat/riff.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-17 20:48:39 +01:00
Michael Niedermayer
2cfa1fdb08 Merge commit '96dd04427fc46e5e25a5ac1f00753207e3aedb0c'
* commit '96dd04427fc46e5e25a5ac1f00753207e3aedb0c':
  isom: Add support for TSCC2

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-17 20:05:53 +01:00
Michael Niedermayer
13f8bbfb70 avformat/mov: fix mis-detection of jpeg2000
Fixes demuxer choice for Ticket 2792

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-17 19:05:44 +01:00
Andreas Cadhalpun
39ddda12f1 mxfenc: fix memleaks in mxf_write_footer
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Reviewed-by: tomas.hardin@codemill.se
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-17 15:05:41 +01:00
Vittorio Giovara
423f5d50e4 mov: Fix little endian audio detection
Set this field to TRUE if the audio component is to operate on
little-endian data, and FALSE otherwise.

However TRUE and FALSE are not defined. Since this flag is just a boolean,
interpret all values except for 0 as little endian.

Sample-Id: 64bit_FLOAT_Little_Endian.mov
2015-03-17 13:34:23 +00:00
Carl Eugen Hoyos
4326bc364b lavf: Do not list mov-only codecs in riff tags
Instead check for all mov code-points when demuxing avi
and print a warning if a video codec is found like this.

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2015-03-17 13:34:22 +00:00
Vittorio Giovara
02d76141d6 riff: Add 'tshd' FourCC for H.264 2015-03-17 13:34:22 +00:00
Paul B Mahol
cf9861dea5 isom: Add X-Com Radvision FourCC
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2015-03-17 13:34:22 +00:00
Luca Barbato
96dd04427f isom: Add support for TSCC2
As produced by Camtasia 4.
2015-03-17 12:21:23 +01:00
Michael Niedermayer
ae65cc7ed3 Merge commit '2cb9c2fc59c9267ad2631c07c81c188058502259'
* commit '2cb9c2fc59c9267ad2631c07c81c188058502259':
  movenc: Allow interleaving samples when writing fragmented files

Conflicts:
	libavformat/movenc.c
	libavformat/movenc.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 23:30:13 +01:00
Michael Niedermayer
b425b81fd2 avformat/rtsp: Fix potential pointer overflow in sdp_probe()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 22:40:36 +01:00
Michael Niedermayer
1b3b018aa4 avformat/mpegts: Fix potential pointer overflows
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 22:37:46 +01:00
Michael Niedermayer
312eb0d66f Merge commit '50ff0c05b691524d1fd044a2f2eefb706932fc98'
* commit '50ff0c05b691524d1fd044a2f2eefb706932fc98':
  movenc: Support writing multiple trun atoms

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 21:53:02 +01:00
zhaoxiu.zeng
332776f6c5 avformat/cavsvideodec: use avpriv_find_start_code in cavsvideo_probe()
Signed-off-by: Zeng Zhaoxiu <zhaoxiu.zeng@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 15:40:10 +01:00
Micah Galizia
fca0851879 avformat/hls: refactor repeated HLS option updates
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 13:01:39 +01:00
Martin Storsjö
2cb9c2fc59 movenc: Allow interleaving samples when writing fragmented files
This is incompatible with the omit_tfhd_offset flag (writing
position independent fragments with interleaving requires the
default_base_moof flag).

This makes the moof atoms slightly bigger, but can be better for
playback (improving locality of sample data in the mdat).

Signed-off-by: Martin Storsjö <martin@martin.st>
2015-03-16 13:23:19 +02:00
Martin Storsjö
50ff0c05b6 movenc: Support writing multiple trun atoms
This is needed if all the data for one track isn't continuous
within the mdat. Normally we make sure all the data for one
track is continuous, but in new cases we will need to have
the samples interleaved.

Signed-off-by: Martin Storsjö <martin@martin.st>
2015-03-16 13:23:19 +02:00
Michael Niedermayer
1e4d0498df avformat/mov: Disallow ".." in dref unless use_absolute_path is set
as this kind of allows to circumvent it to some extend.
We also could add a separate parameter or value to choose this

Found-by: ramiro
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 03:47:56 +01:00
Mark Reid
e575589378 libavformat/mxfdec: fix MXFPackage->comment_refs memory leak
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 03:37:44 +01:00
Micah Galizia
7859618aff avformat/hls: store cookies returned in HLS key response
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 01:57:01 +01:00
Michael Niedermayer
4f3f5ee1ac Merge commit '66028b7ba6b411ba12ef553e9c8f1f4a4fe27710'
* commit '66028b7ba6b411ba12ef553e9c8f1f4a4fe27710':
  udp: Use AVOptions

Conflicts:
	libavformat/udp.c

See: aefed6ca87
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-16 00:10:09 +01:00
Luca Barbato
66a0ac0a80 mkv: Add support for DVB subtitles
Bug-Id: 833
2015-03-15 23:49:17 +01:00
Michael Niedermayer
54db7df34b Merge commit 'a4c5801070198c1f2af32fa5cf850c330615ac24'
* commit 'a4c5801070198c1f2af32fa5cf850c330615ac24':
  sctp: Update to match tcp

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-15 22:43:10 +01:00
Luca Barbato
66028b7ba6 udp: Use AVOptions
Add AVOptions for options currently available as url parameters.
2015-03-15 18:29:11 +01:00
Luca Barbato
a4c5801070 sctp: Update to match tcp
Use AVOption and fallback over multiple addresses
2015-03-15 18:29:11 +01:00
Mark Reid
8d54850f33 libavformat/mxfenc: write user comment metadata
Reviewed-by: Tomas Härdin <tomas.hardin@codemill.se>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-15 17:17:38 +01:00
Michael Niedermayer
2cda1a16d0 avformat/dvbsub: Fix hypothetical pointer overflow in dvbsub_probe()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-15 13:45:31 +01:00
Michael Niedermayer
32c4b504b4 avformat/mpegvideodec: fix hypothetical pointer overflow in mpegvideo_probe()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-15 13:39:56 +01:00
zhaoxiu.zeng
84d8b4fb81 avformat/mpegvideodec: use avpriv_find_start_code in mpegvideo_probe()
Signed-off-by: Zeng Zhaoxiu <zhaoxiu.zeng@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-15 13:28:44 +01:00
zhaoxiu.zeng
213ddcb029 avformat/avidec: cleanup include
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-15 13:03:26 +01:00
zhaoxiu.zeng
bf696e265a avformat/avidec: use avpriv_find_start_code in avi_read_packet()
Signed-off-by: Zeng Zhaoxiu <zhaoxiu.zeng@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-15 13:02:57 +01:00
Mark Reid
43cafb956e libavformat/mxfdec: export user comments metadata
Previous-revision-reviewed-by: Tomas Härdin <tomas.hardin@codemill.se>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-14 22:46:18 +01:00
Michael Niedermayer
8003816e16 avformat/mov: Check for string truncation in mov_open_dref()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-14 21:57:04 +01:00
Michael Niedermayer
21a53dd08d avformat/mov: Use sizeof(filename) instead of a literal number
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-14 21:56:46 +01:00