diff options
author | Frederico Linhares <fred@linhares.blue> | 2024-05-08 17:56:29 -0300 |
---|---|---|
committer | Frederico Linhares <fred@linhares.blue> | 2024-05-08 17:56:29 -0300 |
commit | 43821b0cffc5aa419c0218992f06f8962ae54a13 (patch) | |
tree | 97bdbbf710a78e6dcb181d92dd83e98d8b329c6d /src/view_3d.cpp | |
parent | 70e156d47346ae3198c623e0af75e5703f894db3 (diff) |
refa Rename graphical engine to BluCat
Diffstat (limited to 'src/view_3d.cpp')
-rw-r--r-- | src/view_3d.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/view_3d.cpp b/src/view_3d.cpp index 7db0015..ddaa3eb 100644 --- a/src/view_3d.cpp +++ b/src/view_3d.cpp @@ -20,13 +20,13 @@ #include "orientation_3d.hpp" #include "vector_3d.hpp" #include "vector_4d.hpp" -#include "vk/sprite.hpp" -#include "vk/view_3d.hpp" +#include "blucat/sprite.hpp" +#include "blucat/view_3d.hpp" void cg_free_view_3d(mrb_state *mrb, void* obj) { - auto ptr = static_cast<std::shared_ptr<VK::View3D>*>(obj); + auto ptr = static_cast<std::shared_ptr<BluCat::View3D>*>(obj); ptr->~shared_ptr(); mrb_free(mrb, ptr); @@ -39,17 +39,17 @@ cg_cView3D_initialize(mrb_state *mrb, mrb_value self) { std::shared_ptr<glm::vec4> *region; mrb_float projection_width, projection_height; - std::shared_ptr<VK::View3D> *ptr; + std::shared_ptr<BluCat::View3D> *ptr; mrb_get_args(mrb, "dff", ®ion, &cg_vector_4d_type, &projection_width, &projection_height); - ptr = (std::shared_ptr<VK::View3D>*)DATA_PTR(self); + ptr = (std::shared_ptr<BluCat::View3D>*)DATA_PTR(self); if(ptr) mrb_free(mrb, ptr); - ptr = (std::shared_ptr<VK::View3D>*)mrb_malloc( - mrb, sizeof(std::shared_ptr<VK::View3D>)); + ptr = (std::shared_ptr<BluCat::View3D>*)mrb_malloc( + mrb, sizeof(std::shared_ptr<BluCat::View3D>)); - new(ptr)std::shared_ptr<VK::View3D>( - std::make_shared<VK::View3D>( + new(ptr)std::shared_ptr<BluCat::View3D>( + std::make_shared<BluCat::View3D>( *region->get(), projection_width, projection_height)); mrb_data_init(self, ptr, &cg_view_3d_type); @@ -60,7 +60,7 @@ static mrb_value cg_cView3D_set_camera_position(mrb_state *mrb, mrb_value self) { std::shared_ptr<glm::vec3> *camera_position; - auto ptr = (std::shared_ptr<VK::View3D>*)DATA_PTR(self); + auto ptr = (std::shared_ptr<BluCat::View3D>*)DATA_PTR(self); mrb_get_args(mrb, "d", &camera_position, &cg_vector_3d_type); (*ptr)->camera_position = (*camera_position); @@ -72,7 +72,7 @@ static mrb_value cg_cView3D_set_camera_orientation(mrb_state *mrb, mrb_value self) { std::shared_ptr<glm::quat> *camera_orientation; - auto ptr = (std::shared_ptr<VK::View3D>*)DATA_PTR(self); + auto ptr = (std::shared_ptr<BluCat::View3D>*)DATA_PTR(self); mrb_get_args(mrb, "d", &camera_orientation, &cg_orientation_3d_type); (*ptr)->camera_orientation = (*camera_orientation); @@ -83,7 +83,7 @@ cg_cView3D_set_camera_orientation(mrb_state *mrb, mrb_value self) static mrb_value cg_cView3D_get_field_of_view(mrb_state *mrb, mrb_value self) { - auto ptr = (std::shared_ptr<VK::View3D>*)DATA_PTR(self); + auto ptr = (std::shared_ptr<BluCat::View3D>*)DATA_PTR(self); return mrb_float_value(mrb, (*ptr)->field_of_view); @@ -94,7 +94,7 @@ static mrb_value cg_cView3D_set_field_of_view(mrb_state *mrb, mrb_value self) { mrb_float fov; - auto ptr = (std::shared_ptr<VK::View3D>*)DATA_PTR(self); + auto ptr = (std::shared_ptr<BluCat::View3D>*)DATA_PTR(self); mrb_get_args(mrb, "f", &fov); (*ptr)->field_of_view = fov; |