30#ifndef PXFOUNDATION_PXUNIXINTRINSICS_H
31#define PXFOUNDATION_PXUNIXINTRINSICS_H
33#include "foundation/Px.h"
34#include "foundation/PxSharedAssert.h"
36#if !(PX_LINUX || PX_ANDROID || PX_PS4 || PX_APPLE_FAMILY)
37#error "This file should only be included by Unix builds!!"
40#if (PX_LINUX || PX_ANDROID) && !defined(__CUDACC__) && !PX_EMSCRIPTEN
64 return (a >= 0.0f) ? b : c;
70 return (a >= 0.0f) ? 1.0f : -1.0f;
94 return 1.0f / ::sqrtf(a);
99 return 1.0f / ::sqrtf(a);
117 return a < b ? a : b;
123 return a > b ? a : b;
130 union localU { PxU32 i;
float f; } floatUnion;
132 return !((floatUnion.i & 0x7fffffff) >= 0x7f800000);
138 return !!isfinite(a);
146 return memset(dest, 0, count);
154 return memset(dest, c, count);
160PX_FORCE_INLINE void* memCopy(
void* dest,
const void* src, uint32_t count)
162 return memcpy(dest, src, count);
168PX_FORCE_INLINE void* memMove(
void* dest,
const void* src, uint32_t count)
170 return memmove(dest, src, count);
178 PX_SHARED_ASSERT(((
size_t(dest) + offset) & 0x7f) == 0);
179 memSet(
reinterpret_cast<char*
>(dest) + offset, 0, 128);
GLM_FUNC_QUALIFIER vec< L, T, Q > sqrt(vec< L, T, Q > const &x)
Definition func_exponential.inl:128
GLM_FUNC_QUALIFIER vec< L, T, Q > sin(vec< L, T, Q > const &v)
Definition func_trigonometric.inl:41
GLM_FUNC_QUALIFIER vec< L, T, Q > cos(vec< L, T, Q > const &v)
Definition func_trigonometric.inl:50
#define PX_FORCE_INLINE
Definition PxPreprocessor.h:335
Sorts an array of objects in ascending order, assuming that the predicate implements the < operator:
Definition PxBoxController.h:39