Search Issue Tracker
By Design
Votes
0
Found in
5.5.0f3
Issue ID
873181
Regression
No
Function Mathf.PerlinNoise returns the value which is less than 0
Reproduction steps:
1. Open the attached file "perlinNoise.zip";
2. Open the scene "test";
3. Enter the Play mode;
4. Observe the Console window;
Actual result: the function Mathf.PerlinNoise (89.5714f, 3234.57f) returns a value which is less than 0.
Expected result: the function Mathf.PerlinNoise should return a value between 0.0f and 1.0f (https://docs.unity3d.com/ScriptReference/Mathf.PerlinNoise.html)
Reproduced with: 5.4.3f1, 5.5.0f3, 5.6.0b5
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
- Editor crashes on StoredGraphicsBuffer::GetGfxBufferID when VFX Graph property is modified during Play Mode and Application.targetFrameRate is used to limit FPS
- Crash on NVAPI_Thunk when changing Player resolution while HDR display is used and Direct3D12 is set as the graphics API
- Only one out of multiple cameras is shown in the Play Mode while HDR display is used and Direct3D12 is set as the graphics API
- The "Paste Component as New" option is incorrectly displayed as active despite the action being prohibited
- "TLS Allocator ALLOC_TEMP_TLS" errors are thrown when unsuccessfully importing an FBX file
Resolution Note:
There are small rounding errors which can result in the final value being slightly above 0 or slightly above 1.
You may need to clamp the return value if the 0.0 to 1.0 range is important to you.