light/modules/mirror/public/panels/asset_browser.hpp

48 lines
685 B
C++
Raw Normal View History

#pragma once
#include <filesystem>
2025-07-20 04:46:15 +03:30
#include <mirror/panels/panel.hpp>
#include <renderer/texture.hpp>
2025-07-11 00:05:48 +03:30
namespace lt {
2025-07-11 01:16:52 +03:30
class Scene;
class AssetBrowserPanel: public Panel
2022-03-06 22:25:23 +03:30
{
public:
2025-07-06 14:09:58 +03:30
AssetBrowserPanel(Ref<Scene> active_scene);
void on_user_interface_update();
2022-03-06 22:25:23 +03:30
private:
2022-03-12 21:10:23 +03:30
enum class AssetType
{
2025-07-06 14:09:58 +03:30
none = 0,
scene,
directory,
text,
image,
2022-03-06 22:25:23 +03:30
};
std::filesystem::path m_current_directory;
const std::filesystem::path m_assets_path;
2022-03-06 22:25:23 +03:30
2025-07-06 15:10:34 +03:30
float m_file_size = 128.0f;
2025-07-06 15:10:34 +03:30
float m_file_padding = 8.0f;
2022-03-06 22:25:23 +03:30
Ref<Scene> m_active_scene;
2022-03-12 21:10:23 +03:30
Ref<Texture> m_directory_texture;
Ref<Texture> m_scene_texture;
Ref<Texture> m_image_texture;
Ref<Texture> m_text_texture;
2022-03-06 22:25:23 +03:30
};
2025-07-11 00:05:48 +03:30
} // namespace lt