CaptureOne AppleScript for copying adjustments to processed images

When you process a RAW image from Capture One on Apple using “Process With Topaz Photo AI” the resulting photo loses adjustments including the lens profile. This is an AppleScript to copy all adjustments, including lens correcting and crop, to the image processed by Topaz. Put it in the scripts folder. To run it, select the original and the processed image with the original as the primary selection.

use AppleScript version "2.4" -- Yosemite (10.10) or later
use scripting additions

-- based on script by Zdeněk Macháček 
-- copy adjustments including crop, lens correction and flip/rotation
tell application "Capture One 23"
	set tmpVar to primary variant
	set selVarCount to count of selected variants
	set selVarList to selected variants
	-- check if more variants are selected
	if selVarCount > 1 then
		-- copy adjustements of selected photo to clipboard
		copy adjustments tmpVar
		-- repeat for all photos in selection
		repeat with v from 1 to selVarCount
			set workingVariant to get (item v of selVarList)
			if workingVariant ≠ tmpVar then
				-- reset adjustments of working variant (for not duplicationg layers if there are some)				
				reset adjustments workingVariant
				-- paste adjustments of source variant
				apply adjustments workingVariant
				-- set the last layer as active	
				tell workingVariant
					set current layer to last layer
					--  set crop, lens correstion, rotation and flip based on source variant else based on stored original crop						
					set lens correction to lens correction of tmpVar
					set flip of adjustments to flip of adjustments of tmpVar
					set rotation of adjustments to rotation of adjustments of tmpVar
					-- crop should be after rotation to work correctly
					set crop to crop of tmpVar
				end tell
			end if
		end repeat
		-- move to the next variant in selection		
		change selection current document to next variant
	end if
end tell

Thanks for reporting this. I made a task for my team to update the Capture One plugin.

We can’t use the AppleScript in our plugin, we will use the Capture One plugin instructions to do this.

Let me know if you have any questions on this topic.