GSDP:GAM100/CProcessing/MouseWheelCallbackFunction

From Inside
Jump to: navigation, search

MouseWheelCallbackFunction

Description

The type used to define a callback function that can be set to be called every time the state the mouse wheel changes changes. When making the function, it must have two floats as parameters.

Example

// Must have the two floats as parameters
// The parameters are the offset from the previous wheel position
void MyWheelCallback(float xoffset, float yoffset)
{
    // Use the offsets however you see fit
    if(yoffset != 0.0f)
        ScrollWindow(yoffset);
}

void Init()
{
    // Sets it so every time the mouse wheel 
    // changes your callback function is called
    setMouseWheelCallback(MyWheelCallback);
}

Related

Personal tools
Namespaces

Variants
Actions
Navigation
NameSpaces:>
Tools
Dynamic:>