UI: Add option to auto remux
This commit is contained in:
committed by
Clayton Groeneveld
parent
14ae6351d4
commit
2fedcab987
@@ -77,6 +77,9 @@ string opt_starting_collection;
|
||||
string opt_starting_profile;
|
||||
string opt_starting_scene;
|
||||
|
||||
bool remuxAfterRecord = false;
|
||||
string remuxFilename;
|
||||
|
||||
// GPU hint exports for AMD/NVIDIA laptops
|
||||
#ifdef _MSC_VER
|
||||
extern "C" __declspec(dllexport) DWORD NvOptimusEnablement = 1;
|
||||
@@ -1493,8 +1496,18 @@ string GenerateTimeDateFilename(const char *extension, bool noSpace)
|
||||
string GenerateSpecifiedFilename(const char *extension, bool noSpace,
|
||||
const char *format)
|
||||
{
|
||||
OBSBasic *main = reinterpret_cast<OBSBasic*>(App()->GetMainWindow());
|
||||
bool autoRemux = config_get_bool(main->Config(), "Video", "AutoRemux");
|
||||
|
||||
if ((strcmp(extension, "mp4") == 0) && autoRemux)
|
||||
extension = "mkv";
|
||||
|
||||
BPtr<char> filename = os_generate_formatted_filename(extension,
|
||||
!noSpace, format);
|
||||
|
||||
remuxFilename = string(filename);
|
||||
remuxAfterRecord = autoRemux;
|
||||
|
||||
return string(filename);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user