Skip to content

Instantly share code, notes, and snippets.

@marckean
Created December 10, 2018 08:07
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save marckean/eb1571b1e06775d20ed524b43083363b to your computer and use it in GitHub Desktop.
Save marckean/eb1571b1e06775d20ed524b43083363b to your computer and use it in GitHub Desktop.
# Turn adaptive contrast on - default
$value = '9240'
New-ItemProperty -Path 'HKLM:\SYSTEM\ControlSet001\Control\Class\{4d36e968-e325-11ce-bfc1-08002be10318}\0001' `
-Name 'FeatureTestControl' -PropertyType DWORD -Value $value -Force
# Turn adaptive contrast off
$value = '9250'
New-ItemProperty -Path 'HKLM:\SYSTEM\ControlSet001\Control\Class\{4d36e968-e325-11ce-bfc1-08002be10318}\0001' `
-Name 'FeatureTestControl' -PropertyType DWORD -Value $value -Force
# Restart for changes to take effect
@hjoelr
Copy link

hjoelr commented Feb 2, 2019

@marckean I think your code is incorrect. The 9240 and 9250 should be hex values. They should instead be defined like this:

$value = 0x9240
$value = 0x9250

Notice that the quotes are removed and the numbers are prefixed with 0x to cue to PowerShell that it's a hexadecimal number.

The way you have it in the code they're interpreted as decimal values and that is a much different bitmap. See the explanation of this registry key here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment