|
|
@ -589,6 +589,20 @@ This example will produce the playlists segment file sets: |
|
|
|
@file{file_0_000.ts}, @file{file_0_001.ts}, @file{file_0_002.ts}, etc. and |
|
|
|
@file{file_0_000.ts}, @file{file_0_001.ts}, @file{file_0_002.ts}, etc. and |
|
|
|
@file{file_1_000.ts}, @file{file_1_001.ts}, @file{file_1_002.ts}, etc. |
|
|
|
@file{file_1_000.ts}, @file{file_1_001.ts}, @file{file_1_002.ts}, etc. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The string "%v" may be present in the filename or in the last directory name |
|
|
|
|
|
|
|
containing the file. If the string is present in the directory name, then |
|
|
|
|
|
|
|
sub-directories are created after expanding the directory name pattern. This |
|
|
|
|
|
|
|
enables creation of segments corresponding to different variant streams in |
|
|
|
|
|
|
|
subdirectories. |
|
|
|
|
|
|
|
@example |
|
|
|
|
|
|
|
ffmpeg -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \ |
|
|
|
|
|
|
|
-map 0:v -map 0:a -map 0:v -map 0:a -f hls -var_stream_map "v:0,a:0 v:1,a:1" \ |
|
|
|
|
|
|
|
-hls_segment_filename 'vs%v/file_%03d.ts' vs%v/out.m3u8 |
|
|
|
|
|
|
|
@end example |
|
|
|
|
|
|
|
This example will produce the playlists segment file sets: |
|
|
|
|
|
|
|
@file{vs0/file_000.ts}, @file{vs0/file_001.ts}, @file{vs0/file_002.ts}, etc. and |
|
|
|
|
|
|
|
@file{vs1/file_000.ts}, @file{vs1/file_001.ts}, @file{vs1/file_002.ts}, etc. |
|
|
|
|
|
|
|
|
|
|
|
@item use_localtime |
|
|
|
@item use_localtime |
|
|
|
Use strftime() on @var{filename} to expand the segment filename with localtime. |
|
|
|
Use strftime() on @var{filename} to expand the segment filename with localtime. |
|
|
|
The segment number is also available in this mode, but to use it, you need to specify second_level_segment_index |
|
|
|
The segment number is also available in this mode, but to use it, you need to specify second_level_segment_index |
|
|
@ -717,6 +731,11 @@ set filename to the fragment files header file, default filename is @file{init.m |
|
|
|
When @code{var_stream_map} is set with two or more variant streams, the |
|
|
|
When @code{var_stream_map} is set with two or more variant streams, the |
|
|
|
@var{filename} pattern must contain the string "%v", this string specifies |
|
|
|
@var{filename} pattern must contain the string "%v", this string specifies |
|
|
|
the position of variant stream index in the generated init file names. |
|
|
|
the position of variant stream index in the generated init file names. |
|
|
|
|
|
|
|
The string "%v" may be present in the filename or in the last directory name |
|
|
|
|
|
|
|
containing the file. If the string is present in the directory name, then |
|
|
|
|
|
|
|
sub-directories are created after expanding the directory name pattern. This |
|
|
|
|
|
|
|
enables creation of init files corresponding to different variant streams in |
|
|
|
|
|
|
|
subdirectories. |
|
|
|
|
|
|
|
|
|
|
|
@item hls_flags @var{flags} |
|
|
|
@item hls_flags @var{flags} |
|
|
|
Possible values: |
|
|
|
Possible values: |
|
|
@ -833,7 +852,11 @@ Allowed values are 0 to 9 (limited just based on practical usage). |
|
|
|
|
|
|
|
|
|
|
|
When there are two or more variant streams, the output filename pattern must |
|
|
|
When there are two or more variant streams, the output filename pattern must |
|
|
|
contain the string "%v", this string specifies the position of variant stream |
|
|
|
contain the string "%v", this string specifies the position of variant stream |
|
|
|
index in the output media playlist filenames. |
|
|
|
index in the output media playlist filenames. The string "%v" may be present in |
|
|
|
|
|
|
|
the filename or in the last directory name containing the file. If the string is |
|
|
|
|
|
|
|
present in the directory name, then sub-directories are created after expanding |
|
|
|
|
|
|
|
the directory name pattern. This enables creation of variant streams in |
|
|
|
|
|
|
|
subdirectories. |
|
|
|
|
|
|
|
|
|
|
|
@example |
|
|
|
@example |
|
|
|
ffmpeg -re -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \ |
|
|
|
ffmpeg -re -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \ |
|
|
@ -856,6 +879,14 @@ be an audio only stream with bitrate 64k and the third variant stream will be a |
|
|
|
video only stream with bitrate 256k. Here, three media playlist with file names |
|
|
|
video only stream with bitrate 256k. Here, three media playlist with file names |
|
|
|
out_0.m3u8, out_1.m3u8 and out_2.m3u8 will be created. |
|
|
|
out_0.m3u8, out_1.m3u8 and out_2.m3u8 will be created. |
|
|
|
@example |
|
|
|
@example |
|
|
|
|
|
|
|
ffmpeg -re -i in.ts -b:v:0 1000k -b:v:1 256k -b:a:0 64k -b:a:1 32k \ |
|
|
|
|
|
|
|
-map 0:v -map 0:a -map 0:v -map 0:a -f hls -var_stream_map "v:0,a:0 v:1,a:1" \ |
|
|
|
|
|
|
|
http://example.com/live/vs_%v/out.m3u8 |
|
|
|
|
|
|
|
@end example |
|
|
|
|
|
|
|
This example creates the variant streams in subdirectories. Here, the first |
|
|
|
|
|
|
|
media playlist is created at @file{http://example.com/live/vs_0/out.m3u8} and |
|
|
|
|
|
|
|
the second one at @file{http://example.com/live/vs_1/out.m3u8}. |
|
|
|
|
|
|
|
@example |
|
|
|
ffmpeg -re -i in.ts -b:a:0 32k -b:a:1 64k -b:v:0 1000k -b:v:1 3000k \ |
|
|
|
ffmpeg -re -i in.ts -b:a:0 32k -b:a:1 64k -b:v:0 1000k -b:v:1 3000k \ |
|
|
|
-map 0:a -map 0:a -map 0:v -map 0:v -f hls \ |
|
|
|
-map 0:a -map 0:a -map 0:v -map 0:v -f hls \ |
|
|
|
-var_stream_map "a:0,agroup:aud_low a:1,agroup:aud_high v:0,agroup:aud_low v:1,agroup:aud_high" \ |
|
|
|
-var_stream_map "a:0,agroup:aud_low a:1,agroup:aud_high v:0,agroup:aud_low v:1,agroup:aud_high" \ |
|
|
|