Repository navigation
Conversation
Nikoh77
force-pushed
the
feat/pentax-pixel-shift
branch
from
October 31, 2026 17:56
8ee6c76 to
21d2ade
Compare
A Pentax Pixel Shift RAW holds four Bayer shots, one photosite apart. NegPy decoded only the first shot and gave no warning. - Find a multi-shot RAW from its TIFF structure: count the CFA images of the same size. The Pentax makernote Quality tag (7) tells a Pixel Shift from an in-camera HDR. - Open each shot with shot_select set before open_file. LibRaw selects the shot at open, so rawpy.imread always gives the first shot. - Combine the shots with the mapping of RawTherapee (rtengine/pixelshift.cc), without motion correction. Each pixel gets one R, two G and one B sample, scaled as LibRaw scales one shot on each path. The result is the same as RawTherapee 5.13 within 16-bit rounding (max 0.7/65535 on a PEF and a DNG). - Compare the two green samples of each pixel with a noise model, and warn when the shots do not agree (motion, vibration, light change). - Add a Shots choice to the Raw Decode card: Pixel Shift (Auto) or one shot. The choice is part of the source token and of each cache key. - Keep the combined counts in an in-memory cache, one entry per file. - Linear Output, Trichrome triplets, HDR brackets and stitches use the combined source. A composite warns for each of its parts. - Bump BOUNDS_VERSION and THUMBNAIL_RENDER_VERSION: a Pixel Shift file now measures and renders from the combined source. Refs marcinz606#1499 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The GC can clear a slider before Qt deletes its children. A visible child then sends Hide to the event filter, which read self.label or self.slider, raised inside a Qt virtual, and PyQt6 aborted. c72d66f avoids it in the Crosstalk test; this fixes the widget. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Nikoh77
force-pushed
the
feat/pentax-pixel-shift
branch
from
October 31, 2026 18:12
21d2ade to
b2d2077
Compare
This branch has not been deployed
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.
Closes #1499
Pentax Pixel Shift PEF/DNG files hold four Bayer shots, one pixel apart. NegPy only read the first one, without saying so. This PR combines them, so every pixel gets measured R, G and B and no demosaic runs.
What's in it
shot_selectset beforeopen_file.rawpy.imreadsets it after the open, so it always gives shot 1.rtengine/pixelshift.cc, without motion correction. On a PEF and a DNG it matches RawTherapee 5.13 within 16-bit rounding (max diff 0.7/65535). Credit to the RawTherapee folks.BOUNDS_VERSIONandTHUMBNAIL_RENDER_VERSION. Bounds saved before this came from shot 1. On my test scenes they differ from the combined source by 0.4 to 2.2% of the span, per channel, so a slight cast.Second commit: a
sliders.pyfix. The GC can clear aCompactSliderbefore Qt deletes its children; a visible child then sendsHideto the event filter, which raises inside a Qt virtual, and PyQt6 aborts. c72d66f avoids it in the Crosstalk test, this fixes the widget. Twogetattrs plus a test.Numbers (K-3 III, my machine)
Tested
make allis green (13,323 tests).demosaic: Pixel Shiftin the description).Open questions
negpy_coreif you prefer.BOUNDS_VERSIONbump re-meters everyone's frames once and flags roll baselines. The alternative was a per-edit marker for edits saved before this, but it needed about eight touch points (undo, work prints, diptych halves, Merge to TIFF, paste...). The bump looked simpler and follows your rule. Your call.🤖 Generated with Claude Code