diff --git a/.github/actions/install-dependencies/action.yml b/.github/actions/install-dependencies/action.yml index a5eea33..b574b18 100644 --- a/.github/actions/install-dependencies/action.yml +++ b/.github/actions/install-dependencies/action.yml @@ -14,7 +14,7 @@ inputs: qt_ver: description: 'qt version' required: false - default: '6.9.0' + default: '6.9.2' type: string runs: diff --git a/.github/workflows/clean_cache.yml b/.github/workflows/clean_cache.yml index 2db7538..9d9b9e5 100644 --- a/.github/workflows/clean_cache.yml +++ b/.github/workflows/clean_cache.yml @@ -15,7 +15,7 @@ jobs: contents: read steps: - name: Check out code - uses: actions/checkout@v4 + uses: actions/checkout@v5 - name: Cleanup run: | diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index 1ab9135..6b0c7d6 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -36,7 +36,7 @@ jobs: - "Ninja" steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 with: fetch-depth: 1 diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index 6f7ef91..c6b48c4 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -8,6 +8,8 @@ on: - '.gitignore' - 'LICENSE' - 'README*' + branches-ignore: + - 'dependabot/**' pull_request: paths-ignore: - 'docs/**' @@ -15,6 +17,8 @@ on: - '.gitignore' - 'LICENSE' - 'README*' + branches-ignore: + - 'dependabot/**' schedule: - cron: '0 0 1 * *' @@ -28,7 +32,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 with: fetch-depth: 1 diff --git a/.github/workflows/qmake.yml b/.github/workflows/qmake.yml index d9adc8b..4c2c0a6 100644 --- a/.github/workflows/qmake.yml +++ b/.github/workflows/qmake.yml @@ -32,7 +32,7 @@ jobs: - ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 with: fetch-depth: 1 diff --git a/.github/workflows/readme.yml b/.github/workflows/readme.yml index ebe25e0..23e39e9 100644 --- a/.github/workflows/readme.yml +++ b/.github/workflows/readme.yml @@ -12,9 +12,9 @@ jobs: build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Setup Node.js - uses: actions/setup-node@v4 + uses: actions/setup-node@v5 # ISO Langusge Codes: https://cloud.google.com/translate/docs/languages - name: Adding README - English uses: dephraiim/translate-readme@main diff --git a/.github/workflows/toolchain.yml b/.github/workflows/toolchain.yml index b872572..5dbd873 100644 --- a/.github/workflows/toolchain.yml +++ b/.github/workflows/toolchain.yml @@ -24,7 +24,7 @@ jobs: - ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 with: fetch-depth: 1 diff --git a/cmake/qt.cmake b/cmake/qt.cmake index 15d3210..6762fc7 100644 --- a/cmake/qt.cmake +++ b/cmake/qt.cmake @@ -1,9 +1,9 @@ if(CMAKE_HOST_WIN32) - list(APPEND CMAKE_PREFIX_PATH "C:\\Qt\\6.9.0\\msvc2022_64") + list(APPEND CMAKE_PREFIX_PATH "C:\\Qt\\6.9.2\\msvc2022_64") elseif(CMAKE_HOST_APPLE) elseif(CMAKE_HOST_LINUX) - list(APPEND CMAKE_PREFIX_PATH "/opt/Qt/6.9.0/gcc_64") + list(APPEND CMAKE_PREFIX_PATH "/opt/Qt/6.9.2/gcc_64") endif() add_definitions(-DQT_DEPRECATED_WARNINGS diff --git a/src/gpugraphics/openglview.cc b/src/gpugraphics/openglview.cc index 9212663..51a4eba 100644 --- a/src/gpugraphics/openglview.cc +++ b/src/gpugraphics/openglview.cc @@ -30,6 +30,7 @@ class OpenglView::OpenglViewPrivate q_ptr->glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR); q_ptr->glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); q_ptr->glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); + q_ptr->glBindTexture(GL_TEXTURE_2D, 0); } void uploadTexture() @@ -47,6 +48,7 @@ class OpenglView::OpenglViewPrivate GL_UNSIGNED_BYTE, image.bits()); q_ptr->glGenerateMipmap(GL_TEXTURE_2D); + q_ptr->glBindTexture(GL_TEXTURE_2D, 0); programPtr->release(); q_ptr->doneCurrent(); } @@ -265,6 +267,8 @@ void OpenglView::paintGL() glDrawElements(GL_TRIANGLES, 6, GL_UNSIGNED_INT, 0); + glBindTexture(GL_TEXTURE_2D, 0); + d_ptr->programPtr->release(); } diff --git a/src/gpugraphics/shader/complie_qsb.ps1 b/src/gpugraphics/shader/complie_qsb.ps1 index 0cdcf19..abe12e5 100644 --- a/src/gpugraphics/shader/complie_qsb.ps1 +++ b/src/gpugraphics/shader/complie_qsb.ps1 @@ -1,6 +1,6 @@ Set-Location $PSScriptRoot -$qsb = "C:\Qt\6.9.0\msvc2022_64\bin\qsb.exe" +$qsb = "C:\Qt\6.9.2\msvc2022_64\bin\qsb.exe" & $qsb --glsl "150,120,100 es" --hlsl 50 --msl 12 -o vulkan.vert.qsb vulkan.vert & $qsb --glsl "150,120,100 es" --hlsl 50 --msl 12 -o vulkan.frag.qsb vulkan.frag diff --git a/src/utils/utils.h b/src/utils/utils.h index b8ce20a..6e27833 100644 --- a/src/utils/utils.h +++ b/src/utils/utils.h @@ -13,10 +13,10 @@ class QMenu; namespace Utils { template -auto asynchronous(std::function &&func) -> T +auto asynchronous(std::function &&func) { - if (!func) { - return T(); + if (nullptr == func) { + return T{}; } QEventLoop loop; QFutureWatcher watcher; diff --git a/vcpkg.json b/vcpkg.json index f2d73f0..afd3af6 100644 --- a/vcpkg.json +++ b/vcpkg.json @@ -23,5 +23,5 @@ ] } ], - "builtin-baseline": "a9eee3b18df395dbb8be71a31bd78ea441056e42" + "builtin-baseline": "897ba2ab4c4c776b985ab1f599548fcf3ae598ba" }