{"id":15017979,"url":"https://github.com/blackphlox/bevy_config_cam","last_synced_at":"2025-04-05T12:03:38.674Z","repository":{"id":41994836,"uuid":"361595820","full_name":"BlackPhlox/bevy_config_cam","owner":"BlackPhlox","description":"A Swiss Army knife of a camera plugin that allows for easy setup and configuration of a wide variety of types of moveable cameras and player cameras for a scene.","archived":false,"fork":false,"pushed_at":"2023-09-17T20:51:31.000Z","size":769,"stargazers_count":186,"open_issues_count":13,"forks_count":15,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-05T12:03:32.964Z","etag":null,"topics":["bevy","camera","cameracontroller","plugin"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BlackPhlox.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2021-04-26T02:40:08.000Z","updated_at":"2025-03-12T02:27:49.000Z","dependencies_parsed_at":"2023-10-20T18:28:27.523Z","dependency_job_id":null,"html_url":"https://github.com/BlackPhlox/bevy_config_cam","commit_stats":{"total_commits":80,"total_committers":5,"mean_commits":16.0,"dds":"0.36250000000000004","last_synced_commit":"ababf3fa6972589e9dfc144dd91f592c0347e93d"},"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackPhlox%2Fbevy_config_cam","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackPhlox%2Fbevy_config_cam/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackPhlox%2Fbevy_config_cam/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlackPhlox%2Fbevy_config_cam/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BlackPhlox","download_url":"https://codeload.github.com/BlackPhlox/bevy_config_cam/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247332560,"owners_count":20921853,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bevy","camera","cameracontroller","plugin"],"created_at":"2024-09-24T19:51:16.883Z","updated_at":"2025-04-05T12:03:38.655Z","avatar_url":"https://github.com/BlackPhlox.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"left\"\u003e\n\u003ca href=\"https://github.com/BlackPhlox/bevy_config_cam\"\u003e\u003cimg src=\"https://raw.githubusercontent.com/BlackPhlox/BlackPhlox/master/config_cam.svg\" width=\"970\" height=\"200\" alt=\"bevy config cam\"\u003e\u003c/a\u003e\n\u003c/div\u003e\n\u003c/br\u003e\n\u003cdiv align=\"center\"\u003e\n\u003ca href=\"https://crates.io/crates/bevy_config_cam\"\u003e\u003cimg src=\"https://img.shields.io/crates/v/bevy_config_cam\" alt=\"link to crates.io\"\u003e\u003c/a\u003e\n\u003ca href=\"https://docs.rs/bevy_config_cam\"\u003e\u003cimg src=\"https://docs.rs/bevy_config_cam/badge.svg\" alt=\"link to docs.rs\"\u003e\u003c/a\u003e\n\u003ca href=\"https://github.com/BlackPhlox/bevy_config_cam/blob/master/credits/CREDITS.md\"\u003e\u003cimg src=\"https://img.shields.io/crates/l/bevy_config_cam\" alt=\"link to license\"\u003e\u003c/a\u003e\n\u003ca href=\"https://crates.io/crates/bevy_config_cam\"\u003e\u003cimg src=\"https://img.shields.io/crates/d/bevy_config_cam\" alt=\"downloads/link to crates.io\"\u003e\u003c/a\u003e   \n\u003ca href=\"https://github.com/BlackPhlox/bevy_config_cam\"\u003e\u003cimg src=\"https://img.shields.io/github/stars/BlackPhlox/bevy_config_cam\" alt=\"stars/github repo\"\u003e\u003c/a\u003e\n\u003ca href=\"https://github.com/BlackPhlox/bevy_config_cam/actions/workflows/master.yml\"\u003e\u003cimg src=\"https://github.com/BlackPhlox/bevy_config_cam/actions/workflows/master.yml/badge.svg\" alt=\"github actions\"\u003e\u003c/a\u003e\n\u003ca href=\"https://github.com/bevyengine/bevy/blob/main/docs/plugins_guidelines.md#main-branch-tracking\"\u003e\u003cimg src=\"https://img.shields.io/badge/Bevy%20tracking-released%20version-lightblue\" alt=\"tracking bevy release branch\"\u003e\u003c/a\u003e\n\u003c/div\u003e\n\u003c/br\u003e\nAn easy plug-n-play multifunctional camera controller that allows for easy setup of a camera and player for a scene.\n\nAdd a few lines of code to your existing project allows you to test a wide variety of cameras by attaching it to\nyour player asset or the default red player entity. \n\nInspired and extended on [bevy_flycam](https://github.com/sburris0/bevy_flycam), this plugin is fairly simple but should be a neat help for developers looking for a camera implementation without going the hassle of reinventing the wheel.\n\n# Future Plans\n\nThe main goal of this plugin is to first and foremost provide the user with a configurable, extendable and easy-to-use API. [`dolly`](https://github.com/h3r2tic/dolly) by @h3r2tic is a crate that provides an framework for which to create, combine and modify camera positioning, exactly what `bevy_config_cam` is looking for. So a migration to `dolly` is in the works in order to improve this plugin main goal. \n\n# Showcase\n\n## Camera Modes\n\nLookAt | FollowStatic\n:-------------------------:|:-------------------------:\n\u003cimg src=\"https://user-images.githubusercontent.com/25123512/119991088-5fb59700-bfc9-11eb-88d1-44a2b2a47cfa.png\" style=\"width:700px;height:300px;\" alt=\"LookAt\"\u003e  |  \u003cimg src=\"https://user-images.githubusercontent.com/25123512/119991121-6cd28600-bfc9-11eb-9fcd-89fa9d591d4b.png\" style=\"width:700px;height:300px;\" alt=\"FollowStatic\"\u003e\n\nTopDown | TopDownDirection\n:-------------------------:|:-------------------------:\n\u003cimg src=\"https://user-images.githubusercontent.com/25123512/119991141-71973a00-bfc9-11eb-90ee-377ffe656ae2.png\" style=\"width:700px;height:300px;\" alt=\"TopDown\"\u003e |  \u003cimg src=\"https://user-images.githubusercontent.com/25123512/119991151-7360fd80-bfc9-11eb-9d41-1947c997b98a.png\" style=\"width:700px;height:300px;\" alt=\"TopDownDirection\"\u003e\n\nFollowBehind | Fps\n:-------------------------:|:-------------------------:\n\u003cimg src=\"https://user-images.githubusercontent.com/25123512/119991175-7956de80-bfc9-11eb-901c-0164152dd97d.png\" style=\"width:600px;height:300px;\" alt=\"FollowBehind\"\u003e  |  \u003cimg src=\"https://user-images.githubusercontent.com/25123512/119991187-7bb93880-bfc9-11eb-9739-598e01ba214f.png\" style=\"width:700px;height:300px;\" alt=\"Fps\"\u003e\n\nFree | ?\n:-------------------------:|:-------------------------:\n\u003cimg src=\"https://user-images.githubusercontent.com/25123512/119991199-7fe55600-bfc9-11eb-9ae6-b29cec3a3cd7.png\" alt=\"Free\" \u003e  |  Any suggestions on other camera modes you want? Let me know by creating an issue :)\n\n## Settings\n\n| Camera Mode | Disc. | Demo |\n| --- | --- | --- |\n| MovementSpeed (Camera) | Change the speed of there cameras movement | |\n| Sensitivity | Change the sensitivity of the cameras mouse movement | |\n| Lerp | Change the linear interpolation between the target and the player (LookAt camera-mode only)||\n| Zoom/FOV| Change the FOV of the camera | \u003cimg src=\"https://user-images.githubusercontent.com/25123512/119991256-8d9adb80-bfc9-11eb-9e1d-5d763ec150a2.png\" alt=\"LowFOV\" width=\"250\"\u003e |\n| CamFwd (Unused) | Toggle between xyz movement relative to world coords or camera local coords and rotation (Free camera-mode only)||\n\n# Getting started\n\n## Test the project\n\nBefore I start using a plugin, I all ways like to run the examples prior to setting it up for my own project. Just to see if the plugin satisfy my needs. \nIf you're like me then this is for you.\n\n1. Clone this repo to your local machine\n2. Go into the project folder (`cd bevy_config_cam`)\n3. And run the cargo command (`cargo run --release --example simple`)\n4. Test functionality \u003c/br\u003e\nPlayer : \u003ckbd\u003e↑\u003c/kbd\u003e\u003ckbd\u003e←\u003c/kbd\u003e\u003ckbd\u003e↓\u003c/kbd\u003e\u003ckbd\u003e→\u003c/kbd\u003e for movement, \u003ckbd\u003eRShift\u003c/kbd\u003e \u0026 \u003ckbd\u003e-\u003c/kbd\u003e for going up and down.\u003cbr\u003e\nCamera : \u003ckbd\u003eW\u003c/kbd\u003e\u003ckbd\u003eA\u003c/kbd\u003e\u003ckbd\u003eS\u003c/kbd\u003e\u003ckbd\u003eD\u003c/kbd\u003e for movement, \u003ckbd\u003eSpace\u003c/kbd\u003e \u0026 \u003ckbd\u003eLShift\u003c/kbd\u003e for going up and down.\u003cbr\u003e\nSwitch Camera: \u003ckbd\u003eC\u003c/kbd\u003e (Look in console for which camera type you are on)\u003c/br\u003e\nSettings: \u003ckbd\u003eE\u003c/kbd\u003e and use the mouse-scroll to change the selected settings value.\n\n## Add to your own project\n\nAdding this plugin to your project is *very* simple, it only requires you to write 2 lines of code. \n\n### Step 1. - Setup\n    \nAdd the correct version to your `Cargo.toml`, you can find the version you are looking for under the support section. The thing you should be adding should look like this (only add the line marked by `# \u003c--`):\n```toml\n[dependencies]\nbevy = { version = \"0.7\"}\n# ...\nbevy_config_cam = { version = \"0.3.0\"} # \u003c-- \n```\n\n### Step 2. - Add to project\n\n```rust\nfn main() {\n    App::new()\n        .insert_resource(Msaa { samples: 4 })\n        .add_plugins(DefaultPlugins)\n        .add_plugin(ConfigCam) // \u003c--\n        // ... \n        // Your other plugins and game code here\n        // ...\n        .run();\n}\n```\n\n### Step 3. - Config (Optional)\n\nNow, there is a reason for the name `bevy_config_cam`. It is most likely that you want something more than just the default behavior. You might want to toggle between 2 types of cameras or allow the user to change the fov using a slider. Currently I haven't gotten far with creating a user-friendly api you can access but is something I will look into. For now you can insert two resources to override the default behavior of the plugin, as seen in the example:\n\n```rust\n    .insert_resource(MovementSettings {\n        sensitivity: 0.00015, // default: 0.00012\n        speed: 15.0,          // default: 12.0\n        dist: 5.0,            // Camera distance from the player in topdown view\n        ..Default::default()\n    })\n    .insert_resource(PlayerSettings {\n        pos: Vec3::new(2., 0., 0.),//Initial position of the player\n        player_asset: \"models/craft_speederA.glb#Scene0\", //Model of the player, default is a red cube\n        ..Default::default()\n    })\n```\nNote: That some of them are overwritten by accessing the settings or the changing the camera type. Feedback on this is high appreciated, just create a new issue and I'll look into it when I have the time.\n\n# Support\n[![Bevy tracking](https://img.shields.io/badge/Bevy%20tracking-released%20version-lightblue)](https://github.com/bevyengine/bevy/blob/main/docs/plugins_guidelines.md#main-branch-tracking)\n\n|bevy|bevy_config_cam|\n|---|---|\n|0.5|0.1.X|\n|0.6|0.2.X|\n|0.7|0.3.X|\n\n# Licensing\nThe project is under dual license MIT and Apache-2.0, so yoink to your hearts content, just remember the license agreements.\n\n# Contributing\nYes this project is still very much WIP, so PRs are very welcome\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblackphlox%2Fbevy_config_cam","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fblackphlox%2Fbevy_config_cam","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblackphlox%2Fbevy_config_cam/lists"}