14 ev.
on_os_event.connect(sentinel_, 1000,
this, &imgui_interface::on_os_event);
15 ev.on_frame_render.connect(sentinel_, -100000,
this, &imgui_interface::on_frame_ui_render);
28 APPLOG_TRACE(
"{}::{}", hpp::type_name_str(*
this), __func__);
30 const auto& rend = ctx.get_cached<
renderer>();
40 APPLOG_TRACE(
"{}::{}", hpp::type_name_str(*
this), __func__);
45void imgui_interface::on_os_event(
rtti::context& ctx, os::event& e)
55 const auto& main_window = rend.get_main_window();
56 const auto& main_surface = main_window->get_surface();
60 ev.on_frame_ui_render(ctx, dt);
63 pass.bind(main_surface.get());
imgui_interface(rtti::context &ctx)
auto deinit(rtti::context &ctx) -> bool
auto init(rtti::context &ctx) -> bool
std::chrono::duration< float > delta_t
void imguiCreate(unravel::render_window *window, float _fontSize, bx::AllocatorI *_allocator)
void imguiProcessEvent(os::event &e)
void imguiBeginFrame(float dt)
void imguiEndFrame(gfx::view_id id)
#define APPLOG_TRACE(...)
hpp::event< void(rtti::context &, os::event &e)> on_os_event
os events
auto get_main_window() const -> render_window *