Skip to content

Instantly share code, notes, and snippets.

@yorung
Last active August 29, 2015 14:18
Show Gist options
  • Save yorung/a632d62e19074ad73e1f to your computer and use it in GitHub Desktop.
Save yorung/a632d62e19074ad73e1f to your computer and use it in GitHub Desktop.
[GLSL and HLSL] Uniform Buffer and Constant Buffer
// HLSL (DirectX11)
cbuffer MyContantBuffer : register(b2)
{
float4x4 matW;
}
// GLSL
layout (std140, binding = 2) uniform MyUBO {
mat4 matW;
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment