diff options
| author | Ray <raysan5@gmail.com> | 2016-12-09 10:15:44 +0100 |
|---|---|---|
| committer | Ray <raysan5@gmail.com> | 2016-12-09 10:15:44 +0100 |
| commit | d5c0f9d3867887f86d754a031c7572ca76dcffd9 (patch) | |
| tree | 6fb79b4afccd26edd2d12628bfddde651771a0ea /src | |
| parent | 377dcb025fb6957f73263e1913dfc5f29ba21a58 (diff) | |
| download | raylib-d5c0f9d3867887f86d754a031c7572ca76dcffd9.tar.gz raylib-d5c0f9d3867887f86d754a031c7572ca76dcffd9.zip | |
Replaced log2() function by equivalent
log2() is not available in some standard C library implementations
Diffstat (limited to 'src')
| -rw-r--r-- | src/rlgl.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1780,7 +1780,7 @@ void rlglGenerateMipmaps(Texture2D *texture) #define MIN(a,b) (((a)<(b))?(a):(b)) #define MAX(a,b) (((a)>(b))?(a):(b)) - texture->mipmaps = 1 + (int)floor(log2(MAX(texture->width, texture->height))); + texture->mipmaps = 1 + (int)floor(log(MAX(texture->width, texture->height))/log(2)); #endif } else TraceLog(WARNING, "[TEX ID %i] Mipmaps can not be generated", texture->id); |
