Skip to content

Snapshots should always be applied from a source image to a target - #22076

Open
lefth wants to merge 1 commit into
darktable-org:masterfrom
lefth:fix-snapshot-wrong-image
Open

Snapshots should always be applied from a source image to a target#22076
lefth wants to merge 1 commit into
darktable-org:masterfrom
lefth:fix-snapshot-wrong-image

Conversation

@lefth

@lefth lefth commented Aug 30, 2026

Copy link
Copy Markdown
Contributor

This prevents snapshots from being applied in an unloaded image, which causes loss of image history if undo is not applied.

This tends to happen and go unnoticed when working with duplicates. This fixes #22018.

This prevents snapshots from being applied in an unloaded image, which
causes loss of image history if undo is not applied.

This tends to happen and go unnoticed with duplicates.
@TurboGit

Copy link
Copy Markdown
Member

Indeed, the issue is fixed but I'm wondering if we just want to disable restoring a snapshot to another image. The restore has been designed to go back to an old edit for the same image.

To be discussed, but applying a snapshot to another image seems awkward to me.

@lefth

lefth commented Aug 31, 2026

Copy link
Copy Markdown
Contributor Author

@TurboGit It would be awkward if done by accident, but on purpose (and with Duplicate Manager) it's a straightforward way of persisting snapshots to disk, or to get snapshots into a state where they can be viewed in lighttable.

Here's an example workflow: I've been reading that the proper way to give a warm glow to a scene is not to let some warmth seep in through color calibration, but to calibrate the scene to entirely neutral and add warmth through cbrgb. Without getting into the arguments on either side, I'd like to test it.

  • white balance it neutrally
  • save a snapshot with a descriptive name
  • apply a tint
  • save a snapshot with a descriptive name
  • ask if I can do better; create a duplicate
  • load the snapshot with neutral illuminant
  • apply a creative color calibration

You can do all this without applying changes onto duplicates, but (with multiple versions) it would take longer and introduce confusion about which image I need to load to restore a snapshot. Plus I try not to alter my history stack after I have an image I like, so the workflow would involve cloning with the clone being an original and using the first image to load snapshots then create other duplicates.

I also temporarily apply snapshots just to see module parameters, though this goes against my rule of not casually altering history. (If the parameters are complex, I might even load a snapshot, save a module as temporary preset, undo, then apply the preset.) In short, snapshots are a general tool.

Should we restrict applying snapshots to non-duplicates? I can think of one use case: a snapshot is like a named history stack. I could apply my "artistic color calibration" or "warmed with cbrgb" snapshots to another image in the same set to see how they work.

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

Successfully merging this pull request may close these issues.

Snapshot previews correctly but restores onto the wrong duplicate

2 participants