Skip to content

Conversation

@Karpov-Ruslan
Copy link

@Karpov-Ruslan Karpov-Ruslan commented Dec 14, 2025

This extension is written to support VK_KHR_relaxed_block_layout Vulkan extension. Currently there is only VK_EXT_scalar_block_layout support - GL_EXT_scalar_block_layout. To correct this historical injustice, I present this extension.

If GLSL Working Group approves this extension, then I will create a PR in glslang (link to fully working fork with the extension implementation).

The example of usage GL_EXT_relaxed_block_layout:

#version 460 core

#extension GL_EXT_relaxed_block_layout : require

struct S {
    int i;  // Struct member offset: 0
    vec3 j; // Struct member offset: 4
};

layout(binding = 0, std430, relaxed) buffer SSBO {
    int a; // Offset: 0
    S s;   // Offset: 16 (the base alignment of structure equals to 16)
    int b; // Offset: 32 (the size of structure equals to 16)
};

void main() {...}

@CLAassistant
Copy link

CLAassistant commented Dec 14, 2025

CLA assistant check
All committers have signed the CLA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants