Files
portersky 40ae94788e style: fix include ordering across all source files
- C++ std headers first, then third-party, then local
- Apply consistently in cbt/ and scenes/
2026-05-05 22:40:51 +02:00

31 lines
585 B
C++

#pragma once
#include <array>
#include <optional>
#include <vector>
#include "cbt/opengl/buffer.hpp"
#include "cbt/opengl/texture.hpp"
namespace cbt::opengl {
struct descriptor_binding {
GLuint texture_unit = 0;
std::optional<texture> tex;
std::optional<buffer> buf;
};
class descriptor_set {
public:
descriptor_set();
auto add_texture(texture tex, GLuint unit = 0) -> void;
auto add_buffer(buffer buf, GLuint unit = 0) -> void;
auto bind_all() -> void;
auto count() const -> size_t;
private:
std::vector<descriptor_binding> m_bindings;
};
}