37 lines
730 B
C++
37 lines
730 B
C++
#ifndef HGL_VULKAN_RENDER_CONTEXT_INCLUDE
|
|
#define HGL_VULKAN_RENDER_CONTEXT_INCLUDE
|
|
|
|
#include<hgl/graph/VK.h>
|
|
#include<hgl/graph/VKSwapchain.h>
|
|
VK_NAMESPACE_BEGIN
|
|
/**
|
|
* äÖȾ¿ØÖÆÉÏÏÂÎÄ
|
|
*/
|
|
class RenderContext
|
|
{
|
|
protected:
|
|
|
|
VulkanDevice *device;
|
|
|
|
VkExtent2D extent;
|
|
|
|
public:
|
|
|
|
RenderContext(VulkanDevice *,const VkExtent2D &);
|
|
virtual ~RenderContext();
|
|
|
|
void Prepare(
|
|
};//class RenderContext
|
|
|
|
class RenderContextSwapchain:public RenderContext
|
|
{
|
|
Swapchain *swapchain;
|
|
|
|
public:
|
|
|
|
void RequestPresentMode(const VkPresentModeKHR present_mode);
|
|
void RequestImageFormat(const VkFormat format);
|
|
};//class RenderContextSwapchain:public RenderContext
|
|
VK_NAMESPACE_END
|
|
#endif//HGL_VULKAN_RENDER_CONTEXT_INCLUDE
|