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

dcraw: add Panasonic DC-GH6 #7020

Merged
merged 1 commit into from
Jun 1, 2024
Merged

Conversation

sgotti
Copy link
Contributor

@sgotti sgotti commented Mar 30, 2024

dcraw: add Panasonic DC-GH6 to adobe_coeffs

Depends on v8 decoder provided by #7018

Tested images

  • Tested normal images.
  • Tested in-camera pixelshift high resolution images

@Lawrence37 Lawrence37 linked an issue May 11, 2024 that may be closed by this pull request
Comment on lines 2543 to 2545
"ranges": {
"white": 65535
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The decoder already has the white level for this camera.
white levels: R:65535 G1:65535 B:65535 G2:65535 (provided by dcraw)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right.

If useful this isn't directly provided by any metadata but calculated from tiff_bps (16 in this case):

maximum = ((uint64_t)1 << tiff_bps) - 1; // use uint64_t to avoid overflow if tiff_bps == 32

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similar to the edit to my comment in the other Panasonic camconst PR, Libraw has the color matrix and white level. We should consider copying the new Libraw constants for all cameras into dcraw.cc.
https://github.com/LibRaw/LibRaw/blob/158e635e5e80a95dfa402b0a79a7167922c1d4ec/src/tables/colordata.cpp#L1387-L1388

@sgotti
Copy link
Contributor Author

sgotti commented May 22, 2024

@Lawrence37 Updated the PR to update the dcraw adobe_coeffs table instead of a camconst entry.
Note that the black level is set to 0, while in libraw is set to -2048 because the logic has changed a lot in libraw. If we set it to 2048 here we'll get a black level of 4096 since it's summed to the already provided single channel blacks levels (cblack) with value 2048 read from metadata.

@sgotti sgotti changed the title camconst: add Panasonic DC-GH6 dcraw: add Panasonic DC-GH6 May 22, 2024
@Lawrence37 Lawrence37 merged commit 5a7b0e4 into Beep6581:dev Jun 1, 2024
8 checks passed
@Lawrence37 Lawrence37 added the scope: calibration Camera calibration (camconst.json) label Jun 1, 2024
@Lawrence37 Lawrence37 added this to the v5.11 milestone Jun 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
scope: calibration Camera calibration (camconst.json)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Panasonic Lumix DC GH6 RW2 raw format support
2 participants