summaryrefslogtreecommitdiff
path: root/src/device.h
diff options
context:
space:
mode:
authorkartofen <mladenovnasko0@gmail.com>2023-10-20 19:31:31 +0300
committerkartofen <mladenovnasko0@gmail.com>2023-10-20 19:31:31 +0300
commit5115eb592d1477b355770eee9d6b913481d4859f (patch)
treebad0ddf43cea533a91bd1fa36caf6942f1c97b21 /src/device.h
parent22128c747e0817f09c11b004016e6d7c518c1523 (diff)
graphics pipeline
Diffstat (limited to 'src/device.h')
-rw-r--r--src/device.h21
1 files changed, 18 insertions, 3 deletions
diff --git a/src/device.h b/src/device.h
index 3491b8a..05bdbc1 100644
--- a/src/device.h
+++ b/src/device.h
@@ -19,14 +19,29 @@ typedef struct device {
VkPhysicalDevice physical_device;
VkDevice logical_device;
+
VkQueue graphics_queue;
VkQueue present_queue;
- VkSwapchainKHR swap_chain;
VkSurfaceKHR surface;
+
+ struct swap_chain {
+ VkSwapchainKHR swap_chain;
+
+ VkImage *images;
+ VkImageView *image_views;
+ u32 nimages;
+
+ VkFormat image_format;
+ VkExtent2D extent;
+ } swap_chain;
+
+ struct pipeline {
+ VkRenderPass render_pass;
+ VkPipelineLayout layout;
+ VkPipeline pipeline;
+ } pipeline;
- VkImage *swap_chain_images;
- u32 nimages;
} * device_t;
struct device_info {