Questions tagged [vulkan]

Vulkan is a low-overhead, cross-platform graphics API from the Khronos Group.

Vulkan, once known as Next Generation OpenGL or just GLnext, is designed to be a low-overhead API that facilitates multithreaded 3D development, enabling different CPU threads to simultaneously prepare batches of commands to send to the GPU. It gives developers greater control of generating commands, putting tasks such as memory and thread management in their hands rather than relying on video drivers to handle these responsibilities. In so doing, it greatly reduces the amount of work and validation that the driver must perform, thus drastically reducing driver complexity. Conversely it increases the responsibilities of the application / developer to ensure that operations are valid and properly synchronized with each other.

Vulkan uses SPIR-V bytecode as its standard representation for graphics and compute shaders. The Khronos reference GLSL compiler compiles a form of GLSL (which implements a special extension to support Vulkan features) into SPIR-V, but users can use whatever compilers they wish which have a SPIR-V backend. The SPIR-V ecosystem also includes support for compiling from other languages such as HLSL, and for cross compiling SPIR-V bytecode back into various languages, including GLSL, HLSL and C++.

Vulkan enjoys wide native platform support on Windows, Linux, & Android. Additionally, a large subset of Vulkan is supported on the iOS and MacOS platforms through MoltenVk, part of the Vulkan Portability Initiative. Additional work is being done to develop a similar implementation of Vulkan over D3D12 to allow it to be used on UWP platforms that might not have native Vulkan drivers.

2248 questions
0
votes
0 answers

Fortran bindings to Vulkan API

Is there some place I could get Fortran bindings to Vulkan? Or do I have to manually write signatures of all C functions?
alagris
  • 1,838
  • 16
  • 31
0
votes
1 answer

Vulkan Image View Feature Flags

I get this validation message If a VkSampler created with magFilter or minFilter equal to VK_FILTER_LINEAR and compareEnable equal to VK_FALSE is used to sample a VkImageView as a result of this command, then the image view's format features must…
Sean Nolan
  • 43
  • 3
0
votes
2 answers

Is there a significant performance gap bewteen native VulkanSDK and its C++ binding?

Recently I'm trying to learn vulkan, and I found that although nearly every tutorial or book I found teaches vulkan with C++, the API style of it is more C than C++. Naturally, I looked for its official C++ API, and that raised my question: Is there…
0
votes
0 answers

Creating a MoltenVK Buffer Crashes iOS App Only When Downloaded Through App Store

I have been developing a game in c++ using vulkan and moltenVK for porting to iOS and Mac. The game works fine when I run it through XCode on my iPhone, but when I distribute the app through TestFlight, it crashes immediately. Here is some of the…
Ludius
  • 1
0
votes
1 answer

Optimizations causing errors

std::vector writeDescriptorSets; for (int index = 0; index < descriptorBindings.size(); index++) { VkWriteDescriptorSet writeDescriptorSet = {}; // Binding 0 : Uniform buffer …
Sean Nolan
  • 43
  • 3
0
votes
0 answers

I am trying to learn Vulkan but I keep getting errors that says things are undefined

The code I am trying to run is the same code that was in the tutorial on https://vulkan-tutorial.com/Drawing_a_triangle/Setup/Base_code yet every time I try to run it it does not seem to work. #include #include #include…
0
votes
0 answers

Is there any chance to push a constant of MVP on a device which only support 128 byte?

The MVP structure in my case takes 192 bytes as blow: struct MVP { model: Mat4, view: Mat4, proj: Mat4, } And according to enter link description here, nearly 78% of Android devices only support 128 bytes of push constants. Since…
psionic12
  • 185
  • 1
  • 11
0
votes
0 answers

Unity3d Ubuntu: Changing to Vulkan Graphics API for Linux Freezes

I am running Ubuntu 22.04.1 LTS. In order to solve the problem posed in my older question (Unity3d: "Platform StandaloneLinux64 with graphics API OpenGLCore is with HDRP"), I switched the Graphics API from OpenGLCore to Vulkan: When change the…
Steak
  • 514
  • 3
  • 15
0
votes
0 answers

Can HWUI's ShaderCache be shared across different processes?

I noticed that Vulkan generates ShaderModule from SPIRV bytecode is a very expensive operation, which will take up a lot of CPU cycles, but the overhead of this aspect in skia vulkan is extremely low, I guess this is mainly the role of ShaderCache,…
0
votes
1 answer

How to get cursor position in world space

I'm a Vulkan beginner and I've never worked with 3D graphics before. So, I want to move an object to a place where I click with the cursor. I found a few topics on stackoverflow and reddit. My implementation: int width,…
Wusiki Jeronii
  • 159
  • 1
  • 8
0
votes
2 answers

Is this a validation layer bug/oversight?

In my VkPipelineViewportStateCreateInfo I initialize viewportCount and scissorCount to 0 since I can use vkCmdSetViewport and vkCmdSetScissor during my render pass anyway. Is the validator bugged or is it trying to tell me something other than "0 is…
David Carpenter
  • 1,389
  • 2
  • 16
  • 29
0
votes
1 answer

Vulkan does not detect GPU when running Unity build in Docker container

Running Unity builds on my PC usually works fine. However when I am trying to run Unity builds within a Docker container I get a segmentation error Segmentation fault (core dumped). I am using Ubuntu 20.04 with an Nvidia GTX1080 and installed all…
GeorgUr
  • 61
  • 6
0
votes
0 answers

Validation Error: VkDeviceCreateInfo-queueFamilyIndex-02802

Problem: In certain graphics cards, the current queue selection process will pick the same queueFamilyIndex more than once if there are not enough individual queueFamilyIndex's for each (graphics, transfer and present) queue. This triggers a…
mango
  • 1
0
votes
0 answers

vkCreateDevice segmentation fault

Problem: My current computer only has 2 queue families available, and therefore, I'm trying to make it so that the vulkan program allows for shared queue families yet the program segfaults at the vkCreateDevice function call. I'm very new to Vulkan…
mango
  • 1
0
votes
1 answer

How to map SSBO buffer to CPU in Vulkan similar to glMapBuffer() in openGL

I am making a project in Vulkan, and I want to use an SSBO modified in the GPU on CPU; but Vulkan doesn't have a function to map the buffer, only have a memory function. I tried everything about MemoryMapping, but nothing worked.
XUFAN
  • 1