Skip to content

Commit 839b99f

Browse files
committed
Fix compilation error (float)
1 parent 3fc1371 commit 839b99f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/hsp3dish/essprite.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#include <stdio.h>
1313
#include <stdlib.h>
1414
#include <math.h>
15+
#include <float.h>
1516
#include <algorithm>
1617

1718
#include "essprite.h"
@@ -116,8 +117,8 @@ ESVec2 ESRectAxis::getAxis(int index)
116117

117118
// Checks if projections of two rectangles onto an axis overlap
118119
bool ESRectAxis::checkAxisOverlap( ESRectAxis *rect1, ESRectAxis *rect2, ESVec2 *axis) {
119-
double min1 = FLT_MAX, max1 = -FLT_MAX;
120-
double min2 = FLT_MAX, max2 = -FLT_MAX;
120+
double min1 = DBL_MAX, max1 = -DBL_MAX;
121+
double min2 = DBL_MAX, max2 = -DBL_MAX;
121122

122123
// Project rect1 onto axis
123124
for (int i = 0; i < 4; i++) {

0 commit comments

Comments
 (0)