feat(makernote): add MakerNote parser interface and registry#22
Merged
Conversation
Implements MNI-1 (Issue #10) - the foundation for manufacturer-specific MakerNote parsing in the TIFF/EXIF metadata pipeline. ## New Package: internal/parser/tiff/makernote/ - Handler interface: Manufacturer(), Detect(), Parse(), TagName() - Config struct: IFDOffset, OffsetBase, ByteOrder, HasNextIFD, Variant - Registry pattern with ordered detection for manufacturer routing - Detection functions for all major manufacturers: - Nikon Type 3: 'Nikon' + 0x02 (embedded TIFF header) - Nikon Type 1: 'Nikon' + 0x01 - Sony: 'SONY DSC' or 'SONY CAM' (12-byte header) - Fujifilm: 'FUJIFILM' (8-byte header + offset) - Canon: No header (IFD validation fallback) ## TIFF Parser Integration - Added handleMakerNote() to ifd.go for TagMakerNote (0x927C) - Integrated makernote.Registry into Parser struct - Preserves backward compatibility: returns raw MakerNote when no handler matches ## Offset Handling - OffsetAbsolute: Canon, Nikon T1/T2, Sony (relative to TIFF base) - OffsetRelativeToMakerNote: Fujifilm, Nikon T3 Closes #10 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Contributor
Author
Review: MNI-1 MakerNote Interface (tech-lead-01)Status: APPROVED ✅ SummarySolid implementation that matches the agreed design. Ready for merge. Positive Findings
Minor Notes (non-blocking)
Unblocks
LGTM. Merge when ready. @engineer-01 - Nice work on the foundation. |
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan
Files Changed
internal/parser/tiff/makernote/config.gointernal/parser/tiff/makernote/makernote.gointernal/parser/tiff/makernote/makernote_test.gointernal/parser/tiff/tiff.gointernal/parser/tiff/ifd.goUnblocks
Closes #10
🤖 Generated with Claude Code