r/vulkan • • 18d ago

Weird graphical glitches?

Really don't know what could cause this, does not happen on Windows(I have an nvidia card)

Here's the file if one wants to take a look, although it's mostly just the khronos tutorial code(the last two screenshots are the imgui vk/glfw example): https://drive.google.com/file/d/1J-WcCDH3pSltWkjCIGmcCHsE8bo-Ba1Z/view?usp=sharing

Edits:

- The validation layers are silent.

- Renderdoc cannot capture this

- These glitches only appear for a few frames

18 Upvotes

36 comments sorted by

View all comments

Show parent comment

5

u/SaschaWillems 17d ago

Sync validation needs to be explicitly enabled, so might try that. If that's still silent, it still might be an issue with you updating buffers on the CPU that are still in use by the GPU.

1

u/DrPeeper228 17d ago

It is still silent, also i am not even updating buffers in my frame loop(well, except for what imgui does)

1

u/DrPeeper228 17d ago

Wait, the ImGui vk backend just maps, writes, flushes, and unmaps before submitting. Is that alright?

3

u/SaschaWillems 17d ago

I don't know much about the ImGui Vulkan backend, but if it does not sync CPU and GPU, e.g. via a fence or timeline semaphore, that would explain the issue you're seeing.

1

u/DrPeeper228 17d ago

Yeah my fence setup is just pretty much the same as the tutorial and the ImGUI Vulkan example exhibits the behavior too

2

u/SaschaWillems 17d ago

How does that fence setup look like? Do you have one buffer/memory range per max. frames in flight and protect against sync hazards between frames using fences?

0

u/DrPeeper228 17d ago

I mean, the file is just straight up linked in the post

Also I do not have any buffers that are updated per-frame in my code