FlowArithmeticCalculator
1.0.0
Flow Arithmetic Calculator
Loading...
Searching...
No Matches
helpers.cpp
Go to the documentation of this file.
1
#include "
helpers.h
"
2
3
namespace
business_logic::geometry
{
4
bool
isCircleHovered
(
int
mouseX,
int
mouseY,
int
cX,
int
cY,
int
radius) {
5
// for simplicity, performance and usability, check if the mouse is within a square
6
// that bounds the circle
7
return
mouseX >= cX - radius && mouseX <= cX + radius && mouseY >= cY - radius &&
8
mouseY <= cY + radius;
9
}
10
}
// namespace business_logic::geometry
helpers.h
business_logic::geometry
The 2D geometry utility module.
Definition
helpers.cpp:3
business_logic::geometry::isCircleHovered
bool isCircleHovered(int mouseX, int mouseY, int cX, int cY, int radius)
Check if a point is within a circle.
Definition
helpers.cpp:4
src
business_logic
geometry
helpers.cpp
Generated by
1.9.8