org.lwjgl.vulkan.VkPhysicalDevice Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of lwjgl-vulkan Show documentation
Show all versions of lwjgl-vulkan Show documentation
A new generation graphics and compute API that provides high-efficiency, cross-platform access to modern GPUs used in a wide variety of devices from PCs and consoles to mobile phones and embedded platforms.
/*
* Copyright LWJGL. All rights reserved.
* License terms: https://www.lwjgl.org/license
*/
package org.lwjgl.vulkan;
/** Wraps a Vulkan physical device handle. */
public class VkPhysicalDevice extends DispatchableHandle {
private final VkInstance instance;
/**
* Creates a {@code VkPhysicalDevice} using the specified native handle and Vulkan instance.
*
* @param handle the native {@code VkDevice} handle
* @param instance the Vulkan instance from which the physical device was enumerated
*/
public VkPhysicalDevice(long handle, VkInstance instance) {
super(handle, instance.getCapabilities());
this.instance = instance;
}
/** Returns the Vulkan instance from which this physical device was enumerated. */
public VkInstance getInstance() {
return instance;
}
}