Mesa (master): glsl: make use of glsl_type::is_interface()
Samuel Pitoiset
hakzsam at kemper.freedesktop.org
Fri Apr 21 17:37:06 UTC 2017
Module: Mesa
Branch: master
Commit: cd78ab55d0afefa501929366205443e15ed85495
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=cd78ab55d0afefa501929366205443e15ed85495
Author: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Date: Fri Apr 21 10:28:58 2017 +0200
glsl: make use of glsl_type::is_interface()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Reviewed-by: Samuel Iglesias Gonsálvez <siglesias at igalia.com>
Reviewed-by: Edward O'Callaghan <funfunctor at folklore1984.net>
---
src/compiler/glsl/hir_field_selection.cpp | 2 +-
src/compiler/glsl/shader_cache.cpp | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/compiler/glsl/hir_field_selection.cpp b/src/compiler/glsl/hir_field_selection.cpp
index eab08ad823..aa1808afa1 100644
--- a/src/compiler/glsl/hir_field_selection.cpp
+++ b/src/compiler/glsl/hir_field_selection.cpp
@@ -47,7 +47,7 @@ _mesa_ast_field_selection_to_hir(const ast_expression *expr,
if (op->type->is_error()) {
/* silently propagate the error */
} else if (op->type->base_type == GLSL_TYPE_STRUCT
- || op->type->base_type == GLSL_TYPE_INTERFACE) {
+ || op->type->is_interface()) {
result = new(ctx) ir_dereference_record(op,
expr->primary_expression.identifier);
diff --git a/src/compiler/glsl/shader_cache.cpp b/src/compiler/glsl/shader_cache.cpp
index 19d69c36fc..800d3a2913 100644
--- a/src/compiler/glsl/shader_cache.cpp
+++ b/src/compiler/glsl/shader_cache.cpp
@@ -129,7 +129,7 @@ encode_type_to_blob(struct blob *blob, const glsl_type *type)
blob_write_string(blob, type->fields.structure[i].name);
}
- if (type->base_type == GLSL_TYPE_INTERFACE) {
+ if (type->is_interface()) {
blob_write_uint32(blob, type->interface_packing);
blob_write_uint32(blob, type->interface_row_major);
}
More information about the mesa-commit
mailing list