diff --git a/Sources/src/Visnode/CMakeLists.txt b/Sources/src/Visnode/CMakeLists.txt index 33ee687..6c04341 100644 --- a/Sources/src/Visnode/CMakeLists.txt +++ b/Sources/src/Visnode/CMakeLists.txt @@ -1,16 +1,20 @@ cmake_minimum_required(VERSION 3.22) set(CMAKE_CXX_STANDARD 17) +SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g") project(visnode) +#set(CMAKE_BINARY_DIR ${CMAKE_SOURCE_DIR}/../bin) +set(CMAKE_BINARY_DIR /home/kanken/code/project-/Sources/src/Visnode/) find_package(OpenCV REQUIRED) #SET("OpenCV_DIR" "/usr/local/lib/") include_directories(${OpenCV_INCLUDE_DIRS} ) -link_directories(${Opencv_LINK_DIRS}) +link_directories(${CMAKE_BINARY_DIR}) +MESSAGE(STATUS "OpenCV_INCLUDE_DIRS : ${OpenCV_INCLUDE_DIRS}") +MESSAGE(STATUS "Opencv_LINK_DIRS : ${Opencv_LINK_DIRS}") -set(CMAKE_BINARY_DIR ${CMAKE_SOURCE_DIR}/../bin) set(EXECUTABLE_OUTPUT_PATH ${CMAKE_BINARY_DIR}) add_subdirectory(threadweaver) @@ -28,6 +32,5 @@ MESSAGE(STATUS "CMAKE FLAGS : ${LINK_OPTIONS}") target_link_libraries(prog hw) - SET(GCC_COVERAGE_COMPILE_FLAGS "-L/usr/local/lib") add_definitions(${GCC_COVERAGE_COMPILE_FLAGS}) \ No newline at end of file diff --git a/Sources/src/Visnode/compile.sh b/Sources/src/Visnode/_compile.sh similarity index 100% rename from Sources/src/Visnode/compile.sh rename to Sources/src/Visnode/_compile.sh diff --git a/Sources/src/Visnode/_postmake.sh b/Sources/src/Visnode/_postmake.sh new file mode 100644 index 0000000..f3d9b38 --- /dev/null +++ b/Sources/src/Visnode/_postmake.sh @@ -0,0 +1,2 @@ +#!/bin/bash +/usr/bin/c++ CMakeFiles/prog.dir/main.cpp.o -o /home/kanken/code/project-/Sources/src/bin/prog hw/libhw.a ui/libui.a psvr/libpsvr.a cameras/libcameras.a `pkg-config --cflags --libs opencv4` threadweaver/libthreadweaver.a /home/kanken/code/project-/Sources/src/Visnode/ihidapi/libihiadpi.a -L/home/kanken/code/project-/Sources/src/Visnode/ihidapi/ -ltbb -l:libhidapi-hidraw.so.0 -lopencv_core -lopencv_imgcodecs -lopencv_imgproc -lopencv_highgui -lopencv_videoio -std=c++17 \ No newline at end of file diff --git a/Sources/src/Visnode/cameras/CMakeLists.txt b/Sources/src/Visnode/cameras/CMakeLists.txt index 9ec4222..3dce9f6 100644 --- a/Sources/src/Visnode/cameras/CMakeLists.txt +++ b/Sources/src/Visnode/cameras/CMakeLists.txt @@ -6,12 +6,13 @@ set(cameras_source_files MESSAGE(STATUS "building cameras") add_library(cameras ${cameras_source_files}) +MESSAGE(STATUS "OpenCV_INCLUDE_DIRS : ${OpenCV_INCLUDE_DIRS}") +MESSAGE(STATUS "Opencv_LINK_DIRS : ${Opencv_LINK_DIRS}") + #SET("OpenCV_DIR" "/usr/local/lib/") find_package( OpenCV REQUIRED ) -MESSAGE(STATUS "Include dirs ${OpenCV_INCLUDE_DIRS}") -MESSAGE(STATUS "LINK LIBRARIES ${OpenCV_LIBS}") - target_link_libraries(cameras OpenCV) +target_link_libraries(cameras threadweaver) MESSAGE(STATUS "Done building cameras") \ No newline at end of file diff --git a/Sources/src/Visnode/prog b/Sources/src/Visnode/prog index 34f908c..9c379b4 100755 Binary files a/Sources/src/Visnode/prog and b/Sources/src/Visnode/prog differ diff --git a/Sources/src/Visnode/ui/CMakeLists.txt b/Sources/src/Visnode/ui/CMakeLists.txt index 7422420..669254f 100644 --- a/Sources/src/Visnode/ui/CMakeLists.txt +++ b/Sources/src/Visnode/ui/CMakeLists.txt @@ -12,8 +12,13 @@ SET("OpenCV_DIR" "/usr/local/lib/") find_package( OpenCV REQUIRED ) +MESSAGE(STATUS "OpenCV_INCLUDE_DIRS : ${OpenCV_INCLUDE_DIRS}") +MESSAGE(STATUS "Opencv_LINK_DIRS : ${Opencv_LINK_DIRS}") add_library(ui ${ui_source_files}) target_link_libraries(ui Opencv) +target_link_libraries(ui psvr) +target_link_libraries(ui cameras) + MESSAGE(STATUS "Done building ui") \ No newline at end of file diff --git a/Sources/src/Visnode/ui/uiDrawer.cpp b/Sources/src/Visnode/ui/uiDrawer.cpp index e5c9e62..9805927 100644 --- a/Sources/src/Visnode/ui/uiDrawer.cpp +++ b/Sources/src/Visnode/ui/uiDrawer.cpp @@ -49,7 +49,9 @@ namespace ui{ } void UiDrawer::drawStartupSequence(){ + cout << "opening external ressources" << endl; VideoCapture cap("./media/hud_startup.gif"); + cout << "opened video"<< endl; Mat overlay = imread("./media/hud_fixed.png",-1); cout << "read overlay" << endl; ui::UiDrawer::OverlayMat = overlay;