diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2023-04-09 23:14:37 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2023-04-09 23:14:37 +0200 |
commit | 3212ca62361da55e8eec4cb97ee1698b534daad6 (patch) | |
tree | 265b091306419191d3f8e862f07f2d469d5cbf50 | |
parent | 1189ab4d0144051228eb4265ed0777e0e4c2e5cd (diff) |
remove some obsolete todo's
-rw-r--r-- | main/draw.cpp | 13 | ||||
-rw-r--r-- | main/main-impl.hpp | 1 | ||||
-rw-r--r-- | src/entity.cpp | 3 |
3 files changed, 1 insertions, 16 deletions
diff --git a/main/draw.cpp b/main/draw.cpp index 1a46d4f6..f388b60e 100644 --- a/main/draw.cpp +++ b/main/draw.cpp @@ -62,7 +62,6 @@ void main_impl::recalc_viewport(Vector2i fb_size, Vector2i win_size) noexcept // -- user-- app.on_viewport_event(fb_size); - update_collect_threshold(); } global_coords main_impl::pixel_to_tile(Vector2d position) const noexcept @@ -104,18 +103,6 @@ auto main_impl::get_draw_bounds() const noexcept -> draw_bounds return {x0, x1, y0, y1}; } -void main_impl::update_collect_threshold() -{ - // todo remove it? -#if 0 - const auto [minx, maxx, miny, maxy] = get_draw_bounds(); - const auto value = std::max(64uz, (size_t)(maxx-minx+4)*(size_t)(maxy-minx+4)); - if (!(GL::Context::current().configurationFlags() & GL::Implementation::ContextConfigurationFlag::QuietLog)) - fm_debug("collect threshold is now %zu", value); - _world.set_collect_threshold(value); -#endif -} - void main_impl::draw_world() noexcept { const auto [z_min, z_max] = app.get_z_bounds(); diff --git a/main/main-impl.hpp b/main/main-impl.hpp index 859f2a8f..20b1aa41 100644 --- a/main/main-impl.hpp +++ b/main/main-impl.hpp @@ -114,7 +114,6 @@ private: void recalc_viewport(Vector2i fb_size, Vector2i win_size) noexcept; void draw_world() noexcept; - void update_collect_threshold(); draw_bounds get_draw_bounds() const noexcept override; diff --git a/src/entity.cpp b/src/entity.cpp index 3f5c67be..f382db75 100644 --- a/src/entity.cpp +++ b/src/entity.cpp @@ -94,8 +94,7 @@ bool entity::can_rotate(rotation new_r) void entity::rotate(size_t, rotation new_r) { fm_assert(atlas->check_rotation(new_r)); - // todo normalize coords - auto offset_ = !is_dynamic() ? rotate_point(offset, r, new_r) : offset; // todo add boolean for this condition + auto offset_ = !is_dynamic() ? rotate_point(offset, r, new_r) : offset; auto bbox_offset_ = rotate_point(bbox_offset, r, new_r); auto bbox_size_ = rotate_size(bbox_size, r, new_r); set_bbox(offset_, bbox_offset_, bbox_size_, pass); |