How to permit user to change view using mouse interface in GLFW using Python? [Interface]

Hi All.
I’m new to GLFW but already found it useful - especially to work with .obj & textures.
I also found how to show up the model to turn around on its own, etc.

What we can’t find yet is how to offer the customer to have similar mouse interface like in Sketchfab (for example: or Blender?
LM - turn around the axis
RM - move left, right, up, down
Wheel - zoom in / out
and so on.

Can you advise which command / library / function or advise on the code please?


Hi Eric,

Welcome to the GLFW forums.

This is not specifically a GLFW question, other than the fact you’ll need to use GLFW mouse and keyboard inputs to achieve what you want. The type of camera used in Sketchfab is called an arc ball camera. There’s a decent tutorial of how to create an arc ball camera with GLFW and GLM on, and if you search for arc ball camera tutorials you’ll find a few more examples though they may not use GLFW - however the principles remain the same.