summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorGeorge Marques <george@gmarqu.es>2021-09-01 09:33:13 -0300
committerGitHub <noreply@github.com>2021-09-01 09:33:13 -0300
commit25ae27931758b5a74d30de52ea5601a91d2df7ae (patch)
tree673dbd00b79bf825f9f235ee17a4f8859d306039 /core
parentcf59028972e013128703033bc2ef1677098138bf (diff)
parent017c94222e3b88cb80da311e3e9c63eb3478463c (diff)
Merge pull request #52270 from KoBeWi/goodbye_polar
Remove cartesian2polar and polar2cartesian
Diffstat (limited to 'core')
-rw-r--r--core/variant/variant_utility.cpp11
1 files changed, 0 insertions, 11 deletions
diff --git a/core/variant/variant_utility.cpp b/core/variant/variant_utility.cpp
index f5cb2d40d6..232054d0ca 100644
--- a/core/variant/variant_utility.cpp
+++ b/core/variant/variant_utility.cpp
@@ -267,14 +267,6 @@ struct VariantUtilityFunctions {
return Math::db2linear(db);
}
- static inline Vector2 polar2cartesian(double r, double th) {
- return Vector2(r * Math::cos(th), r * Math::sin(th));
- }
-
- static inline Vector2 cartesian2polar(double x, double y) {
- return Vector2(Math::sqrt(x * x + y * y), Math::atan2(y, x));
- }
-
static inline int64_t wrapi(int64_t value, int64_t min, int64_t max) {
return Math::wrapi(value, min, max);
}
@@ -1214,9 +1206,6 @@ void Variant::_register_variant_utility_functions() {
FUNCBINDR(linear2db, sarray("lin"), Variant::UTILITY_FUNC_TYPE_MATH);
FUNCBINDR(db2linear, sarray("db"), Variant::UTILITY_FUNC_TYPE_MATH);
- FUNCBINDR(polar2cartesian, sarray("r", "th"), Variant::UTILITY_FUNC_TYPE_MATH);
- FUNCBINDR(cartesian2polar, sarray("x", "y"), Variant::UTILITY_FUNC_TYPE_MATH);
-
FUNCBINDR(wrapi, sarray("value", "min", "max"), Variant::UTILITY_FUNC_TYPE_MATH);
FUNCBINDR(wrapf, sarray("value", "min", "max"), Variant::UTILITY_FUNC_TYPE_MATH);