This guide will walk you through this process:
How to encode video on demand content
Salvadore
Hi Salvadore,
The guide is explained how to encode an mp4 to different bitrates in different resolutions. But i need to create the ts files and then segment the ts and create the m3u8.
For example i can do the same with the ffmpeg:
fmpeg -i jeff.mpg -c:v libx264 -b:v 2000k -minrate 2000k -maxrate 2000k -bufsize 2000k jeff1.mp4
but can i do the following with the wowza:
ffmpeg -y -i jeff.mpg -threads 0 -f mpegts \
-acodec libfaac -ab 64k -ar 44100 -vcodec libx264 -vprofile baseline \
-x264opts “fps=12:keyint=36:bitrate=200” -s 416x234 jeff_416_234_200.ts \
-acodec libfaac -ab 64k -ar 44100 -vcodec libx264 -vprofile baseline \
-x264opts “fps=12:keyint=36:bitrate=400” -s 480x270 jeff_480_270_400.ts \
-acodec libfaac -ab 64k -ar 44100 -vcodec libx264 -vprofile baseline \
-x264opts “fps=24:keyint=72:bitrate=600” -s 640x360 jeff_640_360_600.ts \
-acodec libfaac -ab 64k -ar 44100 -vcodec libx264 -vprofile baseline \
-x264opts “fps=24:keyint=72:bitrate=1200” -s 640x360 jeff_640_360_1100.ts \
-acodec libfaac -ab 64k -ar 44100 -vcodec libx264 -vprofile main \
-x264opts “fps=24:keyint=72:bitrate=1800” -s 960x540 jeff_960_540_1400.ts \
-acodec libfaac -ab 64k -ar 44100 -vcodec libx264 -vprofile main \
-x264opts “fps=24:keyint=72:bitrate=2500” -s 960x540 jeff_960_540_1800.ts \
-acodec libfaac -ab 64k -ar 44100 -vcodec libx264 -vprofile main \
-x264opts “fps=24:keyint=72:bitrate=4500” -s 1280x720 jeff_1280_720_2000.ts \
and for the segmenting:
ffmpeg -re -i jeff_416_234_200.ts -codec copy -map 0 -f segment -segment_list eden_416_234_200.m3u8 -segment_list_flags +live -segment_time 7 eden_416_234_200%07d.ts
ffmpeg -re -i jeff_480_270_400.ts -codec copy -map 0 -f segment -segment_list eden_480_270_400.m3u8 -segment_list_flags +live -segment_time 7 eden_480_270_400%07d.ts
ffmpeg -re -i jeff_640_360_600.ts -codec copy -map 0 -f segment -segment_list eden_640_360_600.m3u8 -segment_list_flags +live -segment_time 7 eden_640_360_600%07d.ts
ffmpeg -re -i jeff_640_360_1200.ts -codec copy -map 0 -f segment -segment_list eden_640_360_1200.m3u8 -segment_list_flags +live -segment_time 7 eden_640_360_1200%07d.ts
ffmpeg -re -i jeff_960_540_1800.ts -codec copy -map 0 -f segment -segment_list eden_960_540_1800.m3u8 -segment_list_flags +live -segment_time 7 eden_960_540_1800%07d.ts
ffmpeg -re -i jeff_960_540_2500.ts -codec copy -map 0 -f segment -segment_list eden_960_540_2500.m3u8 -segment_list_flags +live -segment_time 7 eden_960_540_2500%07d.ts
ffmpeg -re -i jeff_1280_720_4500.ts -codec copy -map 0 -f segment -segment_list eden_1280_720_4500.m3u8 -segment_list_flags +live -segment_time 7 eden_1280_720_4500%07d.ts
ffmpeg -re -i eden_1920_1080_8500.ts -codec copy -map 0 -f segment -segment_list eden_1920_1080_8500.m3u8 -segment_list_flags +live -segment_time 7 eden_1920_1080_8500%07d.ts
I create a script to automate all the above but i would like to do it with the wowza because we are thinking to buy the server and use it in a production line.
Thank you
Andrew