diff --git a/CMakeLists.txt b/CMakeLists.txt index 3998817..afc7036 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.25) -project(graphs VERSION 0.0.28) +project(graphs VERSION 0.0.29) option(ENABLE_ADDRSAN "Enable the address sanitizer" OFF) option(ENABLE_UBSAN "Enable the ub sanitizer" OFF) diff --git a/lib/BLT-With-Graphics-Template b/lib/BLT-With-Graphics-Template index fa2b314..7c61323 160000 --- a/lib/BLT-With-Graphics-Template +++ b/lib/BLT-With-Graphics-Template @@ -1 +1 @@ -Subproject commit fa2b31445381fabae5afa5bbbc2b8204dd474333 +Subproject commit 7c61323a05084e46ee8787750caa6f52aa9a099d diff --git a/src/main.cpp b/src/main.cpp index d2313e7..bb2da0b 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -34,7 +34,7 @@ blt::gfx::matrix_state_manager global_matrices; blt::gfx::resource_manager resources; -blt::gfx::batch_renderer_2d renderer_2d(resources); +blt::gfx::batch_renderer_2d renderer_2d(resources, global_matrices); blt::gfx::first_person_camera_2d camera; blt::u64 lastTime; double ft = 0; @@ -227,7 +227,7 @@ class graph_t for (const auto& point : nodes) { - auto draw_info = blt::gfx::render_info_t::make_info("parker_point", blt::make_color(1, 1, 1)); + auto draw_info = blt::gfx::render_info_t::make_info("parker_point", blt::make_color(0, 1, 1)); renderer_2d.drawPointInternal(draw_info, point.getRenderObj(), 10.0f); } for (const auto& edge : edges) @@ -239,7 +239,8 @@ class graph_t { auto n1 = nodes[edge.getFirst()]; auto n2 = nodes[edge.getSecond()]; - renderer_2d.drawLine(blt::make_color(0, 1, 0), 5.0f, n1.getRenderObj().pos, n2.getRenderObj().pos, 2.0f); + auto draw_info = blt::gfx::render_info_t::make_info(blt::make_color(0, 1, 0), blt::make_color(1, 0, 0)); + renderer_2d.drawLine(draw_info, 5.0f, n1.getRenderObj().pos, n2.getRenderObj().pos, 2.0f); } } }