Unable to enable / disable Mosaic using NVAPI

508 views Asked by At

I'm working on some code to enable and disable Mosaic via NVAPI on a Quadro P4000.

I've set Mosaic to be active via the Nvidia utilities on the machine and it works. However, when I try to disable the Mosaic settings via code I receive the NVAPI_NO_IMPLEMENTATION status error.

This is the code I'm using:

void disableMosaic()
{
    NvAPI_Status error;
    NvAPI_ShortString estring;


    NvAPI_Initialize();

    error = NvAPI_EnableCurrentMosaicTopology(0);

    if (error != NVAPI_OK)
    {
        NvAPI_GetErrorMessage(error, estring);
        printf("Error disabling Mosaic: %s\n", estring);
    }
    else
    {
        printf("Mosaic disabled successfully.\n");
    }
}

According to the documentation from Nvidia, this means that the drivers don't support this feature, though I find this a bit vague, the drivers are well established and it's not a new card. Does anyone know if this might be something else or am I wasting my time with this approach?

1

There are 1 answers

0
GrandMasterFlush On BEST ANSWER

After more investigation, it turns out the error message is right, but there is a work around.

The NvAPI_EnableCurrentMosaicTopology() method is for Windows XP (most of the example code I've found in this area has been quite old, hence this mistake). To get this functionality working on Windows 7 - 10 there is a different method to use: NvAPI_Mosaic_EnableCurrentTopo().