clear color works
[demo] / src / vulkan / vkutil.h
index 396209f..71943bd 100644 (file)
@@ -46,6 +46,7 @@ bool vku_create_semaphores();
 
 /* command buffers */
 VkCommandBuffer vku_alloc_cmdbuf(VkCommandPool pool, VkCommandBufferLevel level);
+bool vku_alloc_cmdbufs(VkCommandPool pool, VkCommandBufferLevel level, unsigned int count, VkCommandBuffer *buf_array);
 void vku_free_cmdbuf(VkCommandPool pool, VkCommandBuffer buf);
 
 void vku_begin_cmdbuf(VkCommandBuffer buf, unsigned int flags);
@@ -53,20 +54,12 @@ void vku_end_cmdbuf(VkCommandBuffer buf);
 void vku_reset_cmdbuf(VkCommandBuffer buf);
 void vku_submit_cmdbuf(VkQueue q, VkCommandBuffer buf, VkFence done_fence);
 
-/* swapchain */
-VkSwapchainKHR vku_create_swapchain(VkSurfaceKHR surf, int xsz, int ysz, int n,
-               VkPresentModeKHR pmode, VkSwapchainKHR prev);
-VkImage *vku_get_swapchain_images(VkSwapchainKHR sc, int *count);
-VkImageView *vku_create_image_views(VkImage *images, int count);
+bool vku_get_surface_format(VkPhysicalDevice gpu, VkSurfaceKHR surface, VkSurfaceFormatKHR *sformat);
+VkColorSpaceKHR vku_get_surface_colorspace(VkPhysicalDevice gpu, VkSurfaceKHR surface);
+
 int vku_get_next_image(VkSwapchainKHR sc);
 void vku_present(VkSwapchainKHR sc, int img_idx);
 
-/* rederpass */
-bool vku_create_renderpass();
-
-/* framebuffer */
-bool vku_create_framebuffers(VkImageView *image_views, int count, int w, int h);
-
 /* buffers */
 vku_buffer *vku_create_buffer(int sz, unsigned int usage);
 void vku_destroy_buffer(vku_buffer *buf);
@@ -76,10 +69,5 @@ void vku_cmd_copybuf(VkCommandBuffer cmdbuf, VkBuffer dest, int doffs,
 /* other */
 const char *vku_get_vulkan_error_str(VkResult error);
 
-/* pipeline */
-bool vku_create_graphics_pipeline(VkPipelineLayout *layout);
-
-/* descriptor set */
-//bool vku_create_descriptor_set()
 
 #endif // VKUTIL_H_