ShaderAst: Fix SwizzleOp::GetExpressionType

This commit is contained in:
Lynix
2020-05-23 22:05:37 +02:00
parent 93e76a17c7
commit fdeff2e9d0

View File

@@ -180,7 +180,7 @@ namespace Nz::ShaderAst
ExpressionType ShaderAst::SwizzleOp::GetExpressionType() const
{
return GetComponentType(expression->GetExpressionType());
return static_cast<ExpressionType>(UnderlyingCast(GetComponentType(expression->GetExpressionType())) + componentCount - 1);
}
void SwizzleOp::Register(ShaderWriter& visitor)