ClampedPow seems to have been added as a way to tackle common compile warnings and edge cases (particularly NaNs), but the code shouldn't be calling both an abs() then a max(). This causes negative inputs to give incorrect outputs, something that's very difficult to track down as it's unexpected behavior.
Ideally this code should be replaced by something more inline with actual pow() behavior.
Create a material using the Power node.
Examine the HLSL output and see the code has inserted an abs() and max() in unexpectedly.
Hooking a negative value to the Power node gives an incorrect result (should be NaN or 0).
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-42989 in the post.
0 |
Component | UE - Graphics Features |
---|---|
Affects Versions | 4.15, 4.16 |
Target Fix | 4.16 |
Created | Mar 16, 2017 |
---|---|
Resolved | Mar 28, 2017 |
Updated | Mar 21, 2019 |