public static extern void vkDestroyShaderModule(SharpVk.Interop.Device device, SharpVk.Interop.ShaderModule shaderModule, SharpVk.Interop.AllocationCallbacks *allocator);
public static extern SharpVk.Result vkAllocateCommandBuffers(SharpVk.Interop.Device device, SharpVk.Interop.CommandBufferAllocateInfo *allocateInfo, SharpVk.Interop.CommandBuffer *commandBuffers);
public static extern IntPtr vkGetDeviceProcAddr(SharpVk.Interop.Device device, byte *name);
public static extern void vkGetRenderAreaGranularity(SharpVk.Interop.Device device, SharpVk.Interop.RenderPass renderPass, SharpVk.Extent2D *granularity);
public static extern void vkDestroyCommandPool(SharpVk.Interop.Device device, SharpVk.Interop.CommandPool commandPool, SharpVk.Interop.AllocationCallbacks *allocator);
public static extern SharpVk.Result vkCreateFramebuffer(SharpVk.Interop.Device device, SharpVk.Interop.FramebufferCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.Framebuffer *framebuffer);
public static extern SharpVk.Result vkCreateRenderPass(SharpVk.Interop.Device device, SharpVk.Interop.RenderPassCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.RenderPass *renderPass);
public static extern void vkDestroyPipelineLayout(SharpVk.Interop.Device device, SharpVk.Interop.PipelineLayout pipelineLayout, SharpVk.Interop.AllocationCallbacks *allocator);
public static extern SharpVk.Result vkCreateSampler(SharpVk.Interop.Device device, SharpVk.Interop.SamplerCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.Sampler *sampler);
public static extern SharpVk.Result vkCreateComputePipelines(SharpVk.Interop.Device device, SharpVk.Interop.PipelineCache pipelineCache, uint createInfoCount, SharpVk.Interop.ComputePipelineCreateInfo *createInfos, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.Pipeline *pipelines);
public static extern SharpVk.Result vkCreatePipelineLayout(SharpVk.Interop.Device device, SharpVk.Interop.PipelineLayoutCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.PipelineLayout *pipelineLayout);
public static extern SharpVk.Result vkMergePipelineCaches(SharpVk.Interop.Device device, SharpVk.Interop.PipelineCache destinationCache, uint sourceCacheCount, SharpVk.Interop.PipelineCache *sourceCaches);
public static extern SharpVk.Result vkGetPipelineCacheData(SharpVk.Interop.Device device, SharpVk.Interop.PipelineCache pipelineCache, HostSize *dataSize, void *data);
public static extern SharpVk.Result vkCreatePipelineCache(SharpVk.Interop.Device device, SharpVk.Interop.PipelineCacheCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.PipelineCache *pipelineCache);
public static extern SharpVk.Result vkFreeDescriptorSets(SharpVk.Interop.Device device, SharpVk.Interop.DescriptorPool descriptorPool, uint descriptorSetCount, SharpVk.Interop.DescriptorSet *descriptorSets);
public static extern void vkDestroySampler(SharpVk.Interop.Device device, SharpVk.Interop.Sampler sampler, SharpVk.Interop.AllocationCallbacks *allocator);
public static extern void vkUpdateDescriptorSets(SharpVk.Interop.Device device, uint descriptorWriteCount, SharpVk.Interop.WriteDescriptorSet *descriptorWrites, uint descriptorCopyCount, SharpVk.Interop.CopyDescriptorSet *descriptorCopies);
public static extern SharpVk.Result vkCreateDescriptorSetLayout(SharpVk.Interop.Device device, SharpVk.Interop.DescriptorSetLayoutCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.DescriptorSetLayout *setLayout);
public static extern void vkDestroyFramebuffer(SharpVk.Interop.Device device, SharpVk.Interop.Framebuffer framebuffer, SharpVk.Interop.AllocationCallbacks *allocator);
public static extern void vkDestroyDescriptorSetLayout(SharpVk.Interop.Device device, SharpVk.Interop.DescriptorSetLayout descriptorSetLayout, SharpVk.Interop.AllocationCallbacks *allocator);
public static extern void vkDestroyRenderPass(SharpVk.Interop.Device device, SharpVk.Interop.RenderPass renderPass, SharpVk.Interop.AllocationCallbacks *allocator);
public static extern SharpVk.Result vkCreateDescriptorPool(SharpVk.Interop.Device device, SharpVk.Interop.DescriptorPoolCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.DescriptorPool *descriptorPool);
public static extern SharpVk.Result vkCreateCommandPool(SharpVk.Interop.Device device, SharpVk.Interop.CommandPoolCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.CommandPool *commandPool);
public static extern void vkDestroyDescriptorPool(SharpVk.Interop.Device device, SharpVk.Interop.DescriptorPool descriptorPool, SharpVk.Interop.AllocationCallbacks *allocator);
public static extern SharpVk.Result vkResetCommandPool(SharpVk.Interop.Device device, SharpVk.Interop.CommandPool commandPool, SharpVk.CommandPoolResetFlags flags);
public static extern SharpVk.Result vkResetDescriptorPool(SharpVk.Interop.Device device, SharpVk.Interop.DescriptorPool descriptorPool, SharpVk.DescriptorPoolResetFlags flags);
public static extern void vkFreeCommandBuffers(SharpVk.Interop.Device device, SharpVk.Interop.CommandPool commandPool, uint commandBufferCount, SharpVk.Interop.CommandBuffer *commandBuffers);
public static extern SharpVk.Result vkAllocateDescriptorSets(SharpVk.Interop.Device device, SharpVk.Interop.DescriptorSetAllocateInfo *allocateInfo, SharpVk.Interop.DescriptorSet *descriptorSets);
/// <summary> /// Create a new device instance. /// </summary> /// <param name="flags"> /// Reserved for future use. /// </param> /// <param name="enabledLayerNames"> /// ppEnabledLayerNames is deprecated and ignored. See Device Layer /// Deprecation. /// </param> /// <param name="enabledExtensionNames"> /// An array of enabledExtensionCount strings containing the names of /// extensions to enable for the created device. See the Extensions /// section for further details. /// </param> /// <param name="enabledFeatures"> /// Null or a PhysicalDeviceFeatures structure that contains boolean /// indicators of all the features to be enabled. Refer to the Features /// section for further details. /// </param> /// <param name="allocator"> /// An optional AllocationCallbacks instance that controls host memory /// allocation. /// </param> public unsafe SharpVk.Device CreateDevice(ArrayProxy <SharpVk.DeviceQueueCreateInfo>?queueCreateInfos, ArrayProxy <string>?enabledLayerNames, ArrayProxy <string>?enabledExtensionNames, SharpVk.DeviceCreateFlags?flags = default(SharpVk.DeviceCreateFlags?), SharpVk.PhysicalDeviceFeatures?enabledFeatures = default(SharpVk.PhysicalDeviceFeatures?), SharpVk.Khronos.PhysicalDeviceFeatures2?physicalDeviceFeatures2Khr = null, SharpVk.Khronos.Experimental.DeviceGroupDeviceCreateInfo?deviceGroupDeviceCreateInfoKhx = null, SharpVk.AllocationCallbacks?allocator = default(SharpVk.AllocationCallbacks?)) { try { SharpVk.Device result = default(SharpVk.Device); SharpVk.Interop.DeviceCreateInfo *marshalledCreateInfo = default(SharpVk.Interop.DeviceCreateInfo *); void *nextPointer = default(void *); SharpVk.Interop.AllocationCallbacks *marshalledAllocator = default(SharpVk.Interop.AllocationCallbacks *); SharpVk.Interop.Device marshalledDevice = default(SharpVk.Interop.Device); if (physicalDeviceFeatures2Khr != null) { SharpVk.Interop.Khronos.PhysicalDeviceFeatures2 *extensionPointer = default(SharpVk.Interop.Khronos.PhysicalDeviceFeatures2 *); extensionPointer = (SharpVk.Interop.Khronos.PhysicalDeviceFeatures2 *)(Interop.HeapUtil.Allocate <SharpVk.Interop.Khronos.PhysicalDeviceFeatures2>()); physicalDeviceFeatures2Khr.Value.MarshalTo(extensionPointer); extensionPointer->Next = nextPointer; nextPointer = extensionPointer; } if (deviceGroupDeviceCreateInfoKhx != null) { SharpVk.Interop.Khronos.Experimental.DeviceGroupDeviceCreateInfo *extensionPointer = default(SharpVk.Interop.Khronos.Experimental.DeviceGroupDeviceCreateInfo *); extensionPointer = (SharpVk.Interop.Khronos.Experimental.DeviceGroupDeviceCreateInfo *)(Interop.HeapUtil.Allocate <SharpVk.Interop.Khronos.Experimental.DeviceGroupDeviceCreateInfo>()); deviceGroupDeviceCreateInfoKhx.Value.MarshalTo(extensionPointer); extensionPointer->Next = nextPointer; nextPointer = extensionPointer; } marshalledCreateInfo = (SharpVk.Interop.DeviceCreateInfo *)(Interop.HeapUtil.Allocate <SharpVk.Interop.DeviceCreateInfo>()); marshalledCreateInfo->SType = StructureType.DeviceCreateInfo; marshalledCreateInfo->Next = nextPointer; if (flags != null) { marshalledCreateInfo->Flags = flags.Value; } else { marshalledCreateInfo->Flags = default(SharpVk.DeviceCreateFlags); } marshalledCreateInfo->QueueCreateInfoCount = (uint)(Interop.HeapUtil.GetLength(queueCreateInfos)); if (queueCreateInfos.IsNull()) { marshalledCreateInfo->QueueCreateInfos = null; } else { if (queueCreateInfos.Value.Contents == ProxyContents.Single) { marshalledCreateInfo->QueueCreateInfos = (SharpVk.Interop.DeviceQueueCreateInfo *)(Interop.HeapUtil.Allocate <SharpVk.Interop.DeviceQueueCreateInfo>()); queueCreateInfos.Value.GetSingleValue().MarshalTo(&*(SharpVk.Interop.DeviceQueueCreateInfo *)(marshalledCreateInfo->QueueCreateInfos)); } else { var fieldPointer = (SharpVk.Interop.DeviceQueueCreateInfo *)(Interop.HeapUtil.AllocateAndClear <SharpVk.Interop.DeviceQueueCreateInfo>(Interop.HeapUtil.GetLength(queueCreateInfos.Value)).ToPointer()); for (int index = 0; index < (uint)(Interop.HeapUtil.GetLength(queueCreateInfos.Value)); index++) { queueCreateInfos.Value[index].MarshalTo(&fieldPointer[index]); } marshalledCreateInfo->QueueCreateInfos = fieldPointer; } } marshalledCreateInfo->EnabledLayerCount = (uint)(Interop.HeapUtil.GetLength(enabledLayerNames)); marshalledCreateInfo->EnabledLayerNames = Interop.HeapUtil.MarshalTo(enabledLayerNames); marshalledCreateInfo->EnabledExtensionCount = (uint)(Interop.HeapUtil.GetLength(enabledExtensionNames)); marshalledCreateInfo->EnabledExtensionNames = Interop.HeapUtil.MarshalTo(enabledExtensionNames); if (enabledFeatures != null) { marshalledCreateInfo->EnabledFeatures = (SharpVk.Interop.PhysicalDeviceFeatures *)(Interop.HeapUtil.Allocate <SharpVk.Interop.PhysicalDeviceFeatures>()); enabledFeatures.Value.MarshalTo(marshalledCreateInfo->EnabledFeatures); } else { marshalledCreateInfo->EnabledFeatures = default(SharpVk.Interop.PhysicalDeviceFeatures *); } if (allocator != null) { marshalledAllocator = (SharpVk.Interop.AllocationCallbacks *)(Interop.HeapUtil.Allocate <SharpVk.Interop.AllocationCallbacks>()); allocator.Value.MarshalTo(marshalledAllocator); } else { marshalledAllocator = default(SharpVk.Interop.AllocationCallbacks *); } SharpVk.Interop.VkPhysicalDeviceCreateDeviceDelegate commandDelegate = commandCache.GetCommandDelegate <SharpVk.Interop.VkPhysicalDeviceCreateDeviceDelegate>("vkCreateDevice", ""); Result methodResult = commandDelegate(this.handle, marshalledCreateInfo, marshalledAllocator, &marshalledDevice); if (SharpVkException.IsError(methodResult)) { throw SharpVkException.Create(methodResult); } result = new SharpVk.Device(this, marshalledDevice); return(result); } finally { Interop.HeapUtil.FreeAll(); } }
public static extern SharpVk.Result vkCreateShaderModule(SharpVk.Interop.Device device, SharpVk.Interop.ShaderModuleCreateInfo *createInfo, SharpVk.Interop.AllocationCallbacks *allocator, SharpVk.Interop.ShaderModule *shaderModule);