summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlister Chowdhury <krax.powah@gmail.com>2022-12-06 07:25:43 +0000
committerAlister Chowdhury <krax.powah@gmail.com>2022-12-06 07:25:43 +0000
commit93902a7115949b0079f502cfb2db79c893876803 (patch)
tree1a69ba0b59b1638af9677b1bce06ad2fec8361e7
parent03b2a9d399ce2bdb6262313f9dcc453d7befd375 (diff)
downloadSPIRV-Reflect-93902a7115949b0079f502cfb2db79c893876803.tar.gz
Adding word offset to SpvReflectBlockVariable
-rw-r--r--spirv_reflect.c1
-rw-r--r--spirv_reflect.h5
2 files changed, 6 insertions, 0 deletions
diff --git a/spirv_reflect.c b/spirv_reflect.c
index 5fc190e..9e6976b 100644
--- a/spirv_reflect.c
+++ b/spirv_reflect.c
@@ -2272,6 +2272,7 @@ static SpvReflectResult ParseDescriptorBlockVariable(
ApplyArrayTraits(p_member_type, &p_member_var->array);
}
+ p_member_var->word_offset.offset = p_type_node->member_decorations[member_index].offset.word_offset;
p_member_var->type_description = p_member_type;
}
}
diff --git a/spirv_reflect.h b/spirv_reflect.h
index 690ae6c..674fcb0 100644
--- a/spirv_reflect.h
+++ b/spirv_reflect.h
@@ -379,6 +379,11 @@ typedef struct SpvReflectBlockVariable {
struct SpvReflectBlockVariable* members;
SpvReflectTypeDescription* type_description;
+
+ struct {
+ uint32_t offset;
+ } word_offset;
+
} SpvReflectBlockVariable;
/*! @struct SpvReflectDescriptorBinding