Documentation
¶
Index ¶
- Constants
- type ExtensionDriver
- type ExternalBufferProperties
- type ExternalImageFormatProperties
- type ExternalMemoryFeatureFlags
- type ExternalMemoryHandleTypeFlags
- type ExternalMemoryProperties
- type PhysicalDeviceExternalBufferInfo
- type PhysicalDeviceExternalImageFormatInfo
- type PhysicalDeviceIDProperties
- type VulkanExtensionDriver
Constants ¶
const ( // ExtensionName is "VK_KHR_external_memory_capabilities" // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VK_KHR_external_memory_capabilities.html ExtensionName string = C.VK_KHR_EXTERNAL_MEMORY_CAPABILITIES_EXTENSION_NAME // LUIDSize is the length of a locally unique Device identifier // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VK_LUID_SIZE.html LUIDSize int = C.VK_LUID_SIZE_KHR // ExternalMemoryFeatureDedicatedOnly specifies that Image or Buffer objects created with the // specified parameters and handle type must create or import a dedicated allocation for // the Image or Buffer object // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryFeatureFlagBits.html ExternalMemoryFeatureDedicatedOnly ExternalMemoryFeatureFlags = C.VK_EXTERNAL_MEMORY_FEATURE_DEDICATED_ONLY_BIT_KHR // ExternalMemoryFeatureExportable specifies that handles of this type can be exported from // Vulkan memory objects // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryFeatureFlagBits.html ExternalMemoryFeatureExportable ExternalMemoryFeatureFlags = C.VK_EXTERNAL_MEMORY_FEATURE_EXPORTABLE_BIT_KHR // ExternalMemoryFeatureImportable specifies that handles of this type can be imported as Vulkan // memory objects // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryFeatureFlagBits.html ExternalMemoryFeatureImportable ExternalMemoryFeatureFlags = C.VK_EXTERNAL_MEMORY_FEATURE_IMPORTABLE_BIT_KHR // ExternalMemoryHandleTypeD3D11Texture specifies an NT handle returned by // IDXGIResource1::CreateSharedHandle referring to a Direct3D 10 or 11 texture resource // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryHandleTypeFlagBits.html ExternalMemoryHandleTypeD3D11Texture ExternalMemoryHandleTypeFlags = C.VK_EXTERNAL_MEMORY_HANDLE_TYPE_D3D11_TEXTURE_BIT_KHR // ExternalMemoryHandleTypeD3D11TextureKMT specifies a global share handle returned by // IDXGIResource::GetSharedHandle referring to a Direct3D 10 or 11 texture resource // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryHandleTypeFlagBits.html ExternalMemoryHandleTypeD3D11TextureKMT ExternalMemoryHandleTypeFlags = C.VK_EXTERNAL_MEMORY_HANDLE_TYPE_D3D11_TEXTURE_KMT_BIT_KHR // ExternalMemoryHandleTypeD3D12Heap specifies an NT handle returned by // ID3D12Device::CreateSharedHandle referring to a Direct3D 12 heap resource // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryHandleTypeFlagBits.html ExternalMemoryHandleTypeD3D12Heap ExternalMemoryHandleTypeFlags = C.VK_EXTERNAL_MEMORY_HANDLE_TYPE_D3D12_HEAP_BIT_KHR // ExternalMemoryHandleTypeD3D12Resource specifies an NT handle returned by // ID3D12Device::CreateSharedHandle referring to a Direct3D 12 committed resource // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryHandleTypeFlagBits.html ExternalMemoryHandleTypeD3D12Resource ExternalMemoryHandleTypeFlags = C.VK_EXTERNAL_MEMORY_HANDLE_TYPE_D3D12_RESOURCE_BIT_KHR // ExternalMemoryHandleTypeOpaqueFD specifies a POSIX file descriptor handle that has only limited // valid usage outside of Vulkan and other compatible APIs // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryHandleTypeFlagBits.html ExternalMemoryHandleTypeOpaqueFD ExternalMemoryHandleTypeFlags = C.VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_FD_BIT_KHR // ExternalMemoryHandleTypeOpaqueWin32 specifies an NT handle that has only limited valid usage // outside of Vulkan and other compatible APIs // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryHandleTypeFlagBits.html ExternalMemoryHandleTypeOpaqueWin32 ExternalMemoryHandleTypeFlags = C.VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_BIT_KHR // ExternalMemoryHandleTypeOpaqueWin32KMT specifies a global share handle that has only // limited valid usage outside of Vulkan and other compatible APIs // // https://registry.khronos.org/vulkan/specs/1.3-extensions/man/html/VkExternalMemoryHandleTypeFlagBits.html ExternalMemoryHandleTypeOpaqueWin32KMT ExternalMemoryHandleTypeFlags = C.VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_KMT_BIT_KHR )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ExtensionDriver ¶
type ExtensionDriver interface {
// GetPhysicalDeviceExternalBufferProperties queries external types supported by Buffer objects
//
// physicalDevice - The PhysicalDevice being queried
//
// o - Describes the parameters that would be consumed by Device.CreateBuffer
//
// outData - A pre-allocated object in which the results will be populated. It should include any
// desired chained OutData objects.
//
// https://www.khronos.org/registry/VulkanSC/specs/1.0-extensions/man/html/vkGetPhysicalDeviceExternalBufferProperties.html
GetPhysicalDeviceExternalBufferProperties(physicalDevice core1_0.PhysicalDevice, o PhysicalDeviceExternalBufferInfo, outData *ExternalBufferProperties) error
}
ExtensionDriver contains all the commands for the khr_external_memory_capabilities extension
func CreateExtensionDriverFromCoreDriver ¶
func CreateExtensionDriverFromCoreDriver(driver core1_0.DeviceDriver) ExtensionDriver
CreateExtensionDriverFromCoreDriver produces an ExtensionDriver object from a Device with khr_external_memory_capabilities loaded
type ExternalBufferProperties ¶
type ExternalBufferProperties = core1_1.ExternalBufferProperties
type ExternalImageFormatProperties ¶
type ExternalImageFormatProperties struct {
// ExternalMemoryProperties specifies various capabilities of the external handle type when used
// with the specified Image creation parameters
ExternalMemoryProperties ExternalMemoryProperties
common.NextOutData
}
ExternalImageFormatProperties specifies supported external handle properties
func (*ExternalImageFormatProperties) PopulateHeader ¶
func (*ExternalImageFormatProperties) PopulateOutData ¶
type ExternalMemoryFeatureFlags ¶
type ExternalMemoryFeatureFlags = core1_1.ExternalMemoryFeatureFlags
type ExternalMemoryHandleTypeFlags ¶
type ExternalMemoryHandleTypeFlags = core1_1.ExternalMemoryHandleTypeFlags
type ExternalMemoryProperties ¶
type ExternalMemoryProperties = core1_1.ExternalMemoryProperties
type PhysicalDeviceExternalBufferInfo ¶
type PhysicalDeviceExternalBufferInfo = core1_1.PhysicalDeviceExternalBufferInfo
type PhysicalDeviceExternalImageFormatInfo ¶
type PhysicalDeviceExternalImageFormatInfo struct {
// HandleType specifies the memory handle type that will be used with the memory associated
// with the Image
HandleType ExternalMemoryHandleTypeFlags
common.NextOptions
}
PhysicalDeviceExternalImageFormatInfo specifies external Image creation parameters
type PhysicalDeviceIDProperties ¶
type PhysicalDeviceIDProperties struct {
// DeviceUUID represents a universally-unique identifier for the device
DeviceUUID uuid.UUID
// DriverUUID represents a universally-unique identifier for the loader build
// in use by the device
DriverUUID uuid.UUID
// DeviceLUID represents a locally-unique identifier for the device
DeviceLUID uint64
// DeviceNodeMask identifies the node within a linked device adapter corresponding to the
// Device
DeviceNodeMask uint32
// DeviceLUIDValid is true if DeviceLUID contains a valid LUID and DeviceNodeMask contains
// a valid node mask
DeviceLUIDValid bool
common.NextOutData
}
PhysicalDeviceIDProperties speicifes IDs related to the PhysicalDevice
func (*PhysicalDeviceIDProperties) PopulateHeader ¶
func (*PhysicalDeviceIDProperties) PopulateOutData ¶
type VulkanExtensionDriver ¶
type VulkanExtensionDriver struct {
// contains filtered or unexported fields
}
VulkanExtensionDriver is an implementation of the ExtensionDriver interface that actually communicates with Vulkan. This is the default implementation. See the interface for more documentation.
func CreateExtensionDriverFromLoader ¶
func CreateExtensionDriverFromLoader(driver khr_external_memory_capabilities_loader.Loader) *VulkanExtensionDriver
CreateExtensionDriverFromLoader generates an ExtensionDriver from a loader.Loader object- this is usually used in tests to build an ExtensionDriver from mock drivers
func (*VulkanExtensionDriver) GetPhysicalDeviceExternalBufferProperties ¶
func (e *VulkanExtensionDriver) GetPhysicalDeviceExternalBufferProperties(physicalDevice core1_0.PhysicalDevice, o PhysicalDeviceExternalBufferInfo, outData *ExternalBufferProperties) error