nir: add glsl_get_ifc_packing() helper

This will be used in the following patch.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4797>
This commit is contained in:
Timothy Arceri
2020-04-30 13:36:02 +10:00
committed by Marge Bot
parent 7ac617c117
commit bc79442f3f
2 changed files with 8 additions and 0 deletions

View File

@@ -803,6 +803,12 @@ glsl_get_internal_ifc_packing(const struct glsl_type *type,
return type->get_internal_ifc_packing(std430_supported);
}
enum glsl_interface_packing
glsl_get_ifc_packing(const struct glsl_type *type)
{
return type->get_interface_packing();
}
unsigned
glsl_get_std140_base_alignment(const struct glsl_type *type, bool row_major)
{

View File

@@ -55,6 +55,8 @@ glsl_get_struct_field_data(const struct glsl_type *type, unsigned index);
enum glsl_interface_packing
glsl_get_internal_ifc_packing(const struct glsl_type *type,
bool std430_supported);
enum glsl_interface_packing
glsl_get_ifc_packing(const struct glsl_type *type);
unsigned glsl_get_std140_base_alignment(const struct glsl_type *type,
bool row_major);