9#include <vulkan/vulkan.hpp>
12#include "SD/export.hpp"
19template<
typename T>
concept IsLayer = std::is_base_of_v<Layer, T>;
33 m_debug_name(name), m_scene(
scene), m_stage_id(0), m_view_id{} {}
43 const std::string&
get_name()
const {
return m_debug_name; }
58 bool m_is_active =
true;
Base class for all layers. Prefer using System, RenderStage, or Panel instead.
Definition Layer.hpp:28
virtual void on_event(Event &)
Definition Layer.hpp:48
virtual void on_im_gui_menu_bar()
Definition Layer.hpp:53
ViewId m_view_id
Definition Layer.hpp:62
int m_stage_id
Definition Layer.hpp:61
Layer(const std::string &name="Layer", Scene *scene=nullptr)
Definition Layer.hpp:32
virtual void on_fixed_update(double fixedDelta)
Definition Layer.hpp:49
const std::string & get_name() const
Definition Layer.hpp:43
bool is_active() const noexcept
Definition Layer.hpp:55
virtual void on_activate()
Definition Layer.hpp:38
virtual void on_update(float dt)
Definition Layer.hpp:50
std::string m_debug_name
Definition Layer.hpp:59
virtual void on_deactivate()
Definition Layer.hpp:39
virtual void on_render(vk::CommandBuffer cmd)
Definition Layer.hpp:51
virtual void on_attach()
Definition Layer.hpp:35
void set_scene(Scene *scene)
Definition Layer.hpp:45
Scene * get_scene() const
Definition Layer.hpp:46
virtual void on_swapchain_recreated()
Definition Layer.hpp:41
virtual void on_detach()
Definition Layer.hpp:36
virtual void on_gui_render()
Definition Layer.hpp:52
ImGui UI layer: panels, inspectors, debug tools. No GPU rendering.
Definition Layer.hpp:103
void on_swapchain_recreated() final
Definition Layer.hpp:112
void on_render(vk::CommandBuffer) final
Definition Layer.hpp:111
GPU command recording layer: bound to a View + render stage. No logic or UI.
Definition Layer.hpp:88
void on_gui_render() final
Definition Layer.hpp:98
void on_update(float) final
Definition Layer.hpp:96
void on_fixed_update(double) final
Definition Layer.hpp:97
void on_im_gui_menu_bar() final
Definition Layer.hpp:99
Logic-only layer: events, update, fixed update. No rendering or UI.
Definition Layer.hpp:73
void on_render(vk::CommandBuffer) final
Definition Layer.hpp:81
void on_swapchain_recreated() final
Definition Layer.hpp:84
void on_gui_render() final
Definition Layer.hpp:82
void on_im_gui_menu_bar() final
Definition Layer.hpp:83
Definition Application.hpp:28
Definition id_types.hpp:7
constexpr T g_type_max
Definition types.hpp:21