【qt】sdk写pro写法,cv,onnx,cudnn

我的sdk在OpenCV003项目里:

pro中添加

cpp 复制代码
CONFIG(release, debug|release) {
    LIBS += -L$$PWD/sdk/onnxruntime-x64-gpu/lib/ -lonnxruntime
    LIBS += -L$$PWD/sdk/onnxruntime-x64-gpu/lib/ -lonnxruntime_providers_cuda
    LIBS += -L$$PWD/sdk/onnxruntime-x64-gpu/lib/ -lonnxruntime_providers_shared
    LIBS += -L$$PWD/sdk/onnxruntime-x64-gpu/lib/ -lonnxruntime_providers_tensorrt
    LIBS += -L$$PWD/sdk/opencv/lib/ -lopencv_world470
}
else {
    LIBS += -L$$PWD/sdk/onnxruntime-x64-gpu/lib/ -lonnxruntime
    LIBS += -L$$PWD/sdk/onnxruntime-x64-gpu/lib/ -lonnxruntime_providers_cuda
    LIBS += -L$$PWD/sdk/onnxruntime-x64-gpu/lib/ -lonnxruntime_providers_shared
    LIBS += -L$$PWD/sdk/onnxruntime-x64-gpu/lib/ -lonnxruntime_providers_tensorrt
    LIBS += -L$$PWD/sdk/opencv/lib/ -lopencv_world470d
}

INCLUDEPATH += $$PWD/sdk/onnxruntime-x64-gpu/include
INCLUDEPATH += $$PWD/sdk/opencv/include

CONFIG(release, debug|release) {
    onnxruntime.files += $$PWD/sdk/onnxruntime-x64-gpu/bin/onnxruntime.dll
    onnxruntime.files += $$PWD/sdk/onnxruntime-x64-gpu/bin/onnxruntime_providers_cuda.dll
    onnxruntime.files += $$PWD/sdk/onnxruntime-x64-gpu/bin/onnxruntime_providers_shared.dll
    onnxruntime.files += $$PWD/sdk/onnxruntime-x64-gpu/bin/onnxruntime_providers_tensorrt.dll
    opencv.files += $$PWD/sdk/opencv/bin/opencv_world470.dll
}
else {
    onnxruntime.files += $$PWD/sdk/onnxruntime-x64-gpu/bin/onnxruntime.dll
    onnxruntime.files += $$PWD/sdk/onnxruntime-x64-gpu/bin/onnxruntime_providers_cuda.dll
    onnxruntime.files += $$PWD/sdk/onnxruntime-x64-gpu/bin/onnxruntime_providers_shared.dll
    onnxruntime.files += $$PWD/sdk/onnxruntime-x64-gpu/bin/onnxruntime_providers_tensorrt.dll
    opencv.files += $$PWD/sdk/opencv/bin/opencv_world470d.dll
}


CONFIG(release, debug|release) {
    onnxruntime.path += $$OUT_PWD/Release
    opencv.path += $$OUT_PWD/Release
}
else {
    onnxruntime.path += $$OUT_PWD/Debug
    opencv.path += $$OUT_PWD/Debug
}

COPIES += onnxruntime
COPIES += opencv
相关推荐
fzb5QsS1p20 小时前
告别重复造轮子,Qt 快速开发脚手架
开发语言·qt·php
森G20 小时前
58、最佳实践与注意事项---------多线程、竟态条件和同步
c++·qt
小樱花的樱花21 小时前
1 项目概述
开发语言·c++·qt·ui
MinterFusion1 天前
如何在openKylin 2.0 SP2中安装Qt(v0.2.2)(上)
开发语言·qt·软件开发·系统维护·明德融创·openkylin
特立独行的猫a1 天前
HarmonyOS鸿蒙PC的QT应用开发:(一、开发环境搭建及第一个HelloWorld)
qt·华为·harmonyos·鸿蒙pc
青花瓷1 天前
采用QT下MingW编译opencv4.8.1
开发语言·qt
cpp_learners1 天前
Linux ARM架构 使用 linuxdeployqt 打包QT程序
linux·arm开发·qt
森G1 天前
3.1、移植Qt程序到ARM平台----移植Qt程序到ARM平台(扩展)
arm开发·c++·qt
白杆杆红伞伞1 天前
Qt Event
开发语言·qt
Magic--1 天前
Qt 桌面计算器项目
开发语言·qt