Unravel Engine C++ Reference
Loading...
Searching...
No Matches
unravel::scene_panel Class Reference

#include <scene_panel.h>

Inheritance diagram for unravel::scene_panel:
unravel::entity_panel unravel::panel_base

Public Member Functions

 scene_panel (imgui_panels *parent, const char *name)
 
void init (rtti::context &ctx)
 
auto get_window_name () const -> const char *override
 
void deinit (rtti::context &ctx)
 
void on_frame_update (rtti::context &ctx, delta_t dt)
 
void on_frame_render (rtti::context &ctx, delta_t dt)
 
void on_frame_before_render (rtti::context &ctx, delta_t dt)
 
auto get_window_flags () const -> ImGuiWindowFlags override
 
auto get_camera () -> entt::handle
 
auto get_center () -> entt::handle
 
void reset_camera (rtti::context &ctx)
 Recreate the Scene panel editor camera at the default pose (UI "Reset Camera").
 
auto get_auto_save_prefab () const -> bool
 
void on_project_opened ()
 
auto is_drag_selection_active () const -> bool
 
auto get_drag_selection_rect () const -> ImRect
 
auto get_drag_selection_bounds () const -> std::pair< ImVec2, ImVec2 >
 
- Public Member Functions inherited from unravel::entity_panel
 entity_panel (imgui_panels *parent, const char *name)
 
virtual ~entity_panel ()=default
 
void duplicate_entities (const std::vector< entt::handle > &entities)
 
void focus_entities (entt::handle camera, const std::vector< entt::handle > &entities)
 
void delete_entities (const std::vector< entt::handle > &entities)
 
- Public Member Functions inherited from unravel::panel_base
 panel_base (const char *name)
 
virtual ~panel_base ()=default
 
auto is_visible () const -> bool
 
void set_visible (bool visible)
 
auto is_focused () const -> bool
 
auto is_fullscreen () const -> bool
 
void set_fullscreen (bool fullscreen)
 
void toggle_fullscreen ()
 
void focus ()
 
void on_frame_ui_render (rtti::context &ctx)
 
auto get_name () const -> const std::string &
 

Additional Inherited Members

- Static Public Member Functions inherited from unravel::entity_panel
static auto get_entity_name (entt::handle entity) -> std::string
 Gets the entity name from tag component.
 
static auto get_entity_icon (entt::handle entity) -> std::string
 
static auto get_entity_display_color (entt::handle entity) -> ImVec4
 
- Protected Member Functions inherited from unravel::panel_base
void render_panel (rtti::context &ctx, const char *name, ImGuiWindowFlags flags=ImGuiWindowFlags_MenuBar)
 
virtual void on_before_render (rtti::context &ctx)
 
virtual void on_after_render (rtti::context &ctx)
 
virtual void end_panel (const char *name)
 
- Protected Attributes inherited from unravel::entity_panel
imgui_panelsparent_ {}
 
- Protected Attributes inherited from unravel::panel_base
std::string name_
 
std::string name_fullscreen_
 
bool is_visible_ {}
 
bool is_focused_ {}
 
bool is_fullscreen_ {}
 
bool request_focus_ {}
 

Detailed Description

Definition at line 11 of file scene_panel.h.

Constructor & Destructor Documentation

◆ scene_panel()

unravel::scene_panel::scene_panel ( imgui_panels * parent,
const char * name )

Definition at line 1277 of file scene_panel.cpp.

Member Function Documentation

◆ deinit()

void unravel::scene_panel::deinit ( rtti::context & ctx)

Definition at line 1300 of file scene_panel.cpp.

◆ get_auto_save_prefab()

auto unravel::scene_panel::get_auto_save_prefab ( ) const -> bool

Definition at line 1525 of file scene_panel.cpp.

◆ get_camera()

auto unravel::scene_panel::get_camera ( ) -> entt::handle

Definition at line 1491 of file scene_panel.cpp.

◆ get_center()

auto unravel::scene_panel::get_center ( ) -> entt::handle

Definition at line 1512 of file scene_panel.cpp.

◆ get_drag_selection_bounds()

auto unravel::scene_panel::get_drag_selection_bounds ( ) const -> std::pair<ImVec2, ImVec2>
inline

Definition at line 40 of file scene_panel.h.

◆ get_drag_selection_rect()

auto unravel::scene_panel::get_drag_selection_rect ( ) const -> ImRect
inline

Definition at line 39 of file scene_panel.h.

◆ get_window_flags()

auto unravel::scene_panel::get_window_flags ( ) const -> ImGuiWindowFlags
overridevirtual

Reimplemented from unravel::panel_base.

Definition at line 1480 of file scene_panel.cpp.

◆ get_window_name()

auto unravel::scene_panel::get_window_name ( ) const -> const char*
overridevirtual

Reimplemented from unravel::panel_base.

Definition at line 1283 of file scene_panel.cpp.

◆ init()

void unravel::scene_panel::init ( rtti::context & ctx)

Definition at line 1288 of file scene_panel.cpp.

◆ is_drag_selection_active()

auto unravel::scene_panel::is_drag_selection_active ( ) const -> bool
inline

Definition at line 38 of file scene_panel.h.

◆ on_frame_before_render()

void unravel::scene_panel::on_frame_before_render ( rtti::context & ctx,
delta_t dt )

Definition at line 1411 of file scene_panel.cpp.

◆ on_frame_render()

void unravel::scene_panel::on_frame_render ( rtti::context & ctx,
delta_t dt )

Definition at line 1454 of file scene_panel.cpp.

◆ on_frame_update()

void unravel::scene_panel::on_frame_update ( rtti::context & ctx,
delta_t dt )

Definition at line 1392 of file scene_panel.cpp.

◆ on_project_opened()

void unravel::scene_panel::on_project_opened ( )

Definition at line 1475 of file scene_panel.cpp.

◆ reset_camera()

void unravel::scene_panel::reset_camera ( rtti::context & ctx)

Recreate the Scene panel editor camera at the default pose (UI "Reset Camera").

Definition at line 1502 of file scene_panel.cpp.


The documentation for this class was generated from the following files: