예제 #1
0
 /// <summary>
 /// Retrieve properties of an image format applied to sparse images.
 /// </summary>
 public SparseImageFormatProperties[] GetSparseImageFormatProperties(Format format, ImageType type, SampleCountFlags samples, ImageUsageFlags usage, ImageTiling tiling)
 {
     unsafe
     {
         try
         {
             SparseImageFormatProperties[] result = default(SparseImageFormatProperties[]);
             uint propertyCount;
             SparseImageFormatProperties *marshalledProperties = null;
             Interop.Commands.vkGetPhysicalDeviceSparseImageFormatProperties(this.handle, format, type, samples, usage, tiling, &propertyCount, null);
             marshalledProperties = (SparseImageFormatProperties *)Interop.HeapUtil.Allocate <SparseImageFormatProperties>((uint)propertyCount);
             Interop.Commands.vkGetPhysicalDeviceSparseImageFormatProperties(this.handle, format, type, samples, usage, tiling, &propertyCount, marshalledProperties);
             result = new SparseImageFormatProperties[(uint)propertyCount];
             for (int index = 0; index < (uint)propertyCount; index++)
             {
                 result[index] = marshalledProperties[index];
             }
             return(result);
         }
         finally
         {
             Interop.HeapUtil.FreeLog();
         }
     }
 }
예제 #2
0
 public static extern unsafe void vkGetPhysicalDeviceSparseImageFormatProperties(IntPtr physicalDevice, Format format, ImageType type, SampleCountFlags samples, ImageUsageFlags usage, ImageTiling tiling, uint *pPropertyCount, SparseImageFormatProperties *pProperties);
예제 #3
0
 internal static unsafe extern void vkGetPhysicalDeviceSparseImageFormatProperties(PhysicalDevice physicalDevice, Format format, ImageType type, SampleCountFlags samples, ImageUsageFlags usage, ImageTiling tiling, out UInt32 *PropertyCount, SparseImageFormatProperties *Properties);