Use 64bit integers in utility methods
This commit is contained in:
parent
92bcd3c01d
commit
52b20ce909
1 changed files with 6 additions and 6 deletions
|
@ -128,8 +128,8 @@ struct VariantUtilityFunctions {
|
|||
return Math::floor(x);
|
||||
}
|
||||
|
||||
static inline int floori(double x) {
|
||||
return int(Math::floor(x));
|
||||
static inline int64_t floori(double x) {
|
||||
return int64_t(Math::floor(x));
|
||||
}
|
||||
|
||||
static inline Variant ceil(Variant x, Callable::CallError &r_error) {
|
||||
|
@ -161,8 +161,8 @@ struct VariantUtilityFunctions {
|
|||
return Math::ceil(x);
|
||||
}
|
||||
|
||||
static inline int ceili(double x) {
|
||||
return int(Math::ceil(x));
|
||||
static inline int64_t ceili(double x) {
|
||||
return int64_t(Math::ceil(x));
|
||||
}
|
||||
|
||||
static inline Variant round(Variant x, Callable::CallError &r_error) {
|
||||
|
@ -194,8 +194,8 @@ struct VariantUtilityFunctions {
|
|||
return Math::round(x);
|
||||
}
|
||||
|
||||
static inline int roundi(double x) {
|
||||
return int(Math::round(x));
|
||||
static inline int64_t roundi(double x) {
|
||||
return int64_t(Math::round(x));
|
||||
}
|
||||
|
||||
static inline Variant abs(const Variant &x, Callable::CallError &r_error) {
|
||||
|
|
Loading…
Reference in a new issue