[FFmpeg-trac] #8733(undetermined:new): hls segments list repeated names

FFmpeg trac at avcodec.org
Sat Jun 13 17:47:14 EEST 2020


#8733: hls segments list repeated names
-------------------------------------+-------------------------------------
             Reporter:  krs_vital    |                    Owner:
                 Type:  defect       |                   Status:  new
             Priority:  normal       |                Component:
                                     |  undetermined
              Version:  unspecified  |               Resolution:
             Keywords:               |               Blocked By:
             Blocking:               |  Reproduced by developer:  0
Analyzed by developer:  0            |
-------------------------------------+-------------------------------------

Comment (by stevenliu):

 {{{
 liuqideMacBook-Pro:dash liuqi$ printf %01d\\n 100
 100
 liuqideMacBook-Pro:dash liuqi$
 liuqideMacBook-Pro:dash liuqi$ vim test.c
 Press ENTER or type command to continue
 liuqideMacBook-Pro:dash liuqi$ gcc test.c -o out
 liuqideMacBook-Pro:dash liuqi$ ./out
 30
 liuqideMacBook-Pro:dash liuqi$ cat test.c
 #include <stdio.h>

 int main(int argc, char *argv[])
 {

     printf("%0001d\n", 30);
     return 0;
 }
 liuqideMacBook-Pro:dash liuqi$
 }}}

 Sorry, i cannot understand what you want to do, but the document about the
 %0nd discribe is bellow:

 man printf
 {{{
 Zero or more of the following flags:

              #       A `#' character specifying that the value should be
 printed in an ``alternate form''.  For b, c, d, s and u formats, this
 option has no effect.  For the o formats the precision of the number is
                      increased to force the first character of the output
 string to a zero.  For the x (X) format, a non-zero result has the string
 0x (0X) prepended to it.  For a, A, e, E, f, F, g and G formats,
                      the result will always contain a decimal point, even
 if no digits follow the point (normally, a decimal point only appears in
 the results of those formats if a digit follows the decimal point).
                      For g and G formats, trailing zeros are not removed
 from the result as they would otherwise be;

              -       A minus sign `-' which specifies left adjustment of
 the output in the indicated field;

              +       A `+' character specifying that there should always
 be a sign placed before the number when using signed formats.

              ` '     A space specifying that a blank should be left before
 a positive number for a signed format.  A `+' overrides a space if both
 are used;

              0       A zero `0' character indicating that zero-padding
 should be used rather than blank-padding.  A `-' overrides a `0' if both
 are used;
 }}}


 but i don't think only repeat the last segment is a good idea,
 because:
 ffmpeg make the segment list, seg0.ts, seg1.ts, seg2.ts ... when rollback
 or repeat the last segment, for example seg9.ts, how many seconds should
 the CDN cache the segments?
 this i why deprecated the hls_wrap and use the hls_list_sise to controll
 the length of the hls list. because the CDN can cache the files enough
 long time.

--
Ticket URL: <https://trac.ffmpeg.org/ticket/8733#comment:7>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list