Search Issue Tracker
Fixed in 5.5.0
Votes
0
Found in
5.5.0a5
Issue ID
821711
Regression
Yes
[Shaders] Compilation fails on 5.5 if the entire CGPROGRAM is written in the same line
Steps to reproduce:
1. Open attached project
2. Select 'Occlusion' shader (Assets/AmplifyOcclusion/Resources)
3. Notice there is a bunch of "invalid preprocessor command 'LINE'" errors thrown (if not, click 'Compile and Show Code', the errors will appear).
If you change all the lines starting at line 283 in the 'Occlusion.shader' from
Pass { CGPROGRAM float4 frag( v2f_img IN ) : SV_TARGET { return FullDepth( IN ); } ENDCG }
to
Pass { CGPROGRAM
float4 frag( v2f_img IN ) : SV_TARGET { return FullDepth( IN ); } ENDCG }
(same code, just written in separate lines) the errors disappear and shader compiles successfully.
Does not reproduce with: 5.4.0f3
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Crash when trying to force Shader to interpret 1/30 as a floating point operation
- Terrain is flickering when adjusting "Compatibility Mode" and "Use Rendering Layers" Settings
- Isometric tiles are flickering and overlapping each other when entering Play Mode with Tilemap Renderer mode set to "Chunk"
- Crash on ParticleSystemParticles::array_reserve when particle system starts
- Docking Text Property Preview Window next to UI Builder breaks the window and causes NullReferenceException
Add comment