some decouplings (#2)

* logger business

* code review

* rm c-style array

* extract image rendering to view

* missing view files

* init view abstractions

* leverage concepts and provide a templateized Enumerate function

* RVO

* get rid of some warnings

* logger business

* code review

* rm c-style array

* extract image rendering to view

* missing view files

* init view abstractions

* leverage concepts and provide a templateized Enumerate function

* RVO

* get rid of some warnings

* logger business

* code review

* rm c-style array

* init view abstractions

* leverage concepts and provide a templateized Enumerate function

* RVO

* get rid of some warnings

* logger business

* code review

* rm c-style array

* init view abstractions

* leverage concepts and provide a templateized Enumerate function

* RVO

* get rid of some warnings

* Factor out AppGLFW base class

The intention here is to get rid of scaffolding in the consumer
application class and allow to focus on the "important bits".

* Some cleanup

* dump unnecessary dependency

* link stuff where needed & use only what's needed

* remove deprecation warnings

* add gallery toggle

* make some includes private

* add presets

* remove dir locals, use presets instead

`projectile-configure-project' in conjunction with CMakePresets.json
will allow to configure the project.
`projectile-compile-project' does sth similar for the compile command.

This is equivalent to something like
~cmake --preset clang-debug && cmake --build build --preset clang-debug~

* use presets in pipeline

---------

Co-authored-by: m-aXimilian <keuffnermax@gmail.com>
This commit is contained in:
m-aXimilian
2025-08-18 22:39:43 +00:00
committed by GitHub
parent 566dd112ff
commit d71f4168fb
30 changed files with 548 additions and 259 deletions
+15 -3
View File
@@ -82,9 +82,21 @@ TEST(ImageResourcePoolTest, EnumerateResources)
auto id2 = pool.SetResource(std::make_unique<DummyImage>());
std::vector<size_t> found_ids{};
std::function<void(size_t, const pixelarium::imaging::PixelariumImage&)> func =
[&found_ids](size_t id, const pixelarium::imaging::PixelariumImage&) { found_ids.push_back(id); };
pool.EnumerateResources(func);
pool.EnumerateResources([&found_ids](size_t id, const pixelarium::imaging::PixelariumImage&) { found_ids.push_back(id); });
EXPECT_EQ(found_ids.size(), 2);
EXPECT_NE(std::find(found_ids.begin(), found_ids.end(), id1), found_ids.end());
EXPECT_NE(std::find(found_ids.begin(), found_ids.end(), id2), found_ids.end());
}
TEST(ImageResourcePoolTest, TemplatedEnumerate)
{
ImageResourcePool pool;
auto id1 = pool.SetResource(std::make_unique<DummyImage>());
auto id2 = pool.SetResource(std::make_unique<DummyImage>());
std::vector<size_t> found_ids{};
pool.Enumerate([&found_ids](size_t id, const pixelarium::imaging::PixelariumImage&) { found_ids.push_back(id); });
EXPECT_EQ(found_ids.size(), 2);
EXPECT_NE(std::find(found_ids.begin(), found_ids.end(), id1), found_ids.end());