Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New ImageTypes enum class #2093

Merged
merged 8 commits into from
Feb 15, 2022
Merged

New ImageTypes enum class #2093

merged 8 commits into from
Feb 15, 2022

Conversation

piponazo
Copy link
Collaborator

In this PR I just focus in the addition of a new enum class ImageType to replace the previous namespace in which we were adding global constant values for the image types.

Note that the characterisation tests have revealed some bugs that I also fixed in this branch.

Note that this has been rescued from the old_master branch. The PR in which these changes were already reviewed and approved is: #737

@codecov
Copy link

codecov bot commented Feb 13, 2022

Codecov Report

Merging #2093 (9c53eed) into main (e450c49) will increase coverage by 0.45%.
The diff coverage is 79.16%.

❗ Current head 9c53eed differs from pull request most recent head 408d80b. Consider uploading reports for the commit 408d80b to get more accurate results

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2093      +/-   ##
==========================================
+ Coverage   63.19%   63.64%   +0.45%     
==========================================
  Files          96       96              
  Lines       19203    19206       +3     
  Branches     9797     9798       +1     
==========================================
+ Hits        12135    12224      +89     
+ Misses       4762     4680      -82     
+ Partials     2306     2302       -4     
Impacted Files Coverage Δ
include/exiv2/bmffimage.hpp 100.00% <ø> (ø)
include/exiv2/pgfimage.hpp 100.00% <ø> (ø)
src/actions.cpp 63.60% <ø> (ø)
src/image.cpp 71.42% <75.00%> (+7.48%) ⬆️
include/exiv2/image.hpp 100.00% <100.00%> (ø)
include/exiv2/types.hpp 70.58% <100.00%> (ø)
src/jpgimage.cpp 70.43% <100.00%> (ø)
src/psdimage.cpp 62.28% <0.00%> (+0.67%) ⬆️
src/jp2image.cpp 69.85% <0.00%> (+0.70%) ⬆️
src/webpimage.cpp 49.88% <0.00%> (+0.95%) ⬆️
... and 11 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e450c49...408d80b. Read the comment docs.

@piponazo
Copy link
Collaborator Author

I'll wait for #2090 to be merged. The errors triggered on the MSYS build are around code that will be removed at #2090

@piponazo piponazo merged commit 0a135ff into main Feb 15, 2022
@piponazo piponazo deleted the main_ImageTypes branch February 15, 2022 07:31
@clanmills
Copy link
Collaborator

Gentlemen: This changed caused me a build issue in actions.cpp. It turned out to be a conflict with /usr/local/include/exiv2. My fix was $ sudo rm -rf /usr/local/include/exiv2.

I don't think any change is required and I'm recording this here as it may help another user.

[ 79%] Building CXX object src/CMakeFiles/exiv2.dir/actions.cpp.o
/Users/rmills/gnu/github/exiv2/main/src/actions.cpp:121:76: error: no type named 'ImageType' in namespace 'Exiv2'
    int metacopy(const std::string& source, const std::string& tgt, Exiv2::ImageType targetType, bool preserve);
                                                                    ~~~~~~~^
/Users/rmills/gnu/github/exiv2/main/src/actions.cpp:579:51: error: no member named 'toInt64' in 'Exiv2::Value'
                    const auto value = md.value().toInt64(c);
                                       ~~~~~~~~~~ ^
/Users/rmills/gnu/github/exiv2/main/src/actions.cpp:1814:25: error: no type named 'ImageType' in namespace 'Exiv2'
                 Exiv2::ImageType targetType,
                 ~~~~~~~^
3 errors generated.
make[2]: *** [src/CMakeFiles/exiv2.dir/actions.cpp.o] Error 1
make[1]: *** [src/CMakeFiles/exiv2.dir/all] Error 2
make: *** [all] Error 2
623 rmills@rmillsm1:~/gnu/github/exiv2/main/build $

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants