diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index b2f29d6..e9eb2de 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -31,7 +31,8 @@ jobs: - name: Install Qt uses: jurplel/install-qt-action@v3.3.0 with: - version: '6.2.0' + version: '6.5.3' + aqtversion: ==3.1.7 - name: Setup OpenCV uses: Dovyski/setup-opencv-action@v1.1 diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index 7360d98..3e47c78 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -31,7 +31,8 @@ jobs: - name: Install Qt uses: jurplel/install-qt-action@v3.3.0 with: - version: '6.2.0' + version: '6.5.3' + aqtversion: ==3.1.7 - name: Install prerequisites shell: bash -l {0} @@ -52,7 +53,7 @@ jobs: run: | git fetch --tags --force sed -i'.original' -e 's/--long --dirty/--long/g' ./tools/generate_info.sh - sed -i'.original' -e 's/QT_DIR=\/opt\/Qt6.2.0\/6.2.0\/gcc_64/QT_DIR=$(cd "$(dirname "$0")";pwd)\/..\/Qt\/6.2.0\/macos/g' build_dmg.sh + sed -i'.original' -e 's/QT_DIR=\/opt\/Qt6.2.0\/6.2.0\/gcc_64/QT_DIR=$(cd "$(dirname "$0")";pwd)\/..\/Qt\/6.5.3\/macos/g' build_dmg.sh sed -i'.original' -e 's/\/home\/xiaoming\/Desktop\/opencv/\/usr\/local/g' build_dmg.sh sed -i'.original' -e 's/\/home\/xiaoming\/Desktop\/opencv/\/usr\/local/g' partform_unix.pri ./build_dmg.sh @@ -78,7 +79,8 @@ jobs: - name: Install Qt uses: jurplel/install-qt-action@v3.3.0 with: - version: '6.2.0' + version: '6.5.3' + aqtversion: ==3.1.7 - name: Install prerequisites shell: bash -l {0} @@ -99,7 +101,7 @@ jobs: run: | git fetch --tags --force sed -i'.original' -e 's/--long --dirty/--long/g' ./tools/generate_info.sh - sed -i'.original' -e 's/QT_DIR=\/opt\/Qt6.2.0\/6.2.0\/gcc_64/QT_DIR=$(cd "$(dirname "$0")";pwd)\/..\/Qt\/6.2.0\/macos/g' build_dmg.sh + sed -i'.original' -e 's/QT_DIR=\/opt\/Qt6.2.0\/6.2.0\/gcc_64/QT_DIR=$(cd "$(dirname "$0")";pwd)\/..\/Qt\/6.5.3\/macos/g' build_dmg.sh sed -i'.original' -e 's/\/home\/xiaoming\/Desktop\/opencv/\/usr\/local/g' build_dmg.sh sed -i'.original' -e 's/\/home\/xiaoming\/Desktop\/opencv/\/usr\/local/g' partform_unix.pri ./build_dmg.sh @@ -107,7 +109,7 @@ jobs: - name: Upload build asserts uses: actions/upload-artifact@v4.3.0 with: - name: YUVviewer_macos + name: YUVviewer_macos_arm64 path: | ./build_release/out/YUVviewer.dmg diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 705cc09..f3d620a 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -31,8 +31,9 @@ jobs: - name: Install Qt uses: jurplel/install-qt-action@v3.3.0 with: - arch: win64_mingw81 - version: '6.2.0' + arch: win64_mingw + version: '6.5.3' + aqtversion: ==3.1.7 - name: Cache opencv uses: actions/cache@v4 @@ -79,6 +80,7 @@ jobs: ./tools/sed/sed.exe -i "s/libopencv_imgcodecs420/libopencv_imgcodecs400/g" ./build_setup.bat ./tools/sed/sed.exe -i "s/libopencv_core420/libopencv_core400/g" ./build_setup.bat ./tools/sed/sed.exe -i "s/OPENCV_DIR=D:\\Qt\\opencv4.2.0/OPENCV_DIR=C:\\opencv4.0.0/g" ./partform_win32.pri + c:/Windows/system32/WindowsPowerShell/v1.0/powershell.exe -ExecutionPolicy Bypass -NoLogo -NoProfile -File "./tools/generate_info.ps1" > ./build_info.inc ./build_setup.bat - name: Upload build asserts diff --git a/README.md b/README.md index 187a24e..71c88b4 100644 --- a/README.md +++ b/README.md @@ -44,4 +44,4 @@ YV12、YU12/I420、NV21、NV12、YUY2/YUYV、YVYU、UYVY、YUV444、RGB565_L、R If you have suggestions or ideas for this project, please submit issues and pull requests on GitHub or Gitee. -At present, the project has been completely migrated to Qt6 development, it is recommended to use version Qt6.2.0 or higher. +At present, the project has been completely migrated to Qt6 development, it is recommended to use version Qt6.5.0 or higher. diff --git a/README_zh_CN.md b/README_zh_CN.md index 088f75e..3243680 100644 --- a/README_zh_CN.md +++ b/README_zh_CN.md @@ -44,4 +44,4 @@ YV12、YU12/I420、NV21、NV12、YUY2/YUYV、YVYU、UYVY、YUV444、RGB565_L、R 如果您对本项目有建议或想法,欢迎在GitHub或Gitee上提交issue和pull requests。 -目前项目已完全迁移至Qt6开发,建议使用版本Qt6.2.0或更高版本。 +目前项目已完全迁移至Qt6开发,建议使用版本Qt6.5.0或更高版本。 diff --git a/YUVviewer.pro b/YUVviewer.pro index a6b16ac..d9552c1 100644 --- a/YUVviewer.pro +++ b/YUVviewer.pro @@ -15,6 +15,12 @@ unix:{ YUVVIEWER_VERSION="$$cat(./version.txt)" ############################################################################### + +!versionAtLeast(QT_VERSION, 6.5.0) { + message("Cannot use Qt $$QT_VERSION") + error("Use Qt 6.5.0 or newer") +} + # 定义需要的Qt组件 QT += core gui QT += xml svg @@ -28,6 +34,10 @@ DEFINES += APP_VERSION="\\\"V$${YUVVIEWER_VERSION}\\\"" CONFIG += c++11 # 源文件配置 +INCLUDEPATH += \ + $$PWD \ + $$PWD/src + SOURCES += \ src/YUVviewer.cpp \ src/ImgViewer.cpp \