Search Issue Tracker
Won't Fix
Votes
0
Found in [Package]
5.11.1
Issue ID
1146516
Regression
No
[VFXExpression] VFXEXpressionCombine doesn't handle different number of components
TL;DR: VFXExpressionCombine(float2, float) does not combine to a float3.
An edge, but harder to track issue is that if the produced value is indirectly used, no error will appear with the expression, but there will be a compilation error:
incorrect number of arguments to numeric-type constructor at kernel CSMain
Repro steps:
1. Import the attached files into the VFX package
(The issue is with PositionDepthNode, it is dependent on the VFXExpressionLoadTexture2D expression and the VFXExpressionTransformVector4 expression within VFXExpressionTransform.cs) Note: VFXExpressionTransform.cs already exists, so it'll have to be replaced.
2. Attach the node to a VFX graph and compile it
3. Observe the incorrect number of arguments error in the console.
In this case this:
var uv = new VFXExpressionCombine(new VFXExpressionRandom(true), new VFXExpressionRandom(true));
var uvs = new VFXExpressionCombine(uv, VFXValue.Constant(0f));
Gets compiled to:
//uv
float tmp_z = RAND;
float tmp_ba = RAND;
float2 tmp_bb = float2(tmp_z, tmp_ba);
//uvs
float2 tmp_bj = float2(tmp_bb, (float)0);
float2 tmp_bj should be a float3.
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Articulation Body with 'Revolute' Joint Type has erratic behavior when Upper Limit is set to above 360
- WebGL Player fails to render Scene when Terrain with Detail Mesh is added and WebGPU Graphics API is used
- Inconsistent errors are logged when different types are passed into the Query "Q<>" method in UIToolkit and the ancestor VisualElement is null
- Crash on GetMaterialPropertyByIndex when opening a specific Scene
- Discrepancies in the styling are present when using a TSS file instead of a USS file in custom EditorWindow
Add comment