aarthi priya
2018-11-15 11:15:07 UTC
Hi all,
I am trying to transcode and package a video to HLS using ffmpeg. I tried
it in 2 ways.
1. Transcode and package in a single step
command: ./ffmpeg -i input.mov -vframes 500 -c:v libx264 -g 50
-x264-params
keyint=50:scenecut=0:bitrate=1200:vbv-maxrate=2000:vbv-bufsize=2000 -c:a
aac -profile:a aac_low -ac 2 -b:a 64 -f hls -hls_time 2 -hls_playlist_type
vod -muxdelay 0 -hls_segment_filename 'out/Layer1_%v/seg-%03d.ts'
-master_pl_name
'master.m3u8' out/index.m3u8
2. Tanscode to mp4 output and package mp4 to HLS as a separate process.
command: ./ffmpeg -i input.mov -vframes 500 -c:v libx264 -g 50
-x264-params
keyint=50:scenecut=0:bitrate=1200:vbv-maxrate=2000:vbv-bufsize=2000 -c:a
aac -profile:a aac_low -ac 2 -b:a 64 out.mp4
./ffmpeg -i out.mp4 -c copy -f hls -hls_time 2 -hls_playlist_type vod
-muxdelay 0 -hls_segment_filename 'out/Layer1_%v/seg-%03d.ts' -master_pl_name
'master.m3u8' out/index.m3u8
#1 is working fine - no problem
#2 - Here the Codec attribute string is not getting printed in the master
manifest. When looking into the code, I saw that the
AVStream->codecpar->extradata is populated different and doesnt follow the
expected condition of *(data[0] | data[1] | data[2]) == 0 && data[3] == 1
&& (data[4] & 0x1F) == 7) - this is in hlsenc.*c:write_codec_attr()
I want to understand why it gets populated differently. Also, for my use
case, encoding and packaging needs to be different steps. So, how can I get
the codec id printed in the master manifest for #2 method.
regards
Aarthi
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject "unsubscri
I am trying to transcode and package a video to HLS using ffmpeg. I tried
it in 2 ways.
1. Transcode and package in a single step
command: ./ffmpeg -i input.mov -vframes 500 -c:v libx264 -g 50
-x264-params
keyint=50:scenecut=0:bitrate=1200:vbv-maxrate=2000:vbv-bufsize=2000 -c:a
aac -profile:a aac_low -ac 2 -b:a 64 -f hls -hls_time 2 -hls_playlist_type
vod -muxdelay 0 -hls_segment_filename 'out/Layer1_%v/seg-%03d.ts'
-master_pl_name
'master.m3u8' out/index.m3u8
2. Tanscode to mp4 output and package mp4 to HLS as a separate process.
command: ./ffmpeg -i input.mov -vframes 500 -c:v libx264 -g 50
-x264-params
keyint=50:scenecut=0:bitrate=1200:vbv-maxrate=2000:vbv-bufsize=2000 -c:a
aac -profile:a aac_low -ac 2 -b:a 64 out.mp4
./ffmpeg -i out.mp4 -c copy -f hls -hls_time 2 -hls_playlist_type vod
-muxdelay 0 -hls_segment_filename 'out/Layer1_%v/seg-%03d.ts' -master_pl_name
'master.m3u8' out/index.m3u8
#1 is working fine - no problem
#2 - Here the Codec attribute string is not getting printed in the master
manifest. When looking into the code, I saw that the
AVStream->codecpar->extradata is populated different and doesnt follow the
expected condition of *(data[0] | data[1] | data[2]) == 0 && data[3] == 1
&& (data[4] & 0x1F) == 7) - this is in hlsenc.*c:write_codec_attr()
I want to understand why it gets populated differently. Also, for my use
case, encoding and packaging needs to be different steps. So, how can I get
the codec id printed in the master manifest for #2 method.
regards
Aarthi
_______________________________________________
ffmpeg-user mailing list
ffmpeg-***@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user
To unsubscribe, visit link above, or email
ffmpeg-user-***@ffmpeg.org with subject "unsubscri