mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-12 23:24:41 +00:00
* BugFix: Correct convexDecomp compilation by setting the LINUX flag when necessary.
* BugFix: Update OpenAL to correct a compilation error on Linux.
This commit is contained in:
parent
e071f1d901
commit
7380161054
234 changed files with 30864 additions and 7523 deletions
|
|
@ -4,7 +4,7 @@
|
|||
#include <algorithm>
|
||||
#include <cmath>
|
||||
|
||||
#include "math_defs.h"
|
||||
#include "alnumbers.h"
|
||||
#include "opthelpers.h"
|
||||
|
||||
|
||||
|
|
@ -21,9 +21,9 @@ using uint = unsigned int;
|
|||
*/
|
||||
double Sinc(const double x)
|
||||
{
|
||||
if UNLIKELY(std::abs(x) < Epsilon)
|
||||
if(unlikely(std::abs(x) < Epsilon))
|
||||
return 1.0;
|
||||
return std::sin(al::MathDefs<double>::Pi()*x) / (al::MathDefs<double>::Pi()*x);
|
||||
return std::sin(al::numbers::pi*x) / (al::numbers::pi*x);
|
||||
}
|
||||
|
||||
/* The zero-order modified Bessel function of the first kind, used for the
|
||||
|
|
@ -95,7 +95,7 @@ constexpr uint Gcd(uint x, uint y)
|
|||
*/
|
||||
constexpr uint CalcKaiserOrder(const double rejection, const double transition)
|
||||
{
|
||||
const double w_t{2.0 * al::MathDefs<double>::Pi() * transition};
|
||||
const double w_t{2.0 * al::numbers::pi * transition};
|
||||
if LIKELY(rejection > 21.0)
|
||||
return static_cast<uint>(std::ceil((rejection - 7.95) / (2.285 * w_t)));
|
||||
return static_cast<uint>(std::ceil(5.79 / w_t));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue