Add renderer shader uniform command

This commit is contained in:
2026-06-02 16:15:23 +02:00
parent 23c308db1b
commit 8232b0efc8
9 changed files with 189 additions and 21 deletions

View File

@@ -14,6 +14,7 @@ enum class RecordedRenderCommandKind : std::uint8_t {
set_blend_state,
set_depth_state,
bind_shader,
set_shader_uniform,
bind_texture,
bind_sampler,
bind_mesh,
@@ -50,6 +51,7 @@ struct RecordedRenderCommand {
std::uint64_t capture_bytes = 0;
std::uint64_t blit_source_bytes = 0;
std::uint64_t blit_destination_bytes = 0;
std::uint64_t uniform_bytes = 0;
const char* component = "";
const char* name = "";
};
@@ -111,6 +113,9 @@ public:
[[nodiscard]] pp::foundation::Status set_blend_state(BlendState state) noexcept override;
[[nodiscard]] pp::foundation::Status set_depth_state(DepthState state) noexcept override;
[[nodiscard]] pp::foundation::Status bind_shader(IShaderProgram& shader) noexcept override;
[[nodiscard]] pp::foundation::Status set_shader_uniform(
const char* name,
std::span<const std::byte> bytes) noexcept override;
[[nodiscard]] pp::foundation::Status bind_texture(
std::uint32_t slot,
ITexture2D& texture) noexcept override;