Trackball Camera's icon

Trackball Camera 6.0 3D Tools 3.0 Community

Submitted by user Goutte; MIT; 2022-10-15

A Trackball Camera that responds to input from actions, mouse, keyboard, joystick and touch, in order to rotate around its parent node while continuously facing it.

Works with Godot 3.x (tested up to 3.5).

- stays around its parent node, even if the latter moves
- no gimbal lock (quaternions ♥)
- camera inertia for a smoother experience
- keep the horizon stable if you want
- the parent node does not have to be centered in the camera's view
- can be used to look around itself
- analog camera control with joystick, courtesy of @marcello505
- smooth and constrained zoom with PGUP / PGDOWN or your own custom action, if you want to use the mouse wheel for example
- constrain pitch, or handle headstands by inverting x
- a bunch of parameters to configure things as you want them

CONS:
- No panning
- No promises

USAGE
1. Add a TrackballCamera node as child of the node you want to trackball around.
2. Translate the camera along the Z axis a little bit, so that it faces its parent.
3. Configure the camera.


View files Download Submit an issue Recent Edits