Fix vcam_enum_framesizes to enumerate all sizes when scaling is enabled#44
Open
davidzwei wants to merge 1 commit into
Open
Fix vcam_enum_framesizes to enumerate all sizes when scaling is enabled#44davidzwei wants to merge 1 commit into
davidzwei wants to merge 1 commit into
Conversation
jserv
requested changes
May 29, 2026
Collaborator
jserv
left a comment
There was a problem hiding this comment.
Read https://cbea.ms/git-commit/ carefully and enforce the rules.
Collaborator
|
Provide test cases to reproduce. |
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.
When scaling is enabled,
vcam_enum_framesizesonly returned one frame size because the index guard was never updated after the branch was changed. The original else block also became unreachable dead code.Fix by removing the dead code and enumerating
vcam_sizes[]by index.Summary by cubic
Fixes vcam_enum_framesizes to return all discrete frame sizes when scaling is enabled, instead of only one. Cleans up dead code and adds a proper bounds check.
vcam_sizesby index to set each discrete size.fsize->index > 0with>= ARRAY_SIZE(vcam_sizes)and removes the unreachable stepwise branch.Written for commit c069436. Summary will update on new commits. Review in cubic