rendering: unify builtin forward and depth-style shaders

This commit is contained in:
2026-04-07 03:35:06 +08:00
parent 503ffbc4ff
commit 5f9f3386ab
27 changed files with 1135 additions and 1151 deletions

View File

@@ -1,6 +1,7 @@
#pragma once
#include <d3d12.h>
#include <d3dcompiler.h>
#include <dxgi1_4.h>
#include <wrl/client.h>
#include <string>
@@ -22,6 +23,12 @@ public:
bool CompileFromFile(const wchar_t* filePath, const char* entryPoint, const char* target) override;
bool Compile(const void* sourceData, size_t sourceSize, const char* entryPoint, const char* target) override;
bool Compile(
const void* sourceData,
size_t sourceSize,
const D3D_SHADER_MACRO* macros,
const char* entryPoint,
const char* target);
void Shutdown() override;
const D3D12_SHADER_BYTECODE GetD3D12Bytecode() const;
@@ -48,4 +55,4 @@ private:
};
} // namespace RHI
} // namespace XCEngine
} // namespace XCEngine