Commit Graph

16577 Commits

Author SHA1 Message Date
Martin Storsjö
724cbea719 movenc: Remove an unnecessary condition when flushing fragments
If fragments == 0 it means we haven't written any moov atom yet.
If the empty_moov flag is set, we already have written an empty moov
atom at startup. Thus, the check for empty_moov is redundant.

This is in preparation for allowing writing the moov atom later,
even when using the empty moov flag.

Signed-off-by: Martin Storsjö <martin@martin.st>
2015-01-03 01:18:38 +02:00
Martin Storsjö
355d01a1bf movenc: Factorize writing ftyp and other identification tags to a separate function
Signed-off-by: Martin Storsjö <martin@martin.st>
2015-01-03 01:18:28 +02:00
Clément Bœsch
11201bbf7f avformat/mov: reindent after previous commit 2015-01-02 11:38:28 +01:00
Clément Bœsch
55faf56c72 avformat/mov: move edit list heuristics into mov_build_index()
mov_read_elst() is now only responsible from storing the table in a data
structure; this is consistent with other table readers functions.
2015-01-02 11:38:21 +01:00
Clément Bœsch
6a29499b95 avformat/flvdec: remove duplicated line error
Fix typo regression since 5c37ffca59

Found-By: cousin_luigi
2015-01-01 22:09:21 +01:00
Michael Niedermayer
efc4bfc195 avformat/flvdec: use named identifier instead of literal numbers as return values
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-01 20:19:09 +01:00
Michael Niedermayer
eb767a276b avformat/flvdec: Increase string array size
Fixes parsing httphostheader of Scarlatti\,\ Pieter-Jan\ Belder\ -\ Sonata\ K113\ in\ A\ major\ -\ Alle.flv

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-01 18:16:04 +01:00
Michael Niedermayer
322f0f5960 avformat/flvdec: do not inject dts=0 metadata packets which failed to be parsed into a new data stream
Such data streams (which then contain no other packets except the faulty one)
confuse some user applications, like VLC
Works around vlcticket 12389

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-01 18:13:22 +01:00
Michael Niedermayer
5c37ffca59 avformat/flvdec: add several error messages to error conditions
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-01-01 18:03:54 +01:00
Michael Niedermayer
3eb5cbe0c5 avformat/cdxl: Fix integer overflow of image_size
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-31 22:33:51 +01:00
Michael Niedermayer
0ffb61e8ca Merge commit '8d54bacb789c7d37ca3cf48d9ac13083ad0c1ba7'
* commit '8d54bacb789c7d37ca3cf48d9ac13083ad0c1ba7':
  dashenc: Remove some stray double spaces

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-30 01:57:21 +01:00
Michael Niedermayer
e5a3766767 Merge commit 'b91a5757fcbf723da99b05b298a6f820271dbc2b'
* commit 'b91a5757fcbf723da99b05b298a6f820271dbc2b':
  dashenc: Fix writing of timelines that don't start at t=0

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-30 01:50:53 +01:00
Martin Storsjö
8d54bacb78 dashenc: Remove some stray double spaces
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-29 23:26:43 +02:00
Martin Storsjö
b91a5757fc dashenc: Fix writing of timelines that don't start at t=0
When writing an explicit time, reset the cur_time variable to this
value as well. This avoids writing excessive time attributes for each
segment in the timeline, as long as the segments are continuous.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-29 23:26:25 +02:00
Michael Niedermayer
256df8a2fa libavformat/cdxl: fix duration in case of overflow
Fixes integer overflow
Fixes CID1260706

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-29 20:53:56 +01:00
Michael Niedermayer
ac08c5c0ad avformat/mux: 2 subtitle packets could have the same DTS
Fixes Ticket3514

See: ETSI EN 300 743 V1.3.1 (2006-11)
"In summary, all of the segments of a single display set shall be carried in one (or more) PES packets that have the same
 PTS value."
with PTS = DTS and remuxing of such a stream it is to be expected that sometimes
multiple packets would have the same DTS

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-29 03:57:44 +01:00
Pedro E. M. Brito
202947a066 libavformat/segment.c: Add strftime expansion for segment filename templates
Allows expansion of the filename template with strftime() with the option
-strftime 1 (disabled by default). This allows segments to be named by time of
creation, adding some flexibility.

Fixes Ticket 4104 (add strftime to segment muxer)

Signed-off-by: Pedro E. M. Brito <pedroembrito@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-28 21:48:44 +01:00
Michael Niedermayer
f7da4b1cf1 avformat/rtsp: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-26 14:59:29 +01:00
Michael Niedermayer
0704c44d68 avformat/cache: remove ftruncate usage, its not always available
In case of errors the cache file will be slightly larger than needed,
this should have no practical relevance though

Should fix build on VS201*

Found-by: jamrial
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-26 12:41:15 +01:00
Michael Niedermayer
7c210c4424 avformat/cache: Extend cache entries if possible instead of creating new ones
This reduces the number of cache entries and should significantly
reduce memory requirements

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-26 02:21:51 +01:00
Michael Niedermayer
312151bb9a avformat/cache: avoid lseek() on reading from the cache if possible
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-26 01:24:27 +01:00
Michael Niedermayer
ce3551896a avformat/cache: keep cache_pos updated
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-26 01:22:52 +01:00
Michael Niedermayer
954fc854f2 avformat/cache: cleanup cache file on cache write failure
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-26 01:13:49 +01:00
Michael Niedermayer
8706910c4c avformat/cache: Support user specified read-ahead for non seekable media
Fixes Ticket2406

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-25 22:09:24 +01:00
Michael Niedermayer
7018d3d351 avformat/cache: Use the correct io handle in seeking
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-25 22:07:32 +01:00
Michael Niedermayer
dedd3c89ae avformat/cache: more informative error message
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-25 22:07:32 +01:00
Michael Niedermayer
681559d3ff avformat/cache: remember EOF point if hit and use it to handle SEEK_END
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-25 22:07:23 +01:00
Michael Niedermayer
0c0168a210 avformat/cache: support non continuous caching
This allows using the cache protocol on top of seekable but slow protocols to
speed them up

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-25 19:20:55 +01:00
Michael Niedermayer
7dce91368f avformat/smoothstreamingenc: Use av_freep() avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-25 12:51:48 +01:00
Michael Niedermayer
443bd2715d avformat/wtvdec: Use av_freep() avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-25 12:51:48 +01:00
Michael Niedermayer
68fa549230 avformat/segment: Use av_freep() avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-25 12:51:48 +01:00
Michael Niedermayer
96dce6f7ce avformat/seek: move the cur variable into the loop
This improves readability and makes it clear that the freed
value is not used after the end of an iteration

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-24 13:14:07 +01:00
Michael Niedermayer
3f56224a9a avformat/rtpdec_mpeg4: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-24 13:14:07 +01:00
Michael Niedermayer
ef05af82b2 avformat/rtpproto: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-24 13:14:07 +01:00
Michael Niedermayer
82d1abc44c avformat/seek: use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-24 13:14:07 +01:00
Michael Niedermayer
e01467241f avformat/aea: reduce false positives in probing
Fixes probetest failure

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-23 18:41:53 +01:00
Michael Niedermayer
0d7a14e236 avformat/avidec: optimize probe
about 2x as fast

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-23 16:32:26 +01:00
Michael Niedermayer
f7f4a90174 avformat/rtpdec: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-23 15:35:07 +01:00
Michael Niedermayer
bb858e67e5 avformat/rtpdec_latm: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-23 15:34:29 +01:00
Michael Niedermayer
ba8d2c90cd avformat/rtpdec_xiph: use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-23 15:33:57 +01:00
Piotr Bandurski
75cc85b239 cdxl: fix duration
fixes ticket #1937

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-22 19:49:02 +01:00
Michael Niedermayer
03b84f2fb2 avformat/rtmpproto: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-22 12:03:36 +01:00
Michael Niedermayer
fd3e7447c8 avformat/riffdec: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-22 12:03:35 +01:00
Michael Niedermayer
5dfae3f40a avformat/os_support: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-22 12:03:34 +01:00
Michael Niedermayer
41ee459e88 avformat/img2dec: check w/h in dpx_probe
Fixes probetest failure

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-21 23:32:57 +01:00
Michael Niedermayer
b7e506b3b9 avformat/swfdec: Check frame size rectangle in probe()
fixes probetest failure

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-21 21:10:20 +01:00
Michael Niedermayer
f7a4589b36 avformat/mpegtsenc: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-21 19:25:17 +01:00
Michael Niedermayer
47b9481d9d avformat/mpegenc: Use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-21 19:24:11 +01:00
Michael Niedermayer
5318cf521f Merge commit '9cfa68c560bdec82d2d5ec079f9c5b0f9ca37af0'
* commit '9cfa68c560bdec82d2d5ec079f9c5b0f9ca37af0':
  mpegts: add support for Opus

Conflicts:
	libavcodec/opus_parser.c
	libavformat/mpegts.c

See: 74141f693d
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 19:15:11 +01:00
Michael Niedermayer
8db0c2ffe6 avformat/mmst: Use av_freep() avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 16:54:25 +01:00
Michael Niedermayer
bcd4447173 avformat/http: Use av_freep() avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 16:53:37 +01:00
Michael Niedermayer
081913aec5 avformat/id3v2: Use av_freep() avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 16:53:14 +01:00
Kieran Kunhya
9cfa68c560 mpegts: add support for Opus
Signed-off-by: Anton Khirnov <anton@khirnov.net>
2014-12-20 11:29:19 +01:00
Michael Niedermayer
1728659319 avformat/westwood_aud: replace != 0 error check by <0
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 01:51:16 +01:00
Michael Niedermayer
4b45aa517c avformat/asfenc: replace != 0 error check by <0
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 01:48:26 +01:00
Michael Niedermayer
3d6545d51e Merge commit '8ebf02f8f530240edf7e45f35f7647ef9dd44a58'
* commit '8ebf02f8f530240edf7e45f35f7647ef9dd44a58':
  libavformat: Only use MoveFileExA when targeting the desktop API subset

Conflicts:
	configure

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 00:49:47 +01:00
Michael Niedermayer
a701a9cff4 Merge commit 'fc308b30bb24e623fed042ec78b10803b2362a18'
* commit 'fc308b30bb24e623fed042ec78b10803b2362a18':
  rtpenc_mpegts: Call write_trailer for the mpegts muxer even if no output buffer exists

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 00:42:07 +01:00
Michael Niedermayer
6b0f54ddc7 Merge commit 'e2ce16392205d8efe9143329ed3fb5fcb15498fa'
* commit 'e2ce16392205d8efe9143329ed3fb5fcb15498fa':
  mpegts: Support running the write_trailer function without an AVIOContext

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-20 00:33:40 +01:00
Clément Bœsch
edbbb11488 avformat/rsd: make tag_buf string larger
av_get_codec_tag_string() uses more that 1 char for unprintable characters.
2014-12-20 00:17:43 +01:00
Clément Bœsch
d60fb4f794 avformat/apngdec: make tag_buf string larger
av_get_codec_tag_string() uses more that 1 char for unprintable characters.
2014-12-20 00:17:21 +01:00
Clément Bœsch
83b0fe395b avformat/wavdec: make start_code string larger
av_get_codec_tag_string() uses more that 1 char for unprintable characters.
2014-12-19 23:57:39 +01:00
Thomas Volkert
e8d57e4163 wavdec: avoid output of arbitrary chars
use av_get_codec_tag_string() in wav_read_header() for printing the
faulty start code from riff header

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 23:43:58 +01:00
Thomas Volkert
1a971d33eb wavdec: refactor wav_read_header()
Make it more readable and display an error message in case an invalid
header is detected (the current version just returns
AVERROR_INVALIDDATA)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 22:39:29 +01:00
Martin Storsjö
8ebf02f8f5 libavformat: Only use MoveFileExA when targeting the desktop API subset
The MoveFileExA is available in the headers regardless which API
subset is targeted, but it is missing in the Windows Phone link
libraries. When targeting Windows Store apps, the function is
available both in the headers and in the link libraries, and thus
there is no indication for the build system that this function
should be avoided - such an indication is only given by the
Windows App Certification Kit, which forbids using the MoveFileExA
function.

Therefore check the WINAPI_FAMILY defines instead, to figure out
which API subset is targeted.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-19 23:24:47 +02:00
Martin Storsjö
fc308b30bb rtpenc_mpegts: Call write_trailer for the mpegts muxer even if no output buffer exists
Since the mpegts muxer now can handle being called with a NULL
AVIOContext, we don't need to try to allocate one before calling
write_trailer.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-19 23:14:45 +02:00
Martin Storsjö
e2ce163922 mpegts: Support running the write_trailer function without an AVIOContext
If opening and closing dynamic buffers as AVIOContext, we may
not have any AVIOContext available when wanting to close and
deallocate the muxer. Allow calling write_trailer despite this.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-19 23:13:04 +02:00
Martin Storsjö
4895aa65c6 libavformat: Allow calling av_write_trailer with a NULL AVIOContext
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-19 23:12:58 +02:00
Michael Niedermayer
649c158e8c Add FFMPEG_VERSION into the binary libs
This simplifies identifying from which revision a binary of a lib came from

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 19:32:40 +01:00
Michael Niedermayer
869b56cae6 avformat/mpegenc: replace always enabled asserts by av_assert0()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 15:18:31 +01:00
Carl Eugen Hoyos
96ff6d3805 lavf/rtp_h261: Replace restrict with av_restrict.
Fixes compilation on Windows.
2014-12-19 13:25:51 +01:00
Michael Niedermayer
24af050c2f Merge commit '64f7575fbd64e5b65d5c644347408588c776f1fe'
* commit '64f7575fbd64e5b65d5c644347408588c776f1fe':
  mov: avoid a memleak when multiple stss boxes are present

Conflicts:
	libavformat/mov.c

See: 5ab882d728
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 12:31:52 +01:00
Anton Khirnov
64f7575fbd mov: avoid a memleak when multiple stss boxes are present
CC: libav-stable@libav.org
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
2014-12-19 08:01:46 +01:00
Michael Niedermayer
bf6e332cb4 Merge commit '76ccf114a6c107218e2a1948afc1d0fb3ac7ba0b'
* commit '76ccf114a6c107218e2a1948afc1d0fb3ac7ba0b':
  rtsp: check ffurl_get_file_handle() return value

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 05:04:24 +01:00
Michael Niedermayer
988d27b802 Merge commit 'b1306823d0b3ae998c8e10ad832004eb13bdd93e'
* commit 'b1306823d0b3ae998c8e10ad832004eb13bdd93e':
  check memory errors from av_strdup()

Conflicts:
	avprobe.c
	libavformat/matroskaenc.c
	libavutil/opt.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 04:57:25 +01:00
Michael Niedermayer
6781ec6714 Merge commit '8b263331c5ebbb10b6ea521e9fd56751ba94254b'
* commit '8b263331c5ebbb10b6ea521e9fd56751ba94254b':
  mpegts: check get16() return value

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 04:43:41 +01:00
Michael Niedermayer
5a1cd796e2 Merge commit '430a8168594b3cb29f44141d4da88f2c642de06f'
* commit '430a8168594b3cb29f44141d4da88f2c642de06f':
  oggdec: add support for VP8 demuxing

Conflicts:
	Changelog
	libavformat/oggparsevp8.c
	libavformat/version.h

See: d890db5f53
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 04:36:45 +01:00
Michael Niedermayer
c8e05c438f Merge commit '59f0275dd0a42a7f90271a83a78e9ca5e69ff5b0'
* commit '59f0275dd0a42a7f90271a83a78e9ca5e69ff5b0':
  movenc: Adjust the pts of new fragments similarly to what is done for dts

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 02:58:16 +01:00
Michael Niedermayer
7ef515cda5 Merge commit '8a70ef94b9c377293b3dfa7d92cdc81a4fe1543a'
* commit '8a70ef94b9c377293b3dfa7d92cdc81a4fe1543a':
  libavformat: Add a muxer wrapping mpegts encoding into RTP

Conflicts:
	Changelog
	libavformat/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 02:49:36 +01:00
Michael Niedermayer
5162af67f4 Merge commit 'a505c0d7373336a4cc5aa2022111c46bdd388b1f'
* commit 'a505c0d7373336a4cc5aa2022111c46bdd388b1f':
  rtp: Initial H.261 support

Conflicts:
	Changelog
	libavformat/rtpdec_h261.c
	libavformat/rtpenc_h261.c
	libavformat/sdp.c
	libavformat/version.h

See: 50a4d5cfc6
Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 02:34:17 +01:00
Michael Niedermayer
3f5d1c8130 Merge commit 'adc214e6797750285a5e62634b8521db521162ad'
* commit 'adc214e6797750285a5e62634b8521db521162ad':
  rtpenc: Avoid brittle switch fallthroughs

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-19 02:24:24 +01:00
Vittorio Giovara
76ccf114a6 rtsp: check ffurl_get_file_handle() return value
CC: libav-stable@libav.org
Bug-Id: CID 717844
2014-12-18 23:27:14 +01:00
Vittorio Giovara
b1306823d0 check memory errors from av_strdup() 2014-12-18 23:27:14 +01:00
Vittorio Giovara
8b263331c5 mpegts: check get16() return value
And break flow of execution rather than exiting the function.

CC: libav-stable@libav.org
Bug-Id: CID 732186
2014-12-18 23:27:13 +01:00
James Almer
430a816859 oggdec: add support for VP8 demuxing
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
2014-12-18 23:27:07 +01:00
Martin Storsjö
59f0275dd0 movenc: Adjust the pts of new fragments similarly to what is done for dts
The pts and the corresponding duration is written in sidx
atoms, thus make sure these match up correctly.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 23:14:27 +02:00
Martin Storsjö
8a70ef94b9 libavformat: Add a muxer wrapping mpegts encoding into RTP
Since this structurally is quite different from normal RTP
(multiple streams are muxed into one single mpegts stream,
which is packetized into one single RTP session), it is kept
as a separate muxer.

Since this structurally also behaves differently than normal
RTP, all of the other muxers that do chained RTP muxing
(rtsp, sap, mp4) would need to be updated similarly to handle
this - in particular, creating one single rtp_mpegts muxer
for the whole presentation instead of one rtp muxer per stream.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 23:12:33 +02:00
Thomas Volkert
a505c0d737 rtp: Initial H.261 support
The packetizer only supports splitting at GOB headers - if
such aren't available frequently enough, it splits at any
random byte offset (not at a macroblock boundary either, which
would be allowed by the spec) and sends a payload header pretend
that it starts with a GOB header.

As long as a receiver doesn't try to handle such cases cleverly
but just drops broken frames, this shouldn't matter too much
in practice.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 23:11:37 +02:00
Martin Storsjö
adc214e679 rtpenc: Avoid brittle switch fallthroughs
Instead explicitly jump to the default case in the cases where
it is wanted, and avoid fallthrough between different codecs,
which could easily introduce bugs if people editing the code
aren't careful.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 23:11:37 +02:00
Michael Niedermayer
5d97af0cb2 Merge commit 'df07c07b3de0a5e8890078944de1eb5cb8372ef8'
* commit 'df07c07b3de0a5e8890078944de1eb5cb8372ef8':
  rtpdec_h263_rfc2190: Clear the stored bits if discarding buffered data

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-18 20:40:39 +01:00
Michael Niedermayer
7c0ab0a3b8 Merge commit '42181740a3972e17d0097d28fabc9a1a60322d47'
* commit '42181740a3972e17d0097d28fabc9a1a60322d47':
  rtpenc: Set the AVFMT_TS_NONSTRICT flag

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-18 20:30:12 +01:00
Michael Niedermayer
c0586b257d Merge commit '01f251c44d83eedc819625d2caac9ff9697a085d'
* commit '01f251c44d83eedc819625d2caac9ff9697a085d':
  rtpenc: Set the timestamp properly when sending mpegts data, too

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-18 20:22:47 +01:00
Michael Niedermayer
4d5ca069c7 Merge commit 'f2c614e8c4a935b52bbf86819128d9e797230c20'
* commit 'f2c614e8c4a935b52bbf86819128d9e797230c20':
  srtpproto: fix option flag type

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-18 19:59:03 +01:00
Martin Storsjö
df07c07b3d rtpdec_h263_rfc2190: Clear the stored bits if discarding buffered data
If we throw away the buffered incomplete frame, make sure to also
throw away the buffered bits of an incomplete byte at the same
time.

CC: libav-stable@libav.org
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 11:59:54 +02:00
Martin Storsjö
42181740a3 rtpenc: Set the AVFMT_TS_NONSTRICT flag
In particular, when packetizing mpegts into rtp, the input packet
timestamp may come from more than one stream, which could cause
multiple packets be written with the same timestamp.

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 11:59:19 +02:00
Martin Storsjö
01f251c44d rtpenc: Set the timestamp properly when sending mpegts data, too
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 11:59:12 +02:00
Tristan Matthews
f2c614e8c4 srtpproto: fix option flag type
Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-18 11:58:23 +02:00
Thomas Volkert
00d7555f34 wavdec: RIFX file format support
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-18 00:10:35 +01:00
Michael Niedermayer
973684a4fb Merge commit '456e93bfdd4cbc5e995dea415019abd0703d0e16'
* commit '456e93bfdd4cbc5e995dea415019abd0703d0e16':
  dashenc: Adjust the start time of a segment to the end of the previous segment

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-17 12:05:00 +01:00
Michael Niedermayer
b32cb08b7f Merge commit '2f628d5943c12389c07d652d23d3916997f9f0f6'
* commit '2f628d5943c12389c07d652d23d3916997f9f0f6':
  dashenc: Write segment timelines properly if the timeline has gaps

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-17 11:57:09 +01:00
Martin Storsjö
456e93bfdd dashenc: Adjust the start time of a segment to the end of the previous segment
This is the same adjustment that the mp4 muxer does to the start
timestamp of fragments, since the timestamp of a sample in an mp4
file is implicit from the sum of earlier sample durations.

This avoids gaps in the timeline (which can stop dash.js from
playing it back), and makes sure the timestamp on the segmenter
level matches what the mp4 muxer actually writes into the segments.

This is only an issue if the AVPacket duration of the last
packet of a segment doesn't point to the actual start timestamp
of the next packet (the first in the next segment).

Signed-off-by: Martin Storsjö <martin@martin.st>
2014-12-17 09:43:08 +02:00