Tutorial text and code out of sync: missing queue.waitIdle() in drawFrame() leads to validation error VUID-vkQueueSubmit-pSignalSemaphores-00067

未關閉 適合新手
#525 0 則留言 0 個 reaction 已指派 1 人 在 GitHub 檢視

維護者通常 1 天內回覆

@SaschaWillems 已經在處理了。

開始於 2026年10月19日。

  • #532 來自 @SaschaWillems —— 未關閉

評估

難度
2/5
預估耗時
1-3 小時
新手友好度
76/100
Issue 類型
文件
描述清晰度
描述清楚
活躍度
活躍
技術堆疊
cpp
領域
documentation

研究方向

比較 en/03_Drawing_a_triangle/03_Drawing/02_Rendering_and_presentation.adoc 與 code/03_Drawing_a_triangle/02_Rendering_and_presentation/main.cpp,著重檢視對 drawFrame() 的描述和 queue.waitIdle() 呼叫。決定教學文件應如何記錄這個同步步驟,接著確認文字與程式碼相符,並清楚說明其行為。

由索引模型根據 Issue 內容生成。

描述

Problem

The tutorial text and the corresponding code in the repository are out of sync regarding synchronization in drawFrame().

Tutorial text:
en/03_Drawing_a_triangle/03_Drawing/02_Rendering_and_presentation.adoc

In this chapter, drawFrame() is described without any call to queue.waitIdle(). The text uses a single renderFinishedSemaphore that is signaled in vkQueueSubmit and waited on in vkQueuePresentKHR, and it is reused every frame.

Code:
code/03_Drawing_a_triangle/02_Rendering_and_presentation/main.cpp

The code contains an extra line that is not mentioned in the text:

queue.waitIdle(); // NOTE: for simplicity, wait for the queue to be idle before starting the frame
                  // In the next chapter you see how to use multiple frames in flight and fences to sync
主要語言
C++
星號
437
分支
139
平均合併
5 天 2 小時
30 天內合併 PR
3

環境準備

  • 沒有 Dockerfile 或 Docker Compose 檔案
  • 沒有 Pull Request 範本
  • 閱讀貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

KhronosGroup/Vulkan-Tutorial 的其他 Issue

查看 KhronosGroup/Vulkan-Tutorial 的全部 Issue

相似的 Issue

更多 C++ Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。