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

implement png read routines #222

Merged
merged 2 commits into from
Jan 10, 2025
Merged

implement png read routines #222

merged 2 commits into from
Jan 10, 2025

Conversation

edgarriba
Copy link
Member

This pull request introduces support for PNG image encoding and decoding in the kornia-io crate. The changes include adding dependencies, error handling, and new functions for reading PNG images with different channel configurations.

PNG Support:

  • Added png dependency in Cargo.toml to support PNG image processing.
  • Introduced a new error variant PngDecodeError in the IoError enum to handle PNG decoding errors.
  • Added a new module png in lib.rs for PNG image encoding and decoding.
  • Implemented functions in png.rs for reading PNG images with different channel configurations (mono8, rgb8, rgba8) and a utility function for reading PNG files.

These changes enhance the kornia-io crate by providing comprehensive support for handling PNG images, including error management and testing.

@powei-lin
Copy link

Can you add read mono16, please? For this dataset. https://cvg.cit.tum.de/data/datasets/visual-inertial-dataset

@edgarriba
Copy link
Member Author

@powei-lin done -- verified quickly with the rerun and could viz correctly

@edgarriba edgarriba merged commit e002a30 into main Jan 10, 2025
11 checks passed
@edgarriba edgarriba deleted the read-png branch January 10, 2025 17:04
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