mirror of
https://github.com/godotengine/godot.git
synced 2025-10-27 11:44:21 +00:00
Prevent ternary expression with a sampler types in shaders
This commit is contained in:
parent
5abed52fd9
commit
d3792efa89
1 changed files with 1 additions and 1 deletions
|
|
@ -2003,7 +2003,7 @@ bool ShaderLanguage::_validate_operator(const BlockNode *p_block, const Function
|
|||
DataType nb = p_op->arguments[1]->get_datatype();
|
||||
DataType nc = p_op->arguments[2]->get_datatype();
|
||||
|
||||
valid = na == TYPE_BOOL && (nb == nc);
|
||||
valid = na == TYPE_BOOL && (nb == nc) && !is_sampler_type(nb);
|
||||
ret_type = nb;
|
||||
ret_size = sa;
|
||||
} break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue