Instancing Rate in Vulkan

I have a question about DX11 and OpenGL feature which is InstanceDataStepRate
InstanceDataStepRate can be found in D3D11_INPUT_ELEMENT_DESC and means “The number of instances to draw using the same per-instance data before advancing in the buffer by one element. This value must be 0 for an element that contains per-vertex data (the slot class is set to D3D11_INPUT_PER_VERTEX_DATA).”.
This same feature can be found in OpenGL in function void glVertexAttribDivisor( GLuint index, GLuint divisor). Argument divisor means “Specify the number of instances that will pass between updates of the generic attribute at slot index.”.
The same feature can be found in PS4 API.
How the same functionality can be done in Vulkan ?
Best regards

You don’t. Well, not directly. You can always take the InstanceIndex, divided it by the divisor, and use that to fetch data from an SSBO or whatever. But you can’t use vertex attributes to do the division directly.

Note that D3D12 also doesn’t have this feature: attributes are either per-vertex or per-instance.

So there is some kind of hardware have some problem with support InstanceDataStepRate? And drivers of DX11 or OpenGL have to do some kind of fetch stage “patch” to support this feature?.
Or just Khronos just forgot about this feature in Vulkan API?
It is harder to port from DX11 or OpenGL to Vulkan if some one ( like me ) is using this :slight_smile:

If by “Khronos”, you mean “Khronos and Microsoft”. Again: D3D12 doesn’t let you do it either.

What were you using it for? I’ve always had a difficult time imagining the circumstance where I’d need this particular tool.

D3D12 is not in my area of interest. And if it “do something wrong” Vulkan IMHO should not imitate it.

I am well aware that this is a niche feature. I’m used it only in a very specific case ( special particle system effect ).
But if it not hardware limitation maybe someone much smarter then me will develop some kind of new fantastic use case ( Some fantastic techniques like SSAO, or Deferred Shading =] ).
I’m just try to say even if it is rarely used it is a pity to limit human inventiveness and needs.