mirror of
https://github.com/raysan5/raylib.git
synced 2025-10-08 10:56:28 +00:00
Replace 0.f by 0.0f
This commit is contained in:
@@ -236,7 +236,7 @@ static void DisableCursor() {} // Lock cursor
|
||||
static int IsKeyDown(int key) { return 0; }
|
||||
|
||||
static int IsMouseButtonDown(int button) { return 0;}
|
||||
static float GetMouseWheelMove() { return 0.f; }
|
||||
static float GetMouseWheelMove() { return 0.0f; }
|
||||
static Vector2 GetMousePosition() { return (Vector2){ 0.0f, 0.0f }; }
|
||||
#endif
|
||||
|
||||
|
10
src/core.c
10
src/core.c
@@ -2725,9 +2725,9 @@ void SetMouseScale(float scaleX, float scaleY)
|
||||
float GetMouseWheelMove(void)
|
||||
{
|
||||
#if defined(PLATFORM_ANDROID)
|
||||
return 0.f;
|
||||
return 0.0f;
|
||||
#elif defined(PLATFORM_WEB)
|
||||
return CORE.Input.Mouse.previousWheelMove/100.f;
|
||||
return CORE.Input.Mouse.previousWheelMove/100.0f;
|
||||
#else
|
||||
return CORE.Input.Mouse.previousWheelMove;
|
||||
#endif
|
||||
@@ -3896,7 +3896,7 @@ static void PollInputEvents(void)
|
||||
|
||||
// Register previous mouse states
|
||||
CORE.Input.Mouse.previousWheelMove = CORE.Input.Mouse.currentWheelMove;
|
||||
CORE.Input.Mouse.currentWheelMove = 0.f;
|
||||
CORE.Input.Mouse.currentWheelMove = 0.0f;
|
||||
for (int i = 0; i < 3; i++)
|
||||
{
|
||||
CORE.Input.Mouse.previousButtonState[i] = CORE.Input.Mouse.currentButtonState[i];
|
||||
@@ -3918,7 +3918,7 @@ static void PollInputEvents(void)
|
||||
|
||||
// Register previous mouse states
|
||||
CORE.Input.Mouse.previousWheelMove = CORE.Input.Mouse.currentWheelMove;
|
||||
CORE.Input.Mouse.currentWheelMove = 0.f;
|
||||
CORE.Input.Mouse.currentWheelMove = 0.0f;
|
||||
|
||||
for (int i = 0; i < 3; i++) CORE.Input.Mouse.previousButtonState[i] = CORE.Input.Mouse.currentButtonState[i];
|
||||
#endif // PLATFORM_UWP
|
||||
@@ -3934,7 +3934,7 @@ static void PollInputEvents(void)
|
||||
|
||||
// Register previous mouse wheel state
|
||||
CORE.Input.Mouse.previousWheelMove = CORE.Input.Mouse.currentWheelMove;
|
||||
CORE.Input.Mouse.currentWheelMove = 0.f;
|
||||
CORE.Input.Mouse.currentWheelMove = 0.0f;
|
||||
#endif
|
||||
|
||||
// Register previous touch states
|
||||
|
@@ -587,7 +587,7 @@ Image GenImageGradientRadial(int width, int height, float density, Color inner,
|
||||
float dist = hypotf((float)x - centerX, (float)y - centerY);
|
||||
float factor = (dist - radius*density)/(radius*(1.0f - density));
|
||||
|
||||
factor = (float)fmax(factor, 0.f);
|
||||
factor = (float)fmax(factor, 0.0f);
|
||||
factor = (float)fmin(factor, 1.f); // dist can be bigger than radius so we have to check
|
||||
|
||||
pixels[y*width + x].r = (int)((float)outer.r*factor + (float)inner.r*(1.0f - factor));
|
||||
|
Reference in New Issue
Block a user