0
0
mirror of https://github.com/obsproject/obs-studio.git synced 2024-09-19 20:32:15 +02:00

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
This commit is contained in:
jp9000 2016-04-23 16:02:58 -07:00
parent 448ae26e64
commit 350855a2e7
2 changed files with 12 additions and 0 deletions

View File

@ -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)"

View File

@ -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())