Conversation
|
NOTE: this is an in-progress work to test the site and to gradually migrate all code blocks to handle both C-API and current C++. Don't merge until all relevant code blocks have been addressed and the test site validates that this works as intended. |
|
For organizational purposes, I will keep track of chapters I am adjusting and their linked pull requests in this comment. All request changes are provided in this PR.
|
| // END c++ | ||
|
|
||
| // START c | ||
| VkBufferCreateInfo bufferInfo{}; |
There was a problem hiding this comment.
This should use designated initializers, just like the code a few lines below.
| void createVertexBuffer() { | ||
| VkBufferCreateInfo bufferInfo = { | ||
| .sType = VK_STRUCTURE_TYPE_BUFFER_CREATE_INFO, | ||
| .pNext = NULL, |
There was a problem hiding this comment.
More of a general question: Do we want to always set all fields, or should we omit those that are not set/required? In this case pNext and flags is not used and zeroed out when using designated initializers.
|
Is this still active? In case it is, I can complete adding equivalent C snippets for the remaining chapters (and updating already finished ones to current HEAD). (Note: I do understand that reviewing this is probably a major task) |
|
Yep still very much active. No worries about length of pr, we can deal
with it.
…On Mon, Jan 19, 2026, 9:50 PM Walid Chtioui ***@***.***> wrote:
*walcht* left a comment (KhronosGroup/Vulkan-Tutorial#202)
<#202 (comment)>
Is this still active? In case it is, I can complete adding equivalent C
snippets for the remaining chapters.
(Note: I do understand that reviewing this is probably a major task)
—
Reply to this email directly, view it on GitHub
<#202 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AA5IAY7NQE2WA3HCETS4IA34HW627AVCNFSM6AAAAACJQQH37GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZTONZRGE2TEOBQHE>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
|
We might want to agree on best practices and guidelines before too much work is done. Like if we add C, will this be pure C or "C in C++"? If it's the latter, will we use designated initializers? etc. |
d990430 to
fca909b
Compare
d5c6088 to
1b8530a
Compare
|
How can I actually test this locally? I do have my own Vulkan docs site testbed, as building the whole site requires a spec build, which is nigh impossible to get up and running. When building the site there, code blocks don't have toggles:
I guess I need an updated UI bundle, but I'm not seeing anything related to this inside https://github.com/KhronosGroup/antora-ui-khronos Any guidance? |
|
https://github.com/KhronosGroup/Vulkan-Site/actions/workflows/ci.yml <-- use the runworkflow button, You should be able to give the branch name here in the tutorial field that pops up in that form. You can even click the checkboxes for what you don't want to have it build. |

[source,multilang,c++,c]).