Harden panning via bound check - #3899
Merged
Merged
Conversation
Member
Author
|
std::clamp would have been better - however, I believe it is not available unless we up the C++ version. |
ann0see
marked this pull request as ready for review
August 13, 2026 17:28
Member
Ok, I have missed this. We use c++17 for some things already. Maybe this is an opportunity to up the version? |
Member
Author
Not in this PR. Float2Short could then also be made easier I think. But again, not in this PR. |
pljones
approved these changes
Aug 13, 2026
dingodoppelt
approved these changes
Aug 13, 2026
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.
Short description of changes
Bounds pan values to always be in range. In theory, the network values could have been any value. Thus bounding those is needed.
CHANGELOG: Bug: Ensure correct bounds for panning
Context: Fixes an issue?
No. Found by @mcfnord via AI review.
Does this change need documentation? What needs to be documented and how?
No.
Status of this Pull Request
Ready for review (fast review!)
What is missing until this pull request can be merged?
Review.
Checklist