Function nvapi_hi::sys::gpu::display::NvAPI_GPU_GetConnectedDisplayIds
[−]
[src]
pub unsafe fn NvAPI_GPU_GetConnectedDisplayIds(
hPhysicalGPU: NvPhysicalGpuHandle,
pDisplayIds: *mut NV_GPU_DISPLAYIDS,
pDisplayIdCount: *mut u32,
flags: u32
) -> i32
Due to space limitation NvAPI_GPU_GetConnectedOutputs can return maximum 32 devices, but this is no longer true for DPMST. NvAPI_GPU_GetConnectedDisplayIds will return all the connected display devices in the form of displayIds for the associated hPhysicalGpu. This function can accept set of flags to request cached, uncached, sli and lid to get the connected devices. Default value for flags will be cached.
HOW TO USE
- for each PhysicalGpu, make a call to get the number of connected displayId's using NvAPI_GPU_GetConnectedDisplayIds by passing the pDisplayIds as NULL
- On call success: Allocate memory based on pDisplayIdCount then make a call NvAPI_GPU_GetConnectedDisplayIds to populate DisplayIds
RETURN STATUS
NVAPI_INVALID_ARGUMENT
: hPhysicalGpu or pDisplayIds or pDisplayIdCount is NULLNVAPI_OK
: *pDisplayIds contains a set of GPU-output identifiersNVAPI_NVIDIA_DEVICE_NOT_FOUND
: no NVIDIA GPU driving a display was foundNVAPI_EXPECTED_PHYSICAL_GPU_HANDLE
: hPhysicalGpu was not a physical GPU handle