Imgcodecs minor improvements for better code readibility#26828
Merged
asmorkalov merged 1 commit intoopencv:4.xfrom Jan 25, 2025
Merged
Imgcodecs minor improvements for better code readibility#26828asmorkalov merged 1 commit intoopencv:4.xfrom
asmorkalov merged 1 commit intoopencv:4.xfrom
Conversation
Contributor
|
@sturkmen72 Thanks for the PR! I do not think that io migration to the base class is good idea by several reasons:
|
14d6676 to
b8b4896
Compare
Contributor
Author
|
let me update the PR after #26832 merged |
b8b4896 to
ca51d55
Compare
asmorkalov
approved these changes
Jan 25, 2025
Merged
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.
Pull Request Readiness Checklist
See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request
Patch to opencv_extra has the same branch name.
The PR addresses the following improvements:
1.Improving member functions:
read_from_ioandwrite_to_ioto more descriptive names for better clarity.2.RFC Refactoring functions into the base class with the following considerations (subject to undone):
m_buf_supported = falseto potentially use these functions in the future to support buffer reading.m_fvariable in the base class, which potentially enables efficient handling of file streams by reducing redundant file-opening operations. For example, the source file can be assigned tom_fonce when the decoder is selected, avoiding the need to reopen the file inreadHeader().