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

Decoder IFD access #412

Merged
merged 7 commits into from Mar 7, 2024
Merged

Decoder IFD access #412

merged 7 commits into from Mar 7, 2024

Conversation

cytrinox
Copy link
Contributor

@cytrinox cytrinox commented Mar 7, 2024

Add WellKnownIFD and Decoder::ifd() to access raw file IFDs

For example, if you know you're dealing with DNG raw files
(Decoder::format_hint) and want to extract OpcodeList3, you can access
the raw IFD with decoder.ifd(WellKnownIFD::Raw) and query this IFD
for DngTag::OpcodeList3 entry.

There are also virtual IFDs. Decoders can provide collections of useful
tags as virtual IFDs like format specific tags that are difficult to
read manually.

This commit introduces two virtual IFDs:
 * VirtualDngRootTags
 * VirtualDngRawTags

These IFDs can be used by any decoder implementation to pass-through
DNG tags to dng-writer. This is useful if a raw file format provides
information that can be used to populate DNG tags.

Decoder::ifd() is implemented only for DNG decoder yet but it's easy
to extend it to all other decoders.

For example, if you know you're dealing with DNG raw files
(Decoder::format_hint) and want to extract OpcodeList3, you can access
the raw IFD with decoder.ifd(WellKnownIFD::Raw) and query this IFD
for DngTag::OpcodeList3 entry.

There are also virtual IFDs. Decoders can provide collections of useful
tags as virtual IFDs like format specific tags that are difficult to
read manually.

This commit introduces two virtual IFDs:
 * VirtualDngRootTags
 * VirtualDngRawTags

These IFDs can be used by any decoder implementation to pass-through
DNG tags to dng-writer. This is useful if a raw file format provides
information that can be used to populate DNG tags.

Decoder::ifd() is implemented only for DNG decoder yet but it's easy
to extend it to all other decoders.
Some cameras embed the raw data inside Makernotes and as Exif
struct is part of analyze metadata during test cases, it would
serialize the whole pixels into yaml files.
@cytrinox cytrinox self-assigned this Mar 7, 2024
@cytrinox cytrinox added enhancement New feature or request dng labels Mar 7, 2024
@cytrinox cytrinox added this to the 0.6.1 milestone Mar 7, 2024
@cytrinox
Copy link
Contributor Author

cytrinox commented Mar 7, 2024

Related to #374 #368

@cytrinox cytrinox merged commit e908048 into dnglab:main Mar 7, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dng enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant