• Bela Bodecs's avatar
    avformat/hlsenc: fix handling of delete_segments when %v is present · 9825f77a
    Bela Bodecs authored
    When var_stream_map option is used, %v must appear either in segment
    name template or in the directory path. This latter case currently is
    not handled and delete_segments flag of hls_flags is broken now. This
    patch fix this. The root cause of the bug was that HLSSegment struct
    only stores the final filename part, but not the final directory path.
    Most of the cases, final path info is unneded, It only necessary when
    you want to delete old segments (e.g in case of live streaming).
    Without variant streams it was unnecessary to store the final directory
    path, because all segment were stored into the same directory. But
    introducing %v in directory names either require to store the final
    directory path into HLSSegment or associate segments with their variant
    streams to be able deleting them later. I have choosen the second
    solution and introduced a variant index data member into the segment
    struct.
    Signed-off-by: 's avatarBela Bodecs <bodecsb@vivanet.hu>
    Signed-off-by: 's avatarSteven Liu <lq@onvideo.cn>
    9825f77a
Name
Last commit
Last update
compat Loading commit data...
doc Loading commit data...
ffbuild Loading commit data...
fftools Loading commit data...
libavcodec Loading commit data...
libavdevice Loading commit data...
libavfilter Loading commit data...
libavformat Loading commit data...
libavresample Loading commit data...
libavutil Loading commit data...
libpostproc Loading commit data...
libswresample Loading commit data...
libswscale Loading commit data...
presets Loading commit data...
tests Loading commit data...
tools Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.travis.yml Loading commit data...
CONTRIBUTING.md Loading commit data...
COPYING.GPLv2 Loading commit data...
COPYING.GPLv3 Loading commit data...
COPYING.LGPLv2.1 Loading commit data...
COPYING.LGPLv3 Loading commit data...
CREDITS Loading commit data...
Changelog Loading commit data...
INSTALL.md Loading commit data...
LICENSE.md Loading commit data...
MAINTAINERS Loading commit data...
Makefile Loading commit data...
README.md Loading commit data...
RELEASE Loading commit data...
configure Loading commit data...