Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
f848d384
Commit
f848d384
authored
Oct 18, 2018
by
kjeyapal@akamai.com
Committed by
Karthick J
Oct 21, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avformat/dashenc: Support HTTP Persistent for master.m3u8 as well
parent
0939c33b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
dashenc.c
libavformat/dashenc.c
+6
-5
No files found.
libavformat/dashenc.c
View file @
f848d384
...
...
@@ -878,14 +878,14 @@ static int write_manifest(AVFormatContext *s, int final)
snprintf
(
temp_filename
,
sizeof
(
temp_filename
),
use_rename
?
"%s.tmp"
:
"%s"
,
filename_hls
);
set_http_options
(
&
opts
,
c
);
ret
=
avio_open2
(
&
out
,
temp_filename
,
AVIO_FLAG_WRITE
,
NULL
,
&
opts
);
ret
=
dashenc_io_open
(
s
,
&
c
->
m3u8_out
,
temp_filename
,
&
opts
);
if
(
ret
<
0
)
{
av_log
(
s
,
AV_LOG_ERROR
,
"Unable to open %s for writing
\n
"
,
temp_filename
);
return
ret
;
}
av_dict_free
(
&
opts
);
ff_hls_write_playlist_version
(
out
,
7
);
ff_hls_write_playlist_version
(
c
->
m3u8_
out
,
7
);
for
(
i
=
0
;
i
<
s
->
nb_streams
;
i
++
)
{
char
playlist_file
[
64
];
...
...
@@ -894,7 +894,7 @@ static int write_manifest(AVFormatContext *s, int final)
if
(
st
->
codecpar
->
codec_type
!=
AVMEDIA_TYPE_AUDIO
)
continue
;
get_hls_playlist_name
(
playlist_file
,
sizeof
(
playlist_file
),
NULL
,
i
);
ff_hls_write_audio_rendition
(
out
,
(
char
*
)
audio_group
,
ff_hls_write_audio_rendition
(
c
->
m3u8_
out
,
(
char
*
)
audio_group
,
playlist_file
,
i
,
is_default
);
max_audio_bitrate
=
FFMAX
(
st
->
codecpar
->
bit_rate
+
os
->
muxer_overhead
,
max_audio_bitrate
);
...
...
@@ -923,10 +923,11 @@ static int write_manifest(AVFormatContext *s, int final)
av_strlcat
(
codec_str
,
audio_codec_str
,
sizeof
(
codec_str
));
}
get_hls_playlist_name
(
playlist_file
,
sizeof
(
playlist_file
),
NULL
,
i
);
ff_hls_write_stream_info
(
st
,
out
,
stream_bitrate
,
playlist_file
,
agroup
,
ff_hls_write_stream_info
(
st
,
c
->
m3u8_out
,
stream_bitrate
,
playlist_file
,
agroup
,
codec_str
,
NULL
);
}
avio_close
(
out
);
dashenc_io_close
(
s
,
&
c
->
m3u8_out
,
temp_filename
);
if
(
use_rename
)
if
((
ret
=
avpriv_io_move
(
temp_filename
,
filename_hls
))
<
0
)
return
ret
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment