Search Issue Tracker
Won't Fix
Votes
0
Found in
2018.4
2019.4
2019.4.11f1
2020.1
2020.2
Issue ID
1280036
Regression
No
The return fixed4 statement causes an internal compiler error when one of the fixed4 parameters is a previously defined variable
How to reproduce:
1. Create a new 3D Template project
2. Import the attached shader named "TestShader"
3. Select the shader and observe the Inspector window
Expected result: Shader is compiled
Actual result: Shader compilation error is thrown
Reproducible with: 2018.4.27f1, 2019.4.12f1, 2020.1.8f1, 2020.2.0b5
Notes:
1. The predefined variable changes its value in a for loop before being returned. If this loop is removed, the issue does not occur
2. Graphics APIs tested - D3D11, D3D12, Vulkan, OpenGLCore
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Mono Windows Builds don't produce full log callstacks when generating logs
- AssetBundles fail to load when running in Built Players for Mobile Devices
- UI elements with text gets bigger and grey when Player window is moved to another screen with different resolution
- System name accepts multiline text but crops it on confirmation, duplicates input, and shrinks the field when empty
- UI element scale and position are wrong in project build when DRS is changed with HDR and Software Dynamic Resolution enabled
Resolution Note (2021.1.X):
Unfortunately, we cannot fix this crash.
Equivalent code of the first loop that makes the crash go away:
for (int i = 0; i < 2; ++i)
{
float xAlpha = xAlphas[ix];
if (xAlpha <= 1)
++ix;
alphas[nRegions - 1] = 1;
++nRegions;
}