From 762ccde74cbf433f85faf7b7f86e67cb69f12820 Mon Sep 17 00:00:00 2001 From: lordmulder Date: Sun, 8 May 2016 21:52:46 +0200 Subject: [PATCH] Show warning when NVidia encoder API (NVENCODEAPI.DLL) is *not* available. --- src/encoder_nvenc.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/encoder_nvenc.cpp b/src/encoder_nvenc.cpp index 11d39c0..e19035f 100644 --- a/src/encoder_nvenc.cpp +++ b/src/encoder_nvenc.cpp @@ -390,6 +390,7 @@ void NVEncEncoder::runEncodingPass_init(QList &patterns) { patterns << new QRegExp("^(\\d+) frames:"); patterns << new QRegExp("Selected\\s+codec\\s+is\\s+not\\s+supported", Qt::CaseInsensitive); + patterns << new QRegExp("nvEncodeAPI.dll\\s+does\\s+not\\s+exists\\s+in\\s+your\\s+system", Qt::CaseInsensitive); } void NVEncEncoder::runEncodingPass_parseLine(const QString &line, QList &patterns, const ClipInfo &clipInfo, const int &pass, double &last_progress, double &size_estimate) @@ -401,7 +402,11 @@ void NVEncEncoder::runEncodingPass_parseLine(const QString &line, QListlastIndexIn(line)) >= 0) { - log(QString("YOUR HARDWARE DOES *NOT* SUPPORT THE '%1' CODEC !!!\n").arg(s_nvencEncoderInfo.variantToString(m_options->encVariant()))); + log(QString("ERROR: YOUR HARDWARE DOES *NOT* SUPPORT THE '%1' CODEC !!!\n").arg(s_nvencEncoderInfo.variantToString(m_options->encVariant()))); + } + else if ((offset = patterns[2]->lastIndexIn(line)) >= 0) + { + log("ERROR: NVIDIA ENCODER API (NVENCODEAPI.DLL) IS *NOT* AVAILABLE !!!\n"); } else if(!line.isEmpty()) {