Skip to content

Commit

Permalink
add warning for unsupported gpu drivers / bump version
Browse files Browse the repository at this point in the history
  • Loading branch information
mafiosnik777 committed Dec 14, 2022
1 parent e91eeb1 commit 5f115ad
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 25 deletions.
18 changes: 9 additions & 9 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "enhancr",
"productName": "enhancr",
"version": "0.9.3",
"version": "0.9.3a",
"private": true,
"description": "Interpolation/Upscaling AI",
"main": "src/app.js",
Expand All @@ -20,7 +20,7 @@
"@ffmpeg-installer/ffmpeg": "^1.1.0",
"@ffprobe-installer/ffprobe": "^1.4.1",
"@fortawesome/fontawesome-free": "~6.2.1",
"@mafiosnik/nvenc-codecs": "^1.0.2",
"@mafiosnik/nvenc-codecs": "^1.0.4",
"@supercharge/promise-pool": "^2.3.2",
"animate.css": "^4.1.1",
"aspect-ratio": "^2.1.1",
Expand Down
32 changes: 18 additions & 14 deletions src/js/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -170,20 +170,24 @@ function detectHWEncodingCaps() {
var waitUntilGPUInitialization = setInterval(() => {
if (sessionStorage.getItem('hasNVIDIA') != null) {
if (sessionStorage.getItem('hasNVIDIA') == "true") {
if (nvencDevice.supports('AV1')) {
document.getElementById('AV1-hw').innerHTML = '<i class="fa-solid fa-check"></i> AV1';
document.getElementById('AV1-hw').classList.add('green');
clearInterval(waitUntilGPUInitialization);
}
if (nvencDevice.supports('HEVC')) {
document.getElementById('H265-hw').innerHTML = '<i class="fa-solid fa-check"></i> H265';
document.getElementById('H265-hw').classList.add('green');
clearInterval(waitUntilGPUInitialization);
}
if (nvencDevice.supports('H264')) {
document.getElementById('H264-hw').innerHTML = '<i class="fa-solid fa-check"></i> H264';
document.getElementById('H264-hw').classList.add('green');
clearInterval(waitUntilGPUInitialization);
if (nvencDevice.supports('AV1').includes('Driver does not support the reqired nvenc API version')) {
alert('Driver does not support the required NVENC API version. The minimum required NVIDIA Driver for NVENC is 436.15 or newer. Please update your GPU drivers to use hardware encoding.');
} else {
if (nvencDevice.supports('AV1')) {
document.getElementById('AV1-hw').innerHTML = '<i class="fa-solid fa-check"></i> AV1';
document.getElementById('AV1-hw').classList.add('green');
clearInterval(waitUntilGPUInitialization);
}
if (nvencDevice.supports('HEVC')) {
document.getElementById('H265-hw').innerHTML = '<i class="fa-solid fa-check"></i> H265';
document.getElementById('H265-hw').classList.add('green');
clearInterval(waitUntilGPUInitialization);
}
if (nvencDevice.supports('H264')) {
document.getElementById('H264-hw').innerHTML = '<i class="fa-solid fa-check"></i> H264';
document.getElementById('H264-hw').classList.add('green');
clearInterval(waitUntilGPUInitialization);
}
}
} else {
document.getElementById('AV1-hw').innerHTML = '<i class="fa-solid fa-question"></i> AV1';
Expand Down

0 comments on commit 5f115ad

Please sign in to comment.