Raylib C++  1.0.0
Encapsulates the raylib library
Static Public Member Functions | List of all members
raylib::helper::input::MouseHelper Class Reference

Helper class for Input-related functions: mouse. More...

#include <MouseHelper.hpp>

Collaboration diagram for raylib::helper::input::MouseHelper:
Collaboration graph

Static Public Member Functions

static bool isMouseButtonPressed (const MouseButton &button)
 Check if a mouse button has been pressed once. More...
 
static bool isMouseButtonDown (const MouseButton &button)
 Check if a mouse button is being pressed. More...
 
static bool isMouseButtonReleased (const MouseButton &button)
 Check if a mouse button has been released once. More...
 
static bool isMouseButtonUp (const MouseButton &button)
 Check if a mouse button is NOT being pressed. More...
 
static int getMouseX ()
 Get the mouse X position. More...
 
static int getMouseY ()
 Get the mouse Y position. More...
 
static Vector2f getMousePosition ()
 Get the mouse position. More...
 
static Vector2f getMouseDelta ()
 Get mouse delta between frames. More...
 
static void setMousePosition (int x, int y)
 Set mouse position XY. More...
 
static void setMouseOffset (int offsetX, int offsetY)
 Set mouse offset. More...
 
static void setMouseScale (float scaleX, float scaleY)
 Set mouse scaling. More...
 
static float getMouseWheelMove ()
 Get mouse wheel movement Y. More...
 
static void setMouseCursor (const MouseCursor &cursor)
 Set mouse cursor. More...
 
static Ray getMouseRay (const Vector2f &mousePosition, const RlCamera &camera)
 Get a ray trace from mouse position. More...
 

Detailed Description

Helper class for Input-related functions: mouse.

Member Function Documentation

◆ getMouseDelta()

Vector2f raylib::helper::input::MouseHelper::getMouseDelta ( )
static

Get mouse delta between frames.

Returns
the mouse delta
Here is the call graph for this function:

◆ getMousePosition()

Vector2f raylib::helper::input::MouseHelper::getMousePosition ( )
static

Get the mouse position.

Returns
the mouse position
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getMouseRay()

Ray raylib::helper::input::MouseHelper::getMouseRay ( const Vector2f mousePosition,
const RlCamera camera 
)
static

Get a ray trace from mouse position.

Parameters
mousePositionthe mouse position
camerathe camera
Returns
the ray trace
Here is the call graph for this function:

◆ getMouseWheelMove()

float raylib::helper::input::MouseHelper::getMouseWheelMove ( )
static

Get mouse wheel movement Y.

Returns
the mouse wheel movement Y

◆ getMouseX()

int raylib::helper::input::MouseHelper::getMouseX ( )
static

Get the mouse X position.

Returns
the mouse X position

◆ getMouseY()

int raylib::helper::input::MouseHelper::getMouseY ( )
static

Get the mouse Y position.

Returns
the mouse Y position

◆ isMouseButtonDown()

bool raylib::helper::input::MouseHelper::isMouseButtonDown ( const MouseButton &  button)
static

Check if a mouse button is being pressed.

Parameters
buttonthe button to check
Returns
true if the button is being pressed

◆ isMouseButtonPressed()

bool raylib::helper::input::MouseHelper::isMouseButtonPressed ( const MouseButton &  button)
static

Check if a mouse button has been pressed once.

Parameters
buttonthe button to check
Returns
true if the button has been pressed once
Here is the caller graph for this function:

◆ isMouseButtonReleased()

bool raylib::helper::input::MouseHelper::isMouseButtonReleased ( const MouseButton &  button)
static

Check if a mouse button has been released once.

Parameters
buttonthe button to check
Returns
true if the button has been released once

◆ isMouseButtonUp()

bool raylib::helper::input::MouseHelper::isMouseButtonUp ( const MouseButton &  button)
static

Check if a mouse button is NOT being pressed.

Parameters
buttonthe button to check
Returns
true if the button is NOT being pressed

◆ setMouseCursor()

void raylib::helper::input::MouseHelper::setMouseCursor ( const MouseCursor &  cursor)
static

Set mouse cursor.

Parameters
cursorthe cursor to set

◆ setMouseOffset()

void raylib::helper::input::MouseHelper::setMouseOffset ( int  offsetX,
int  offsetY 
)
static

Set mouse offset.

Parameters
offsetXthe X offset
offsetYthe Y offset

◆ setMousePosition()

void raylib::helper::input::MouseHelper::setMousePosition ( int  x,
int  y 
)
static

Set mouse position XY.

Parameters
xthe X position
ythe Y position

◆ setMouseScale()

void raylib::helper::input::MouseHelper::setMouseScale ( float  scaleX,
float  scaleY 
)
static

Set mouse scaling.

Parameters
scaleXthe X scaling
scaleYthe Y scaling

The documentation for this class was generated from the following files: