You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
Added a few new options
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user