From 350855a2e7a31c853ab7e64087d7f85408e7e856 Mon Sep 17 00:00:00 2001 From: jp9000 Date: Sat, 23 Apr 2016 16:02:58 -0700 Subject: [PATCH] UI: Show warning if using multiple separate QSV encoders Warns users that two separate QSV encoders can't be active at the same time. This should be considered a temporary solution to two issues: 1.) Encoders need to be able to report these errors themselves 2.) If the QSV encoder is ever changed to allow more than one encoder at the same time this should be removed --- obs/data/locale/en-US.ini | 1 + obs/window-basic-settings.cpp | 11 +++++++++++ 2 files changed, 12 insertions(+) diff --git a/obs/data/locale/en-US.ini b/obs/data/locale/en-US.ini index de9a819ba..9a65b5e0f 100644 --- a/obs/data/locale/en-US.ini +++ b/obs/data/locale/en-US.ini @@ -388,6 +388,7 @@ Basic.Settings.Output.Simple.Warn.Encoder="Warning: Recording with a software en Basic.Settings.Output.Simple.Warn.Lossless="Warning: Lossless quality generates tremendously large file sizes! Lossless quality can use upward of 7 gigabytes of disk space per minute at high resolutions and framerates. Lossless is not recommended for long recordings unless you have a very large amount of disk space available." Basic.Settings.Output.Simple.Warn.Lossless.Msg="Are you sure you want to use lossless quality?" Basic.Settings.Output.Simple.Warn.Lossless.Title="Lossless quality warning!" +Basic.Settings.Output.Simple.Warn.MultipleQSV="Warning: You cannot use multiple separate QSV encoders when streaming and recording at the same time. If you want to stream and record at the same time, please change either the recording encoder or the stream encoder." Basic.Settings.Output.Simple.Encoder.Software="Software (x264)" Basic.Settings.Output.Simple.Encoder.Hardware.QSV="Hardware (QSV)" Basic.Settings.Output.Simple.Encoder.Hardware.NVENC="Hardware (NVENC)" diff --git a/obs/window-basic-settings.cpp b/obs/window-basic-settings.cpp index f186edcb8..4204cbf20 100644 --- a/obs/window-basic-settings.cpp +++ b/obs/window-basic-settings.cpp @@ -479,6 +479,8 @@ OBSBasicSettings::OBSBasicSettings(QWidget *parent) this, SLOT(SimpleRecordingQualityLosslessWarning(int))); connect(ui->simpleOutStrEncoder, SIGNAL(currentIndexChanged(int)), this, SLOT(SimpleStreamingEncoderChanged())); + connect(ui->simpleOutStrEncoder, SIGNAL(currentIndexChanged(int)), + this, SLOT(SimpleRecordingEncoderChanged())); connect(ui->simpleOutRecEncoder, SIGNAL(currentIndexChanged(int)), this, SLOT(SimpleRecordingEncoderChanged())); connect(ui->simpleOutputVBitrate, SIGNAL(valueChanged(int)), @@ -3267,12 +3269,21 @@ void OBSBasicSettings::SimpleRecordingEncoderChanged() } else if (qual != "Stream") { QString enc = ui->simpleOutRecEncoder->currentData().toString(); + QString streamEnc = + ui->simpleOutStrEncoder->currentData().toString(); + if (enc == SIMPLE_ENCODER_X264 || enc == SIMPLE_ENCODER_X264_LOWCPU) { if (!warning.isEmpty()) warning += "\n\n"; warning += SIMPLE_OUTPUT_WARNING("Encoder"); } + + if (streamEnc == enc && enc == SIMPLE_ENCODER_QSV) { + if (!warning.isEmpty()) + warning += "\n\n"; + warning += SIMPLE_OUTPUT_WARNING("MultipleQSV"); + } } if (warning.isEmpty())