Update changed cameras in camera_system.#5694
Closed
HackerFoo wants to merge 1 commit intobevyengine:mainfrom
Closed
Update changed cameras in camera_system.#5694HackerFoo wants to merge 1 commit intobevyengine:mainfrom
camera_system.#5694HackerFoo wants to merge 1 commit intobevyengine:mainfrom
Conversation
Contributor
|
This system already updates every camera where the target or projection was changed. |
alice-i-cecile
approved these changes
Sep 6, 2022
Member
alice-i-cecile
left a comment
There was a problem hiding this comment.
This change makes sense to me, and based on my understanding of the logic seems correct. Other fields may change on cameras in surprising ways, and we should be sure to catch those.
| .target | ||
| .is_changed(&changed_window_ids, &changed_image_handles) | ||
| || added_cameras.contains(&entity) | ||
| || changed_cameras.contains(&entity) |
Contributor
There was a problem hiding this comment.
Suggested change
| || changed_cameras.contains(&entity) | |
| || camera.is_changed() |
Using is_changed on camera makes the second query unnecessary.
james7132
reviewed
Oct 25, 2022
Member
james7132
left a comment
There was a problem hiding this comment.
@HackerFoo do you mind addressing @devil-ira's comment? This would be an approval if it were not for that one potential change.
Contributor
|
This was superceded by #5945 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Objective
A
Camerashould be updated bycamera_systemwhenever it changes, not just when added.Solution
Replace the
Addedquery filter withChanged.