Merge pull request #92847 from aaronp64/varying_getter_port_type

Fix `VisualShaderNodeVaryingGetter` expanded ports adding ".x" to shader
This commit is contained in:
Rémi Verschelde 2024-06-11 16:59:25 +02:00
commit 0d1f2396d5
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -5166,11 +5166,11 @@ VisualShaderNodeVarying::PortType VisualShaderNodeVarying::get_port_type(VisualS
case VisualShader::VARYING_TYPE_UINT:
return PORT_TYPE_SCALAR_UINT;
case VisualShader::VARYING_TYPE_VECTOR_2D:
return PORT_TYPE_VECTOR_2D;
return p_port == 0 ? PORT_TYPE_VECTOR_2D : PORT_TYPE_SCALAR;
case VisualShader::VARYING_TYPE_VECTOR_3D:
return PORT_TYPE_VECTOR_3D;
return p_port == 0 ? PORT_TYPE_VECTOR_3D : PORT_TYPE_SCALAR;
case VisualShader::VARYING_TYPE_VECTOR_4D:
return PORT_TYPE_VECTOR_4D;
return p_port == 0 ? PORT_TYPE_VECTOR_4D : PORT_TYPE_SCALAR;
case VisualShader::VARYING_TYPE_BOOLEAN:
return PORT_TYPE_BOOLEAN;
case VisualShader::VARYING_TYPE_TRANSFORM: