Ejemplo n.º 1
0
  static WGLNVGPUAffinity create(java.util.Set<String> ext, FunctionProvider provider) {
    if (!ext.contains("WGL_NV_gpu_affinity")) return null;

    WGLNVGPUAffinity funcs = new WGLNVGPUAffinity(provider);

    boolean supported =
        checkFunctions(
            funcs.EnumGpusNV,
            funcs.EnumGpuDevicesNV,
            funcs.CreateAffinityDCNV,
            funcs.EnumGpusFromAffinityDCNV,
            funcs.DeleteDCNV);

    return GL.checkExtension("WGL_NV_gpu_affinity", funcs, supported);
  }
Ejemplo n.º 2
0
  static WGLNVDXInterop create(java.util.Set<String> ext, FunctionProvider provider) {
    if (!ext.contains("WGL_NV_DX_interop")) return null;

    WGLNVDXInterop funcs = new WGLNVDXInterop(provider);

    boolean supported =
        checkFunctions(
            funcs.DXSetResourceShareHandleNV,
            funcs.DXOpenDeviceNV,
            funcs.DXCloseDeviceNV,
            funcs.DXRegisterObjectNV,
            funcs.DXUnregisterObjectNV,
            funcs.DXObjectAccessNV,
            funcs.DXLockObjectsNV,
            funcs.DXUnlockObjectsNV);

    return GL.checkExtension("WGL_NV_DX_interop", funcs, supported);
  }