Files
autopilot/misc/rtsp_ai_player/rtsp_ai_player.pro
T
Tuomas Järvinen ba810592b5 Added new qmake config option which enables real gimbal camera
Gimbal camera can be enabled and used for example with command:
qmake6 CONFIG+=gimbal && make && ./rtsp_ai_player ~/azaion/models/onnx/yolov8m.onnx
2024-07-27 11:54:37 +03:00

55 lines
1.7 KiB
Prolog

QT += core network serialport
QT -= gui
CONFIG += c++11 concurrent console
MOC_DIR = moc
OBJECTS_DIR = obj
SOURCES = $$PWD/*.cpp
HEADERS = $$PWD/*.h
gimbal {
message("Using real gimbal camera.")
QMAKE_CXXFLAGS += -DGIMBAL
}
else {
message("Not using real gimbal camera.")
}
opi5 {
message("OPI5 build")
PKGCONFIG += opencv4 librga stb libturbojpeg
INCLUDEPATH += /usr/include/rga
QMAKE_CXXFLAGS += -DOPI5_BUILD
LIBS += /usr/local/lib/librknnrt.so
SOURCES += $$PWD/src-opi5/*.c $$PWD/src-opi5/*.cpp $$PWD/src-opi5/*.cc
HEADERS += $$PWD/src-opi5/*.h
} else:opencv {
message("OpenCV build")
message("You must use YOLOv8 ONNX files. Azaion model does not work!")
message("OpenCV must be version 4.10.0 installed to /usr/local/")
INCLUDEPATH += /opt/opencv-4.10.0/include/opencv4/
LIBS += /opt/opencv-4.10.0/lib/libopencv_world.so
QMAKE_LFLAGS += -Wl,-rpath,/opt/opencv-4.10.0/lib
QMAKE_CXXFLAGS += -DOPENCV_BUILD
SOURCES += $$PWD/src-opencv-onnx/*.cpp
HEADERS += $$PWD/src-opencv-onnx/*.h
}
else {
message("ONNX build")
message("You must use YOLOv8 ONNX files. Azaion ONNX model also works fine.")
QMAKE_CXXFLAGS += -DONNX_BUILD
# ONNX-runtime
INCLUDEPATH += /opt/onnxruntime-linux-x64-1.18.0/include
QMAKE_LFLAGS += -Wl,-rpath,/opt/onnxruntime-linux-x64-1.18.0/lib
LIBS += /opt/onnxruntime-linux-x64-1.18.0/lib/libonnxruntime.so.1.18.0
# OpenCV 4.10.0
INCLUDEPATH += /opt/opencv-4.10.0/include/opencv4/
QMAKE_LFLAGS += -Wl,-rpath,/opt/opencv-4.10.0/lib
LIBS += /opt/opencv-4.10.0/lib/libopencv_world.so
SOURCES += $$PWD/src-onnx-runtime/*.cpp
HEADERS += $$PWD/src-onnx-runtime/*.h
}