Exemple #1
0
	void OGLApp::glfw_scroll(GLFWwindow* window, double xoffset, double yoffset)
	{
#ifdef USE_ANT
		TwEventMouseWheelGLFW(xoffset);
#endif
		app->v_scrollCallback(window, xoffset, yoffset);
	}
static void onMouseScroll(GLFWwindow* window, double xoffset, double yoffset)
{
	// AntTweakBar event
	if (TwEventMouseWheelGLFW(int(yoffset)))
		return;

	s_camera.zoom((float) yoffset);
}
Exemple #3
0
// Callback function called by GLFW on mouse wheel event
void GLFWCALL OnMouseWheel(int pos)
{
    if( !TwEventMouseWheelGLFW(pos) )   // Send event to AntTweakBar
    {
        // Event has not been handled by AntTweakBar
        // Do something if needed.
    }
}
Exemple #4
0
// Callback function called by GLFW on mouse wheel event
void GLFWCALL OnMouseWheel(int pos)
{
    if( !TwEventMouseWheelGLFW(pos) )   // Send event to AntTweakBar
    {
    	GUIactive = false;
    }
    else
    	GUIactive = true;
}
Exemple #5
0
void mouseWheel_Aux(GLFWwindow* pWindow, double x, double y)
{
#ifdef USE_ANTTWEAKBAR
    int ant = TwEventMouseWheelGLFW(static_cast<int>(x));
    if (ant != 0)
        return;
#endif
    mouseWheel(pWindow, x, y);
}
void mouseWheel_Aux(GLFWwindow* pWindow, double x, double y)
{
#ifdef USE_ANTTWEAKBAR
    static int scrollpos = 0;
    scrollpos += static_cast<int>(y);
    int ant = TwEventMouseWheelGLFW(scrollpos);
    if (ant != 0)
        return;
#endif
    mouseWheel(pWindow, x, y);
}
Exemple #7
0
void myTwEventMouseWheelGLFW(GLFWwindow* window, double xoffset, double yoffset)
{
	TwEventMouseWheelGLFW((int)yoffset); // Is this correct??
}
	void DebugUIMouseWheel(int pos)
	{
		TwEventMouseWheelGLFW(pos);
	}
Exemple #9
0
void TwEventMouseWheelGLFW3(GLFWwindow* window, double xoffset, double yoffset){TwEventMouseWheelGLFW(yoffset);}
bool Sample::mouse_wheel(int wheel)
{
  return !!TwEventMouseWheelGLFW(wheel); 
}
Exemple #11
0
void scrollCallback(GLFWwindow *window, double x, double y) {
    int tweak = TwEventMouseWheelGLFW((int) y);
}