Fixes (hopefully) build on ARM machine (other then Pandora, so RPI and ODroid should be good now)

This commit is contained in:
ptitSeb 2017-12-22 13:59:22 +01:00
parent 360d19b01c
commit 668cc6dc56
2 changed files with 2 additions and 2 deletions

View File

@ -313,7 +313,7 @@ Rect ExtractPolygonsInBox(CTerrain *ptrTerrain, const FLOATaabbox3D &bboxExtract
#ifdef PANDORA
#define Isinf(a) (((*(unsigned int*)&a)&0x7fffffff)==0x7f800000)
#else
#define Isinf insif
#define Isinf isinf
#endif
rc.rc_iLeft = (Isinf(bbox.minvect(1)))?(INDEX)0:Clamp((INDEX)(bbox.minvect(1)-0),(INDEX)0,ptrTerrain->tr_pixHeightMapWidth);
rc.rc_iTop = (Isinf(bbox.minvect(3)))?(INDEX)0:Clamp((INDEX)(bbox.minvect(3)-0),(INDEX)0,ptrTerrain->tr_pixHeightMapHeight);

View File

@ -51,7 +51,7 @@ static inline void BoxToGrid(
#ifdef PANDORA
#define Isinf(a) (((*(unsigned int*)&a)&0x7fffffff)==0x7f800000)
#else
#define Isinf insif
#define Isinf isinf
#endif
iMinX = (Isinf(fMinX))?INDEX(GRID_MIN):Clamp(INDEX(floor(fMinX/GRID_CELLSIZE)), (INDEX)GRID_MIN, (INDEX)GRID_MAX);
iMinZ = (Isinf(fMinZ))?INDEX(GRID_MIN):Clamp(INDEX(floor(fMinZ/GRID_CELLSIZE)), (INDEX)GRID_MIN, (INDEX)GRID_MAX);