# C# - Sharpdx - Enabling AMDExpress/NVOptimus

## Recommended Posts

Hi Guys,

I have a laptop that currently is an AMD based cpu with an APU.  I'm looking to enable the correct integrated graphics device.   Apparently this can be problematic, but is fixed by using the declaration

extern "C"
{
__declspec(dllexport) DWORD NvOptimusEnablement = 0x00000001;
__declspec(dllexport) int AmdPowerXpressRequestHighPerformance = 1;
}

That's fine, but I am using C#, and as such looking for ways to enable this.  I found this from a 2014 article for C# and enabling the Nvidia Optimus export (http://lucasmagder.com/blog/2014/05/exporting-data-symbols-in-c-for-nvidia-optimus/>).

2 - Its still needed and there is a more elegant way of performing this since this article (written in 2014).

3 - This is still the best way.

4 - Something I do not know of...

I've been digging for a while, and this seems to be the only information I can dig up from a c# perspective.  I although still need to validate that I have indeed is already enabled, and this should really be my first step.  Is this still an issue for lap tops for both Nvidia and AMD integrated graphics?

## Create an account

Register a new account