mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-25 15:19:42 -06:00
Renderer: Add backbuffer format to base class
This commit is contained in:
@ -10,6 +10,7 @@
|
||||
#include "Common/CommonTypes.h"
|
||||
#include "VideoBackends/Vulkan/Constants.h"
|
||||
#include "VideoBackends/Vulkan/Texture2D.h"
|
||||
#include "VideoCommon/TextureConfig.h"
|
||||
|
||||
namespace Vulkan
|
||||
{
|
||||
@ -33,10 +34,10 @@ public:
|
||||
void* GetNativeHandle() const { return m_native_handle; }
|
||||
VkSurfaceKHR GetSurface() const { return m_surface; }
|
||||
VkSurfaceFormatKHR GetSurfaceFormat() const { return m_surface_format; }
|
||||
AbstractTextureFormat GetTextureFormat() const { return m_texture_format; }
|
||||
bool IsVSyncEnabled() const { return m_vsync_enabled; }
|
||||
bool IsStereoEnabled() const { return m_layers == 2; }
|
||||
VkSwapchainKHR GetSwapChain() const { return m_swap_chain; }
|
||||
VkRenderPass GetRenderPass() const { return m_render_pass; }
|
||||
u32 GetWidth() const { return m_width; }
|
||||
u32 GetHeight() const { return m_height; }
|
||||
u32 GetCurrentImageIndex() const { return m_current_swap_chain_image_index; }
|
||||
@ -69,8 +70,6 @@ private:
|
||||
bool CreateSwapChain();
|
||||
void DestroySwapChain();
|
||||
|
||||
bool CreateRenderPass();
|
||||
|
||||
bool SetupSwapChainImages();
|
||||
void DestroySwapChainImages();
|
||||
|
||||
@ -88,14 +87,13 @@ private:
|
||||
VkSurfaceKHR m_surface = VK_NULL_HANDLE;
|
||||
VkSurfaceFormatKHR m_surface_format = {};
|
||||
VkPresentModeKHR m_present_mode = VK_PRESENT_MODE_RANGE_SIZE_KHR;
|
||||
AbstractTextureFormat m_texture_format = AbstractTextureFormat::Undefined;
|
||||
bool m_vsync_enabled;
|
||||
|
||||
VkSwapchainKHR m_swap_chain = VK_NULL_HANDLE;
|
||||
std::vector<SwapChainImage> m_swap_chain_images;
|
||||
u32 m_current_swap_chain_image_index = 0;
|
||||
|
||||
VkRenderPass m_render_pass = VK_NULL_HANDLE;
|
||||
|
||||
u32 m_width = 0;
|
||||
u32 m_height = 0;
|
||||
u32 m_layers = 0;
|
||||
|
Reference in New Issue
Block a user