Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@sturkmen72
Copy link
Contributor

@sturkmen72 sturkmen72 commented Jun 26, 2024

Related : #24855

adds getFrameCount() member function to BaseImageDecoder.

Pull Request Readiness Checklist

See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request

  • I agree to contribute to the project under Apache 2 License.
  • To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV
  • The PR is proposed to the proper branch
  • There is a reference to the original bug report and related work
  • There is accuracy test, performance test and test data in opencv_extra repository, if applicable
    Patch to opencv_extra has the same branch name.
  • The feature is well documented and sample code can be built with the project CMake

@asmorkalov asmorkalov changed the title add numFrames add numFrames to image codecs Jun 26, 2024
@asmorkalov asmorkalov added this to the 4.11.0 milestone Jun 26, 2024
@sturkmen72 sturkmen72 force-pushed the numFrames branch 2 times, most recently from 149900b to 817a0f1 Compare June 26, 2024 12:10
@sturkmen72 sturkmen72 marked this pull request as draft June 28, 2024 19:15
@sturkmen72
Copy link
Contributor Author

@asmorkalov @vrabaud in the beginning used numframes() name and later frame_count() name. what is your opinion and any other naming suggestions.

@dan-masek
Copy link
Contributor

All the other member functions of BaseImageDecoder appear to use camelCase, so frame_count() is not consistent. However, I do like "frame count" more than abbreviated "number of frames".... so perhaps frameCount()?

@sturkmen72
Copy link
Contributor Author

@dan-masek thank you for your reminding cameCase.. getFrameCount() looks good to me.

@sturkmen72 sturkmen72 changed the title add numFrames to image codecs add getFrameCount() member function to BaseImageDecoder Jun 30, 2024
@sturkmen72 sturkmen72 marked this pull request as ready for review June 30, 2024 20:51
@asmorkalov asmorkalov requested a review from vpisarev July 1, 2024 05:49
@sturkmen72 sturkmen72 marked this pull request as draft July 1, 2024 08:48
@vrabaud
Copy link
Contributor

vrabaud commented Jul 1, 2024

Hmmm, I am not sure this is the right way to go: it is going to clutter the image decoding API. Let's create a proper animation decoder class instead.

@sturkmen72
Copy link
Contributor Author

sturkmen72 commented Jul 1, 2024

@vrabaud imho this PR mostly related current image decoders. TIFF Avif etc.

@sturkmen72 sturkmen72 marked this pull request as ready for review July 3, 2024 17:09
@vrabaud
Copy link
Contributor

vrabaud commented Jul 4, 2024

imcount now returns the number of frames of an animation (e.g. AVIF), not just a multi-page image anymore. The doc needs to be updated.

@sturkmen72
Copy link
Contributor Author

imcount now returns the number of frames of an animation (e.g. AVIF), not just a multi-page image anymore. The doc needs to be updated.

@vrabaud could you please check the documentation update.

@vrabaud
Copy link
Contributor

vrabaud commented Jul 5, 2024

THx @sturkmen72 . @asmorkalov , I believe it is good to go

@asmorkalov
Copy link
Contributor

@vrabaud please approve the PR then.

@asmorkalov asmorkalov merged commit eab21b6 into opencv:4.x Jul 24, 2024
@sturkmen72 sturkmen72 deleted the numFrames branch July 24, 2024 15:24
@asmorkalov asmorkalov mentioned this pull request Jul 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants