|
If I’m planning to do cross-platform 3d graphics, is there any reason not to do it in Vulkan? I.e., is there any advantage to the alternative of manually doing a dx12 backend and a metal backend? (Talking mostly theoretically here just to better understand. I’m probably gonna just stick with OpenGL for my actual work for the foreseeable future)
|
# ¿ Aug 31, 2022 17:05 |
|
|
# ¿ Apr 29, 2024 15:24 |
|
I'm following vulkan-tutorial.com on an old mac with integrated graphics. I ran into a weird issue, and I wonder if any of y'all have a clue about what could be going on. The first part of the tutorial involves drawing a single triangle to the screen without using a vertex buffer at all, so the vertex shader just hardcodes the vertex positions and colors into the shader, using gl_VertexIndex to select the appropriate position/color. I'm following the code exactly to the tutorial, but my triangle's colors are wrong: only one corner is red, and the other two corners are black. code:
code:
code:
e: I realize that this specific shader is totally unrealistic, but I'm stuck on this because in the future if I want to use hardcoded constant arrays for some reason, I'm not gonna trust 'em if they can exhibit weird behavior I don't understand!!! giogadi fucked around with this message at 22:09 on Nov 20, 2022 |
# ¿ Nov 20, 2022 22:04 |
|
VostokProgram posted:This could very well be a compiler bug. Can you post the SPIR-V? The Vulkan sdk has a program called spirv-dis you can use to get a text listing of a SPIR-V binary. I'm not familiar with Mac development but I assume you're using glslang to convert from GLSL to SPIR-V right? A little while back I actually found a github issue on MoltenVK with my exact problem: https://github.com/KhronosGroup/MoltenVK/issues/1499 It looks like it's a bug in Intel's Metal drivers. I've been meaning to put together a super minimal example in pure Metal that reproduces the issue that I can send over to Apple. It really sucks that bugs like this exist - it makes me afraid to use any graphics API built on top of Metal because it could potentially have weird bugs like the above. It's shameful that support for intel-based macs is so bad - there are still soooo many of these macbooks out there that otherwise work really great!
|
# ¿ May 5, 2023 16:28 |