mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-13 03:29:11 +00:00
VideoBackends / VideoCommon: refactor Vulkan to use new SPIRV functionality
This commit is contained in:
parent
c2d3b7e7f5
commit
dda1479ecf
5 changed files with 49 additions and 213 deletions
|
@ -8,7 +8,10 @@
|
|||
#include <string_view>
|
||||
#include <vector>
|
||||
|
||||
#include "ShaderLang.h"
|
||||
|
||||
#include "Common/CommonTypes.h"
|
||||
#include "VideoCommon/VideoCommon.h"
|
||||
|
||||
namespace SPIRV
|
||||
{
|
||||
|
@ -17,14 +20,18 @@ using CodeType = u32;
|
|||
using CodeVector = std::vector<CodeType>;
|
||||
|
||||
// Compile a vertex shader to SPIR-V.
|
||||
std::optional<CodeVector> CompileVertexShader(std::string_view source_code);
|
||||
std::optional<CodeVector> CompileVertexShader(std::string_view source_code, APIType api_type,
|
||||
glslang::EShTargetLanguageVersion language_version);
|
||||
|
||||
// Compile a geometry shader to SPIR-V.
|
||||
std::optional<CodeVector> CompileGeometryShader(std::string_view source_code);
|
||||
std::optional<CodeVector> CompileGeometryShader(std::string_view source_code, APIType api_type,
|
||||
glslang::EShTargetLanguageVersion language_version);
|
||||
|
||||
// Compile a fragment shader to SPIR-V.
|
||||
std::optional<CodeVector> CompileFragmentShader(std::string_view source_code);
|
||||
std::optional<CodeVector> CompileFragmentShader(std::string_view source_code, APIType api_type,
|
||||
glslang::EShTargetLanguageVersion language_version);
|
||||
|
||||
// Compile a compute shader to SPIR-V.
|
||||
std::optional<CodeVector> CompileComputeShader(std::string_view source_code);
|
||||
std::optional<CodeVector> CompileComputeShader(std::string_view source_code, APIType api_type,
|
||||
glslang::EShTargetLanguageVersion language_version);
|
||||
} // namespace SPIRV
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue