Пример #1
0
        public static ReadOnlySpan <VkRect2D> vkGetPhysicalDevicePresentRectanglesKHR(VkPhysicalDevice physicalDevice, VkSurfaceKHR surface)
        {
            uint rectCount = 0;

            vkGetPhysicalDevicePresentRectanglesKHR(physicalDevice, surface, &rectCount, null).CheckResult();

            ReadOnlySpan <VkRect2D> rects = new VkRect2D[rectCount];

            fixed(VkRect2D *rectsPtr = rects)
            {
                vkGetPhysicalDevicePresentRectanglesKHR(physicalDevice, surface, &rectCount, rectsPtr).CheckResult();
            }

            return(rects);
        }
Пример #2
0
 public static void vkCmdSetScissor(VkCommandBuffer commandBuffer, uint firstScissor, VkRect2D scissor)
 {
     vkCmdSetScissor(commandBuffer, firstScissor, 1, &scissor);
 }