Win HOW TO - Kodi 2D - 3D - UHD (4k) HDR Guide Internal & External Players
Switch.js keeps giving errors
heres mine current ---- its causing some rate change issues.
Please advise

(function() {
var refreshRate = 0;

// Get current refresh rate

var wmiService = GetObject('WinMgmts://./root/cimv2');
refreshRate = new Enumerator(
wmiService.ExecQuery('SELECT * FROM Win32_VideoController WHERE Availability <> 8')
).item(0).CurrentRefreshRate;

if (typeof refreshRate != 'number' || refreshRate === 0) {
WScript.Echo('Duh. Cannot determine current refresh rate.');
} else {

// Run QRes.exe to change refresh rate

var fs = new ActiveXObject('Scripting.FileSystemObject');
var shell = new ActiveXObject('WScript.Shell');
shell.Run(fs.GetAbsolutePathName(fs.BuildPath)
(fs.GetParentFolderName(WScript.ScriptFullName), 'QRes.exe')
) + ' /x 1920 /y 1080 /r:' + (refreshRate >= 59 ? 24 : 60), 0, true };
Reply
 
Thread Rating:
  • 39 Vote(s) - 4.49 Average


Messages In This Thread
RE: Kodi 3D Guide - by brazen1 - 2015-06-15, 22:20
RE: Kodi 3D Guide - by brazen1 - 2015-06-15, 22:29
RE: Kodi 3D Guide - by michaelsammler - 2015-06-22, 00:38
RE: Kodi 3D Guide - by brazen1 - 2015-06-23, 17:15
RE: Kodi 3D Guide - by michaelsammler - 2015-06-24, 02:23
RE: Kodi 3D Guide - by brazen1 - 2015-06-24, 17:22
RE: Kodi 3D Guide - by michaelsammler - 2015-06-25, 09:26
RE: HOW TO - Kodi 2D - 3D - UHD (4k) HDR Guide Internal & External Players - by shaktoo - 2017-11-04, 17:01
HELP! - by brazen1 - 2018-08-22, 18:50
RE: HELP! - by zxaura1 - 2018-08-24, 09:32
Problem with DXVA scaling videos - by obstler - 2018-10-27, 10:13


Logout Mark Read Team Forum Stats Members Help
HOW TO - Kodi 2D - 3D - UHD (4k) HDR Guide Internal & External Players4.4939