diff --git a/CMakeLists.txt b/CMakeLists.txt index d825412..03d97a2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -11,7 +11,20 @@ if(NOT ${OPENGL_GLU_FOUND}) endif() add_executable(tests_opengl - src/main.cpp src/displayers.h src/displayers.cpp src/DataHandling/Texture.cpp src/DataHandling/Texture.h src/DataHandling/Model3D.cpp src/DataHandling/Model3D.h src/types.h) + src/main.cpp + src/displayers.h + src/displayers.cpp + src/DataHandling/Texture.cpp + src/DataHandling/Texture.h + src/DataHandling/Model3D.cpp + src/DataHandling/Model3D.h + src/types.h) + +target_link_directories(tests_opengl PRIVATE + src) + +target_include_directories(tests_opengl PRIVATE + src) target_link_libraries(tests_opengl ${OPENGL_LIBRARIES} diff --git a/src/DataHandling/Model3D.cpp b/src/DataHandling/Model3D.cpp index 995811c..185eb13 100644 --- a/src/DataHandling/Model3D.cpp +++ b/src/DataHandling/Model3D.cpp @@ -11,7 +11,6 @@ Model3D::Model3D() : vertex_count(0), face_count(0), texture_count(0), is_textur Model3D::Model3D(const std::string& file_name) : Model3D() { load_ascii_off_file(file_name); - draw_model(); } Model3D::~Model3D() diff --git a/src/DataHandling/Model3D.h b/src/DataHandling/Model3D.h index f50bf34..43010c5 100644 --- a/src/DataHandling/Model3D.h +++ b/src/DataHandling/Model3D.h @@ -10,7 +10,7 @@ #include #include "GL/glut.h" -#include "../types.h" +#include "types.h" #include "Texture.h" class Model3D {