Skip to content

Snap to view#23674

Open
taishi-sama wants to merge 7 commits intobevyengine:mainfrom
taishi-sama:snap_to_view
Open

Snap to view#23674
taishi-sama wants to merge 7 commits intobevyengine:mainfrom
taishi-sama:snap_to_view

Conversation

@taishi-sama
Copy link
Copy Markdown

Objective

Solution

  • Adds snap_to_view module behind free_camera feature flag

Testing

  • Manually tested with cargo run --example free_camera_controller --features="free_camera bevy_dev_tools" and cargo run --example scene_viewer --features="free_camera bevy_dev_tools":
    • All six hotkeys works.
      • [LCtrl +] Numpad1 - Snap to front/back
      • [LCtrl +] Numpad3 - Snap to right/left
      • [LCtrl +] Numpad7 - Snap to top/bottom
  • Tested on Linux (Wayland)

Showcase

2026-04-05.18-35-40.mp4

Add SnapToViewCamera component to any Camera3d entity.
Change parameters inside SnapToViewCamera to change snap speed and hotkeys.

app.add_plugins(SnapToViewPlugin);

commands.spawn((
    Camera3d::default(),
    SnapToViewCamera::default(),
));

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 5, 2026

Welcome, new contributor!

Please make sure you've read our contributing guide, as well as our policy regarding AI usage, and we look forward to reviewing your pull request shortly ✨

@kfc35 kfc35 added C-Feature A new feature, making something new possible S-Needs-Review Needs reviewer attention (from anyone!) to move forward A-Camera User-facing camera APIs and controllers. D-Modest A "normal" level of difficulty; suitable for simple features or challenging fixes A-Dev-Tools Tools used to debug Bevy applications. labels Apr 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Camera User-facing camera APIs and controllers. A-Dev-Tools Tools used to debug Bevy applications. C-Feature A new feature, making something new possible D-Modest A "normal" level of difficulty; suitable for simple features or challenging fixes S-Needs-Review Needs reviewer attention (from anyone!) to move forward

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants