1
0
Fork 0
mirror of https://github.com/ossrs/srs.git synced 2025-03-09 15:49:59 +00:00

add ffmpeg transcoding framework

This commit is contained in:
winlin 2013-11-30 18:31:07 +08:00
parent b1466c8883
commit 8d91561ca0
9 changed files with 161 additions and 1 deletions

View file

@ -20,6 +20,7 @@ vhost __defaultVhost__ {
enabled on;
ffmpeg ./objs/ffmpeg/bin/ffmpeg;
engine fd{
enabled on;
vcodec libx264;
vbitrate 300;
vfps 20;
@ -47,9 +48,12 @@ vhost all.transcode.vhost.com {
enabled on;
# the ffmpeg
ffmpeg ./objs/ffmpeg/bin/ffmpeg;
# the transcode engine for matched stream.
# all matched stream will transcoded to the following stream.
# the transcode set name(ie. hd) is optional and not used.
engine super{
# whether the engine is enabled
enabled on;
# video encoder name
vcodec libx264;
# video bitrate, in kbps
@ -92,6 +96,7 @@ vhost all.transcode.vhost.com {
output rtmp://[vhost]:[port]/[app]/[stream]_super;
}
engine hd{
enabled on;
vcodec libx264;
vbitrate 1200;
vfps 25;
@ -111,6 +116,7 @@ vhost all.transcode.vhost.com {
output rtmp://[vhost]:[port]/[app]/[stream]_hd;
}
engine sd{
enabled on;
vcodec libx264;
vbitrate 800;
vfps 25;
@ -130,6 +136,7 @@ vhost all.transcode.vhost.com {
output rtmp://[vhost]:[port]/[app]/[stream]_sd;
}
engine fast{
enabled on;
vcodec libx264;
vbitrate 300;
vfps 20;
@ -150,6 +157,30 @@ vhost all.transcode.vhost.com {
}
}
}
# transcode all app and stream of app
vhost app.transcode.vhost.com {
# the streaming transcode configs.
# if app specified, transcode all streams of app.
transcode live {
enabled on;
ffmpeg ./objs/ffmpeg/bin/ffmpeg;
engine fd{
enabled off;
}
}
}
# transcode specified stream.
vhost stream.transcode.vhost.com {
# the streaming transcode configs.
# if stream specified, transcode the matched stream.
transcode live/livestream {
enabled on;
ffmpeg ./objs/ffmpeg/bin/ffmpeg;
engine fd{
enabled off;
}
}
}
# the vhost which forward publish streams.
vhost forward.vhost.com {
# forward all publish stream to the specified server.