framebufferResized bug inherited from original tutorial

未关闭 适合新手
#555 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 10 天内回复

还没有人认领这个 Issue。

评估

难度
1/5
预计耗时
1 小时以内
新手友好度
84/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
cpp
领域
documentation

调研方向

打开 issue 中链接的交换链重建教程部分,检查 framebufferResized 条件以及 Vulkan 结果代码的处理方式。修改条件前,先确认 C++ 绑定的成功枚举;完成标准是调整大小处理不会掩盖其他错误结果,且教程示例使用正确的枚举。

由索引模型根据 Issue 内容生成。

描述

In this section:
https://docs.vulkan.org/tutorial/latest/03_Drawing_a_triangle/04_Swap_chain_recreation.html#_handling_resizes_explicitly

This code is incorrect:

if (result == vk::Result::eErrorOutOfDateKHR || result == vk::Result::eSuboptimalKHR || framebufferResized)

It should be:

if (result == vk::Result::eErrorOutOfDateKHR || result == vk::Result::eSuboptimalKHR || (result == vk::Result::Success && framebufferResized))

Otherwise, framebufferResized=true prevents the detection of all other VkResult error codes.

(I don't know if the enum is actually called vk::Result::Success, please verify before updating. I don't use the C++ bindings.)

主要语言
C++
星标
447
派生
149
平均合并
11 天 10 小时
30 天内合并 PR
11

环境准备

  • 没有 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 摘要。