gtk/gsk/gskvulkanrenderprivate.h
Benjamin Otte b3a1732a3e vulkan: Redo descriptor set handling
First, we collect all the info about descriptor sets into a hash table,
then we use its size to determine the amount of sets and allocate those
before we finally go ahead and use the hash table's contents to
initialize the descriptor sets.

And then we're ready to render.
2016-12-09 18:35:52 +01:00

53 lines
2.4 KiB
C

#ifndef __GSK_VULKAN_RENDER_PRIVATE_H__
#define __GSK_VULKAN_RENDER_PRIVATE_H__
#include <gdk/gdk.h>
#include <gsk/gskrendernode.h>
#include "gsk/gskvulkanimageprivate.h"
#include "gsk/gskvulkanpipelineprivate.h"
G_BEGIN_DECLS
typedef struct _GskVulkanRender GskVulkanRender;
typedef struct _GskVulkanVertex GskVulkanVertex;
struct _GskVulkanVertex
{
float x;
float y;
float tex_x;
float tex_y;
};
GskVulkanRender * gsk_vulkan_render_new (GskRenderer *renderer,
GdkVulkanContext *context);
void gsk_vulkan_render_free (GskVulkanRender *self);
gboolean gsk_vulkan_render_is_busy (GskVulkanRender *self);
void gsk_vulkan_render_reset (GskVulkanRender *self,
GskVulkanImage *target);
GskRenderer * gsk_vulkan_render_get_renderer (GskVulkanRender *self);
void gsk_vulkan_render_add_cleanup_image (GskVulkanRender *self,
GskVulkanImage *image);
void gsk_vulkan_render_add_node (GskVulkanRender *self,
GskRenderNode *node);
void gsk_vulkan_render_upload (GskVulkanRender *self);
VkDescriptorSet gsk_vulkan_render_get_descriptor_set (GskVulkanRender *self,
gsize id);
gsize gsk_vulkan_render_reserve_descriptor_set (GskVulkanRender *self,
GskVulkanImage *source);
void gsk_vulkan_render_draw (GskVulkanRender *self,
VkSampler sampler);
void gsk_vulkan_render_submit (GskVulkanRender *self);
G_END_DECLS
#endif /* __GSK_VULKAN_RENDER_PRIVATE_H__ */