diff options
author | Jcrespo <jcrespo@wikimedia.org> | 2023-06-18 14:47:01 +0200 |
---|---|---|
committer | Jaime Crespo <jcrespo@wikimedia.org> | 2023-09-01 01:27:56 +0200 |
commit | 528a76486c5475bdbb5cc9d1152d349205a366f6 (patch) | |
tree | 72977a33dd2770ab21c2da28c42e890100f42089 /modules/gdscript/gdscript_warning.cpp | |
parent | 549fcce5f8f7beace3e5c90e9bbe4335d4fd1476 (diff) | |
download | redot-engine-528a76486c5475bdbb5cc9d1152d349205a366f6.tar.gz |
Add inverse hyperbolic functions `asinh()`, `acosh()` & `atanh()`
GDScript has the following built-in trigonometry functions:
- `sin()`
- `cos()`
- `tan()`
- `asin()`
- `acos()`
- `atan()`
- `atan()`
- `sinh()`
- `cosh()`
- `tanh()`
However, it lacks the hyperbolic arc (also known as inverse
hyperbolic) functions:
- `asinh()`
- `acosh()`
- `atanh()`
Implement them by just exposing the C++ Math library, but clamping
its values to the closest real defined value.
For the cosine, clamp input values lower than 1 to 1.
In the case of the tangent, where the limit value is infinite,
clamp it to -inf or +inf.
References #78377
Fixes godotengine/godot-proposals#7110
Diffstat (limited to 'modules/gdscript/gdscript_warning.cpp')
0 files changed, 0 insertions, 0 deletions