summaryrefslogtreecommitdiff
path: root/libavformat/hlsenc.c
diff options
context:
space:
mode:
authorSteven Liu <lq@chinaffmpeg.org>2017-12-12 11:50:23 +0800
committerSteven Liu <lq@chinaffmpeg.org>2017-12-12 11:50:23 +0800
commit0e5260226a72fc9da2967ded99624f5dfb1ed135 (patch)
tree6fb86f798d9ee82a64893de013f0ece90a32c3ab /libavformat/hlsenc.c
parent555119bd762540a9f17a61bdd92329c8b8feb1e0 (diff)
avformat/hlsenc: reindent after previous commits
Diffstat (limited to 'libavformat/hlsenc.c')
-rw-r--r--libavformat/hlsenc.c60
1 files changed, 30 insertions, 30 deletions
diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c
index dd09739651..fdf614bdd1 100644
--- a/libavformat/hlsenc.c
+++ b/libavformat/hlsenc.c
@@ -1646,40 +1646,40 @@ static int hls_write_header(AVFormatContext *s)
for (i = 0; i < hls->nb_varstreams; i++) {
vs = &hls->var_streams[i];
- av_dict_copy(&options, hls->format_options, 0);
- ret = avformat_write_header(vs->avf, &options);
- if (av_dict_count(options)) {
- av_log(s, AV_LOG_ERROR, "Some of provided format options in '%s' are not recognized\n", hls->format_options_str);
- ret = AVERROR(EINVAL);
+ av_dict_copy(&options, hls->format_options, 0);
+ ret = avformat_write_header(vs->avf, &options);
+ if (av_dict_count(options)) {
+ av_log(s, AV_LOG_ERROR, "Some of provided format options in '%s' are not recognized\n", hls->format_options_str);
+ ret = AVERROR(EINVAL);
+ av_dict_free(&options);
+ goto fail;
+ }
av_dict_free(&options);
- goto fail;
- }
- av_dict_free(&options);
- //av_assert0(s->nb_streams == hls->avf->nb_streams);
- for (j = 0; j < vs->nb_streams; j++) {
- AVStream *inner_st;
- AVStream *outer_st = vs->streams[j];
-
- if (hls->max_seg_size > 0) {
- if ((outer_st->codecpar->codec_type == AVMEDIA_TYPE_VIDEO) &&
- (outer_st->codecpar->bit_rate > hls->max_seg_size)) {
- av_log(s, AV_LOG_WARNING, "Your video bitrate is bigger than hls_segment_size, "
- "(%"PRId64 " > %"PRId64 "), the result maybe not be what you want.",
- outer_st->codecpar->bit_rate, hls->max_seg_size);
+ //av_assert0(s->nb_streams == hls->avf->nb_streams);
+ for (j = 0; j < vs->nb_streams; j++) {
+ AVStream *inner_st;
+ AVStream *outer_st = vs->streams[j];
+
+ if (hls->max_seg_size > 0) {
+ if ((outer_st->codecpar->codec_type == AVMEDIA_TYPE_VIDEO) &&
+ (outer_st->codecpar->bit_rate > hls->max_seg_size)) {
+ av_log(s, AV_LOG_WARNING, "Your video bitrate is bigger than hls_segment_size, "
+ "(%"PRId64 " > %"PRId64 "), the result maybe not be what you want.",
+ outer_st->codecpar->bit_rate, hls->max_seg_size);
+ }
}
- }
- if (outer_st->codecpar->codec_type != AVMEDIA_TYPE_SUBTITLE)
- inner_st = vs->avf->streams[j];
- else if (vs->vtt_avf)
- inner_st = vs->vtt_avf->streams[0];
- else {
- /* We have a subtitle stream, when the user does not want one */
- inner_st = NULL;
- continue;
+ if (outer_st->codecpar->codec_type != AVMEDIA_TYPE_SUBTITLE)
+ inner_st = vs->avf->streams[j];
+ else if (vs->vtt_avf)
+ inner_st = vs->vtt_avf->streams[0];
+ else {
+ /* We have a subtitle stream, when the user does not want one */
+ inner_st = NULL;
+ continue;
+ }
+ avpriv_set_pts_info(outer_st, inner_st->pts_wrap_bits, inner_st->time_base.num, inner_st->time_base.den);
}
- avpriv_set_pts_info(outer_st, inner_st->pts_wrap_bits, inner_st->time_base.num, inner_st->time_base.den);
- }
}
fail: