summaryrefslogtreecommitdiff
path: root/libavformat/dashenc.c
Commit message (Collapse)AuthorAge
* avformat/dashenc: use a quieter log lever when informing prft was ↵James Almer2020-02-26
| | | | | | | automatically enabled Suggested-by: Anton Khirnov <anton@khirnov.net> Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: always attempt to enable prft in ldash modeJames Almer2020-02-22
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: write a capture time Producer Reference Time element when ↵James Almer2020-02-22
| | | | | | | | none is provided by the encoder This way, the element will be present in any scenario when the write_prft option is used. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: write the styp box when the first frame of a segment is readyJames Almer2020-02-22
| | | | | | | This ensures it's written at the beginning of a segment in non streaming mode when segment duration differs from fragment duration. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: warn if Producer Reference Time element option is missing ↵James Almer2020-02-17
| | | | | | when ldash mode is used Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: disable Resync elements when using DVB-DASH profileJames Almer2020-02-17
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: always set coding_dependency to 1 if a parser isn't usedJames Almer2020-02-16
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: include an availabilityTimeComplete element in all ↵James Almer2020-02-16
| | | | | | | | | streaming modes It's not exclusive for Low Latency streaming. The muxer will serve partial segments regardless of streaming mode. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: add Trick Mode support for AdaptationSetsJames Almer2020-02-16
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: make AdaptationSet id an integer valueJames Almer2020-02-16
| | | | | | | Unlike Representation id, it's defined as an integer in the spec, and not as a string. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: use AV_OPT_TYPE_DICT for http_optsMarton Balint2020-02-03
| | | | | | | | This changes the separator character from comma to colon, but since this option was only added recently I think it should be done for consistency with other similar options. Signed-off-by: Marton Balint <cus@passwd.hu>
* dashenc: check pts to prevent division by zero errorAlfred E. Heggestad2020-01-31
| | | | | | | | | | | | | | | | | | this usecase will cause a division by zero trap: 1. dashenc has received one frame 2. os->max_pts and os->start_pts have same value 3. delta between max_pts and start_pts is 0 4. av_rescale_q(0, x, y) returns 0 5. this value is used as denominator in division 6. Bang! -> segfault this fix checks that max_pts > start_pts. the fix has been tested and works. Signed-off-by: Alfred E. Heggestad <alfred.heggestad@gmail.com> Reviewed-by: Jeyapal, Karthick <kjeyapal@akamai.com> Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: use ff_rename instead of avpriv_io_moveMarton Balint2020-01-19
| | | | | | ff_rename always logs the error message. Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/dashenc: add an option to write a Latency elementJames Almer2020-01-15
| | | | | | | Allows to set an intended target latency while streaming that clients can use to measure when using low latency mode. Signed-off-by: James Almer <jamrial@gmail.com>
* dashenc: support setting arbitrary HTTP protocol optionsAnton Khirnov2020-01-15
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: allow setting custom movflags using format_optionsJames Almer2020-01-15
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: implement DVB-DASH profileJames Almer2020-01-15
| | | | | | | Add new required elements and constrain presence and values for existing ones based on the spec. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: add an option to enable low latency Dash manifestJames Almer2020-01-15
| | | | | | | In combination with the streaming option it constrains the value of a few elements, to prevet clients from buffering too much data before starting presentation. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: Write a Producer Reference Time elementJames Almer2020-01-15
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: allow splitting fragments following P-Frame reorderingJames Almer2020-01-15
| | | | Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: allow setting fragment durationsJames Almer2020-01-15
| | | | | | | | Implemented as as a frag_duration muxer option and key=value entry in the adaptation_sets muxer option. It has the same syntax as the seg_duration option. A new frag_type option is also introduced to select the kind of fragmentation. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: allow setting segment durations per AdaptationSetJames Almer2020-01-15
| | | | | | | | | Implemented as as a seg_duration key=value entry in the adaptation_sets muxer option. It has the same syntax as the global seg_duration option, and has precedence over it if set. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: Fix leak of AVFormatContext on errorAndreas Rheinhardt2020-01-08
| | | | | | | | | | | The Dash muxer uses submuxers and when one such submuxer has been allocated, it is initially only stored in a temporary variable. Therefore it leaks if an error happens between the allocation and storing it permanently. This commit changes this. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> Reviewed-by: "Jeyapal, Karthick" <kjeyapal@akamai.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/dashenc: use AV_OPT_TYPE_DICT for format_optionsMarton Balint2020-01-01
| | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* avformat/dashenc: remove unused check of avformat_free_contextSteven Liu2019-12-02
| | | | | | | Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Reviewed-by: Jun Zhao <barryjzhao@tencent.com> Reviewed-by: Jeyapal, Karthick <kjeyapal@akamai.com> Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/dashenc: fix writing the AV1 codec string in mp4 modeJames Almer2019-08-03
| | | | | | | | | | From https://aomediacodec.github.io/av1-isobmff/#codecsparam, the parameters sample entry 4CC, profile, level, tier, and bitDepth are all mandatory fields. All the other fields are optional, mutually inclusive (all or none). Fixes ticket #8049 Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: update stream extradata from packet side dataJames Almer2019-08-03
| | | | | | | | | codecpar->extradata is not going to change between packets. New extradata is instead propagated using packet side data. Use ff_alloc_extradata() as well. Signed-off-by: James Almer <jamrial@gmail.com>
* avformat/dashenc: add descriptor which is useful to the scheme defined by ↵Leo Zhang2019-07-22
| | | | | | ISO/IEC 23009-1:2014/Amd.2:2015. Signed-off-by: leozhang <leozhang@qiyi.com>
* avformat/dashenc: split extension for MP4 into .mp4 or .m4sAlfred E. Heggestad2019-06-25
|
* avformat/hlsenc: add EXT-X-I-FRAMES-ONLY tag supportSteven Liu2019-06-14
| | | | Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/dashenc: use 64bit for handling the return of avio_tell()Michael Niedermayer2019-05-17
| | | | | | | The return code is 64bit, so this is more correct, especially in case it actually would be a file of such large size Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
* avformat/dashenc: Fix a bug with writing "final" manifestKarthick J2019-04-22
| | | | This bug was introduced in the commit 951561b64ee6c11f01daedd9dcf73276cc1e765b
* avformat/dashenc: Disable streaming for webm outputKarthick J2019-04-16
| | | | | Currently streaming for webm output doesn't work. Disabling explicitly will make sure that the manifest will get generated correctly.
* libavformat/dashenc : Prevent writing manifest files multiple timesjoepadmiraal2019-04-10
|
* avformat/dashenc: Add support for Global SIDXKarthick J2019-04-02
|
* avformat/dashenc: Added #EXT-X-PROGRAM-DATE-TIME to HLS playlistsjoepadmiraal2019-03-06
|
* avformat/dashenc: Added commentsKarthick J2019-02-25
| | | | Added comments regarding usage of certain movflags in streaming mode.
* avformat/dashenc: Added option to repeatedly publish master playlistKarthick J2019-02-25
| | | | The master playlist can be published at a specified interval with this option
* avformat/hlsenc: add var_stream_map LANGUAGE field string parameterSteven Liu2019-01-31
| | | | | | | | | | | | | | | | | | | | | use a:0,agroup:aud_low,default:Yes,language:CHN a:1,agroup:aud_low,language:ENG a:2,agroup:aud_high,default:YesYes,language:CHN a:3,agroup:aud_high,language:ENG v:0,agroup:aud_low v:1,agroup:aud_high create master m3u8 list. result: EXTM3U EXT-X-VERSION:3 EXT-X-MEDIA:TYPE=AUDIO,GROUP-ID="group_aud_low",NAME="audio_0",DEFAULT=YES,LANGUAGE="CHN",URI="out_0.m3u8" EXT-X-MEDIA:TYPE=AUDIO,GROUP-ID="group_aud_low",NAME="audio_1",DEFAULT=NO,LANGUAGE="ENG",URI="out_1.m3u8" EXT-X-MEDIA:TYPE=AUDIO,GROUP-ID="group_aud_high",NAME="audio_2",DEFAULT=YES,LANGUAGE="CHN",URI="out_2.m3u8" EXT-X-MEDIA:TYPE=AUDIO,GROUP-ID="group_aud_high",NAME="audio_3",DEFAULT=NO,LANGUAGE="ENG",URI="out_3.m3u8" EXT-X-STREAM-INF:BANDWIDTH=1170400,RESOLUTION=640x480,CODECS="avc1.64001e,mp4a.40.2",AUDIO="group_aud_low" out_4.m3u8 EXT-X-STREAM-INF:BANDWIDTH=3440800,RESOLUTION=640x480,CODECS="avc1.64001e,mp4a.40.2",AUDIO="group_aud_high" out_5.m3u8 Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
* avformat/dashenc: Skip writing trailer for MP4 output when in streaming modeKarthick J2019-01-28
| | | | In streaming mode mp4 trailer is not required for playout.
* avformat/dashenc: Format xs:datetime in millisecond precisionKarthick J2019-01-21
| | | | For low latency streaming even milliseconds matter!
* avformat/dashenc: Added support for Low-latency HLS(Experimental)kjeyapal@akamai.com2018-12-17
| | | | | | | Apple doesn't have an official spec for LHLS. Meanwhile hls.js player folks are trying to standardize a open LHLS spec. The draft spec is available in https://github.com/video-dev/hlsjs-rfcs/blob/lhls-spec/proposals/0001-lhls.md This option will also try to comply with the above open spec, till Apple's spec officially supports it. Applicable only when @var{streaming} and @var{hls_playlist} options are enabled.
* avformat/dashenc : Refactored HLS media playlist related codekjeyapal@akamai.com2018-12-17
| | | | Made it as a separate function, so that it could be reused (in future)
* avformat/dashenc: Used the movenc option skip_sidx instead of global_sidxkjeyapal@akamai.com2018-12-11
| | | | Anyways the intended behaviour was to disable SIDX atom.
* lavf/dashenc: Write media trailers when DASH trailer is written.Andrey Semashev2018-12-04
| | | | | | | This commit ensures that all (potentially, long) filesystem activity is performed when the user calls av_write_trailer on the DASH libavformat context, not when freeing the context. Also, this defers media segment deletion until after the media trailers are written.
* Revert "lavf/dashenc: Write media trailers when DASH trailer is written."Karthick J2018-12-03
| | | | | This reverts commit e444b3b184f36e3c97bb3489822f6b05ccb848a8. Causing build error due to rebasing. Sorry for about it.
* lavf/dashenc: Use avpriv_io_delete to delete files.Andrey Semashev2018-12-03
| | | | | This fixes incorrect handling of file pseudo-URIs (i.e. when the filename starts with "file:").
* lavf/dashenc: Write media trailers when DASH trailer is written.Andrey Semashev2018-12-03
| | | | | | | This commit ensures that all (potentially, long) filesystem activity is performed when the user calls av_write_trailer on the DASH libavformat context, not when freeing the context. Also, this defers media segment deletion until after the media trailers are written.
* avformat/dashenc: Added proper logging when io_open fails for writeKarthick J2018-12-03
|
* avformat/dashenc: Added an option to ignore io errorskjeyapal@akamai.com2018-12-02
| | | | | When dashenc has to run for long duration(say 24x7 live stream), one can enable this option to ignore the io failure of few segment's upload due to an intermittent network issues. When the network connection recovers dashenc will continue with the upload of the current segments, leading to the recovery of the stream.