Expand description
Camera Controllers and tools for editor like 3D views
Inspired by Blender’s viewport camera controls and tools and provide the same functionalities:
- Pan/Orbit/Zoom camera controls with “Zoom to mouse position” and “Auto depth”.
- Fly camera controls with zooming (back, forward), panning (left, right, down, up) and speed controls.
- Set viewpoint: View from left, right, front, back, top and bottom.
- Frame entities into view: Allowing to do things like framing the whole scene, or the selected objects.
- Switch between orthographic and perspective camera projection
Modules§
- raycast
- Raycast utilities
Structs§
- Active
Camera Data - Tracks which
PanOrbitCamera
is active (should handle input events), along with the window and viewport dimensions, which are used for scaling mouse motion.BlendyCamerasPlugin
manages this resource automatically, in order to support multiple viewports/windows. However, if this doesn’t work for you, you can take over and manage it yourself, e.g. when you want to control a camera that is rendering to a texture. - Blendy
Cameras Plugin - Bevy pluging that contains all the systems necessarty to this crate
- FlyCamera
Controller - Component to tag an entiy as able to be controlled in “fly mode”
The entity must have
Transform
andProjection
components. Typically you would addCamera3d
to this entity. - Frame
Event - Event to move the camera to frame certain entities
- Orbit
Camera Controller - Component to tag an entiy as able to be controlled by orbiting, panning
and zooming.
The entity must have
Transform
andProjection
components. Typically you would addCamera3d
to this entity. - Switch
Projection - Event to switch between perspective and ortographic camera projections
- Switch
ToFly Controller - Event to enable the
FlyCameraController
and disable theOrbitCameraController
if present - Switch
ToOrbit Controller - Event to enable the
OrbitCameraController
and disable theFlyCameraController
if present - Viewpoint
Event - Event used to set the camera point of view
Enums§
- Blendy
Cameras System Set - System set to allow ordering
- Viewpoint
- Point of view of a camera, looking in the oposite direction
Functions§
- get_
camera_ entity_ from_ cursor_ position - Get the camera entity that renders to the viewport under the mouse cursor with highest rendering order.