Somehow none of this MoltenVK stuff makes any comparison to Metal proper. I wonder if that’s intentional.
Choosing Vk in that scenario makes sense if you don’t /want/ to be locked into PC/Xbox without writing another backend, esp. given that DX12 and Vk are roughly the same complexity.
-
-
1/7 Vk supports any combination of https://www.khronos.org/registry/vulkan/specs/1.0/man/html/VkMemoryPropertyFlagBits.html …, while D3D just has https://msdn.microsoft.com/en-us/library/dn770374(v=vs.85).aspx …. Vk supports any combination of https://www.khronos.org/registry/vulkan/specs/1.0/man/html/VkQueueFlagBits.html …, while D3D has just https://msdn.microsoft.com/en-us/library/dn770348(v=vs.85).aspx … (no combinations)
-
2/7 Vk formats & image formats each individually need to be queried about what tiling they support https://www.khronos.org/registry/vulkan/specs/1.0/man/html/vkGetPhysicalDeviceFormatProperties.html …, while D3D has the same rules for every device https://msdn.microsoft.com/en-us/library/dn770442(v=vs.85).aspx …
-
3/7 Each Vk resource may only be able to be placed in certain heaps https://www.khronos.org/registry/vulkan/specs/1.0/man/html/vkGetBufferMemoryRequirements.html …, while D3D doesn't seem to have this requirement. Vk has semaphores, fences, events, pipeline barriers, while D3D just has fences and resource barriers.
-
4/7 Vk barriers have https://www.khronos.org/registry/vulkan/specs/1.0/man/html/vkCmdPipelineBarrier.html … and https://www.khronos.org/registry/vulkan/specs/1.0/man/html/VkBufferMemoryBarrier.html …, while D3D barriers have https://msdn.microsoft.com/en-us/library/dn986740(v=vs.85).aspx … and https://msdn.microsoft.com/en-us/library/dn986745(v=vs.85).aspx ….
-
5/7 Creating Vk pipeline state requires knowing each render subpass & its dependencies https://www.khronos.org/registry/vulkan/specs/1.0/man/html/VkRenderPassCreateInfo.html … but D3D lets you swap render targets at any point https://msdn.microsoft.com/en-us/library/dn986884(v=vs.85).aspx …
-
6/7 Vk's hello world has 3369 lines of code https://github.com/KhronosGroup/Vulkan-LoaderAndValidationLayers/blob/master/demos/cube.c … and D3D's hello world has 478 lines of code https://github.com/Microsoft/DirectX-Graphics-Samples/blob/22718ba0ea7be235fd00fd38b28b06cf30adf8e7/Samples/UWP/D3D12HelloWorld/src/HelloTexture/D3D12HelloTexture.cpp …
-
7/7 So, no, Vk is not write-once-run-anywhere. It’s more like write-three-times-run-some-places. And if you’re going to write three times, you might as well do it using good APIs that each target platform natively supports.
End of conversation
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.