remove legacy background loading

This commit is contained in:
jerrrrycho
2026-01-29 08:06:49 +01:00
parent ba6d3c09f2
commit 45889a40a1
4 changed files with 0 additions and 17 deletions

View File

@@ -129,20 +129,6 @@ bool ui_layer::mouse_button_callback(int button, int action, int mods)
return m_imguiio->WantCaptureMouse;
}
void ui_layer::load_random_background()
{
std::vector<std::string> images;
for (auto &f : std::filesystem::directory_iterator("textures/logo"))
if (f.is_regular_file())
images.emplace_back(std::filesystem::relative(f.path(), "textures/").string());
if (!images.empty())
{
std::string &selected = images[std::lround(LocalRandom(images.size() - 1))];
set_background(selected);
}
}
static ImVec4 imvec_lerp(const ImVec4 &a, const ImVec4 &b, float t)
{
return ImVec4(a.x + (b.x - a.x) * t, a.y + (b.y - a.y) * t, a.z + (b.z - a.z) * t, a.w + (b.w - a.w) * t);