Remove all trail spaces
This commit is contained in:
parent
a7afd8de99
commit
c3f06b7470
11 changed files with 100 additions and 100 deletions
|
@ -1551,7 +1551,7 @@ Vector2 GetWorldToScreenEx(Vector3 position, Camera camera, int width, int heigh
|
||||||
if (camera.type == CAMERA_PERSPECTIVE)
|
if (camera.type == CAMERA_PERSPECTIVE)
|
||||||
{
|
{
|
||||||
// Calculate projection matrix from perspective
|
// Calculate projection matrix from perspective
|
||||||
matProj = MatrixPerspective(camera.fovy * DEG2RAD, ((double)width/(double)height), DEFAULT_NEAR_CULL_DISTANCE, DEFAULT_FAR_CULL_DISTANCE);
|
matProj = MatrixPerspective(camera.fovy * DEG2RAD, ((double)width/(double)height), DEFAULT_NEAR_CULL_DISTANCE, DEFAULT_FAR_CULL_DISTANCE);
|
||||||
}
|
}
|
||||||
else if (camera.type == CAMERA_ORTHOGRAPHIC)
|
else if (camera.type == CAMERA_ORTHOGRAPHIC)
|
||||||
{
|
{
|
||||||
|
@ -1560,7 +1560,7 @@ Vector2 GetWorldToScreenEx(Vector3 position, Camera camera, int width, int heigh
|
||||||
double right = top*aspect;
|
double right = top*aspect;
|
||||||
|
|
||||||
// Calculate projection matrix from orthographic
|
// Calculate projection matrix from orthographic
|
||||||
matProj = MatrixOrtho(-right, right, -top, top, DEFAULT_NEAR_CULL_DISTANCE, DEFAULT_FAR_CULL_DISTANCE);
|
matProj = MatrixOrtho(-right, right, -top, top, DEFAULT_NEAR_CULL_DISTANCE, DEFAULT_FAR_CULL_DISTANCE);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Calculate view matrix from camera look at (and transpose it)
|
// Calculate view matrix from camera look at (and transpose it)
|
||||||
|
@ -1579,7 +1579,7 @@ Vector2 GetWorldToScreenEx(Vector3 position, Camera camera, int width, int heigh
|
||||||
Vector3 ndcPos = { worldPos.x/worldPos.w, -worldPos.y/worldPos.w, worldPos.z/worldPos.w };
|
Vector3 ndcPos = { worldPos.x/worldPos.w, -worldPos.y/worldPos.w, worldPos.z/worldPos.w };
|
||||||
|
|
||||||
// Calculate 2d screen position vector
|
// Calculate 2d screen position vector
|
||||||
Vector2 screenPosition = { (ndcPos.x + 1.0f)/2.0f*(float)width, (ndcPos.y + 1.0f)/2.0f*(float)height };
|
Vector2 screenPosition = { (ndcPos.x + 1.0f)/2.0f*(float)width, (ndcPos.y + 1.0f)/2.0f*(float)height };
|
||||||
|
|
||||||
return screenPosition;
|
return screenPosition;
|
||||||
}
|
}
|
||||||
|
@ -2455,7 +2455,7 @@ bool IsMouseButtonPressed(int button)
|
||||||
#else
|
#else
|
||||||
// NOTE: On PLATFORM_DESKTOP and PLATFORM_WEB IsMouseButtonPressed() is equivalent to GESTURE_TAP
|
// NOTE: On PLATFORM_DESKTOP and PLATFORM_WEB IsMouseButtonPressed() is equivalent to GESTURE_TAP
|
||||||
if (((CORE.Input.Mouse.currentButtonState[button] != CORE.Input.Mouse.previousButtonState[button]) &&
|
if (((CORE.Input.Mouse.currentButtonState[button] != CORE.Input.Mouse.previousButtonState[button]) &&
|
||||||
(CORE.Input.Mouse.currentButtonState[button] == 1)) || IsGestureDetected(GESTURE_TAP)) pressed = true;
|
(CORE.Input.Mouse.currentButtonState[button] == 1)) || IsGestureDetected(GESTURE_TAP)) pressed = true;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return pressed;
|
return pressed;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue