Added a few new options

This commit is contained in:
Jonathan Thomas
2012-08-11 03:39:00 -05:00
parent 1b1b84dde8
commit 7eeb8f7c80
2 changed files with 15 additions and 3 deletions

View File

@@ -195,7 +195,8 @@ void FFmpegWriter::SetOption(Stream_Type stream, string name, string value)
option = av_find_opt(c->priv_data, name.c_str(), NULL, NULL, NULL);
// Was option found?
if (option || (name == "g" || name == "qmin" || name == "qmax" || name == "max_b_frames" || name == "mb_decision"))
if (option || (name == "g" || name == "qmin" || name == "qmax" || name == "max_b_frames" || name == "mb_decision" ||
name == "level" || name == "profile"))
{
// Check for specific named options
if (name == "g")
@@ -218,6 +219,14 @@ void FFmpegWriter::SetOption(Stream_Type stream, string name, string value)
// macroblock decision mode
convert >> c->mb_decision;
else if (name == "level")
// set codec level
convert >> c->level;
else if (name == "profile")
// set codec profile
convert >> c->profile;
else
// Set AVOption
av_set_string3 (c->priv_data, name.c_str(), value.c_str(), 0, NULL);