Skip to content

Conversation

syszery
Copy link
Contributor

@syszery syszery commented Oct 18, 2025

Objective

This PR addresses #21569, which proposes renaming the newly introduced camera controller modules FreeCam and PanCam to use the full term Camera.

This PR resolves the PanCam portion.

Solution

  • Renamed the PanCam controller, PanCamPlugin, and related methods to use the full term Camera instead of the abbreviation Cam.
  • Renamed the module from pan_cam to pan_camera for consistency with naming conventions.
  • Updated the example pan_camera_controller and adjusted usage of the renamed controller and plugin.
  • Updated documentation and release notes accordingly.

Follow-up Work

I see two options from here:

  1. Use this PR as a reference for renaming FreeCam. The process is similar and could be a great first issue for someone looking to contribute to the new camera modules or Bevy in general. Most of the changes follow the same pattern, although FreeCam has more examples that need updating. One could find them using grep (e.g., grep FreeCam) or by reviewing the diff from the PR that introduced FreeCam: Add bevy_camera_controllers crate and move freecam implementation into it #20215

  2. I can continue and update this PR to also handle the FreeCam renaming, if you'd prefer to resolve the entire issue in one go.

@syszery syszery marked this pull request as ready for review October 18, 2025 18:54
@alice-i-cecile
Copy link
Member

I can continue and update this PR to also handle the FreeCam renaming, if you'd prefer to resolve the entire issue in one go.

Please do this :)

@alice-i-cecile alice-i-cecile added C-Usability A targeted quality-of-life change that makes Bevy easier to use S-Needs-Review Needs reviewer attention (from anyone!) to move forward A-Camera User-facing camera APIs and controllers. labels Oct 19, 2025
@alice-i-cecile alice-i-cecile added this to the 0.18 milestone Oct 19, 2025
@alice-i-cecile alice-i-cecile added S-Waiting-on-Author The author needs to make changes or address concerns before this can be merged and removed S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Oct 19, 2025
@syszery
Copy link
Contributor Author

syszery commented Oct 20, 2025

I've updated both available camera controllers to consistently use the full term "camera", replacing previous uses of "cam". I aimed to be consistent across crate modules and examples while keeping doc changes minimal and non-invasive.

There’s one remaining detail in free_camera_controller.rs I’d like feedback on:

In the following snippet, I’d like to rename the variables state and controller to camera_state and camera_controller respectively, to better reflect their roles and improve clarity:

let Ok((mut transform, mut state, controller)) = query.single_mut() else {
    return;
};

Do you agree with this change, or would you prefer different names?

Also, this now fixes #21569

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. C-Usability A targeted quality-of-life change that makes Bevy easier to use S-Waiting-on-Author The author needs to make changes or address concerns before this can be merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants