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

Shutter speed, ISO and aperture #36

Open
art-den opened this issue Feb 8, 2022 · 8 comments
Open

Shutter speed, ISO and aperture #36

art-den opened this issue Feb 8, 2022 · 8 comments

Comments

@art-den
Copy link

art-den commented Feb 8, 2022

Hi! Is there any hope that shutter speed, ISO and aperture will appear in RawImage struct? How difficult is it to implement?

@art-den art-den changed the title Shutter speed, ISO and aperture will appear in RawImage struct Shutter speed, ISO and aperture Feb 8, 2022
@pedrocr
Copy link
Owner

pedrocr commented Feb 21, 2022

Hey there. I've considered doing it in the past for the formats I most care about. Other projects don't bundle this functionality because it's a whole other can of worms compared to raw decoding, but there's a lot in common. A lot of the parsing is the same and saner formats will have that information accessible very easily as EXIF uses the TIFF structure for most of its work and there's already a parser for that.

So I'd definitely take a PR that adds an Option<EXIFInfo> or something like that to RawImage and adds support for at least one format. Depending on what format you care about most that may even be an easy thing to do based on the existing parser.

@art-den
Copy link
Author

art-den commented Mar 21, 2022

Look at #37 (comment)

@inferiorhumanorgans
Copy link

What's the intended scope? Expose an EXIF blob or actually parse the EXIF data?

@art-den
Copy link
Author

art-den commented Mar 21, 2022

NativeExitItem store raw EXIF blob copied from TiffEntry. Blob is parsed only if you call getters (ExifInfo::get_uint, ExifInfo::get_rational etc). This is more safe if you don't want use EXIF data because it just copies bytes and can't fail if something goes wrong

@art-den
Copy link
Author

art-den commented Mar 21, 2022

By the way, how to test this library? Is there a set of RAW files to check if I broke something?

@inferiorhumanorgans
Copy link

@art-den Yeah I don't think there's much in the way of testing, and given how large RAW files are I'm not sure that a test suite belongs in this repo. However, copyright-free samples from a variety of cameras are available here:

http://www.rawsamples.ch/index.php/en/

This piqued my interest as I'd like to expose the metadata and thumbnails in a NEF file. To that end I've started work on a quick NEF parser and would be happy to contribute whatever to ensure that metadata also works with Nikon files.

@pedrocr
Copy link
Owner

pedrocr commented Apr 15, 2022

To test rawloader I use the raw library from here:

https://raw.pixls.us/

I have some personal scripts I use to do some checks, but I've been meaning to add to this repo a way to run quick regression testing across the whole library:

  1. A simple binary that writes a text output of the rawloader decoding result for a file. Basically all the metadata and some hash of the file contents.
  2. A script that downloads all the files from the archive if you don't have them yet, runs the binary on each, and compares the output to a stored output in the repo

Once the initial download is done, running the test becomes fast.

@art-den
Copy link
Author

art-den commented Apr 19, 2022

I have added exif support to almost all formats. I want to test it before submitting a pull request

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

No branches or pull requests

3 participants