mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-01 22:58:38 -04:00
render/vulkan: make shm/dmabuf split clearer in wlr_vk_format_props
struct wlr_vk_format_props contains a mix of properties for shm and dmabuf, and it's not immediately clear which fields are for which kind of buffer. Use a nested struct to group the fields.
This commit is contained in:
parent
db9d277614
commit
337ef33edc
2 changed files with 36 additions and 30 deletions
|
|
@ -96,14 +96,19 @@ struct wlr_vk_format_modifier_props {
|
|||
|
||||
struct wlr_vk_format_props {
|
||||
struct wlr_vk_format format;
|
||||
VkExtent2D max_extent; // relevant if not created as dma_buf
|
||||
VkFormatFeatureFlags features; // relevant if not created as dma_buf
|
||||
|
||||
uint32_t render_mod_count;
|
||||
struct wlr_vk_format_modifier_props *render_mods;
|
||||
struct {
|
||||
VkExtent2D max_extent;
|
||||
VkFormatFeatureFlags features;
|
||||
} shm;
|
||||
|
||||
uint32_t texture_mod_count;
|
||||
struct wlr_vk_format_modifier_props *texture_mods;
|
||||
struct {
|
||||
uint32_t render_mod_count;
|
||||
struct wlr_vk_format_modifier_props *render_mods;
|
||||
|
||||
uint32_t texture_mod_count;
|
||||
struct wlr_vk_format_modifier_props *texture_mods;
|
||||
} dmabuf;
|
||||
};
|
||||
|
||||
void vulkan_format_props_query(struct wlr_vk_device *dev,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue