• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

All Corrections get overwritten when calling applyDevelopPreset with a plugin preset in LRC 9.3

Community Beginner ,
Jun 27, 2020 Jun 27, 2020

Copy link to clipboard

Copied

Calling `applyDevelopPreset` on a preset created within the plugin with even just the edit of adjusting exposure will cause all "Corrections" (Local adjustment Brushes, Radial Filters and Graduated Filters) to be reset. All other image settings remain unchanged.

 

Is there a way to prevent this from happening?

 

 

local preset = LrApplication.addDevelopPresetForPlugin(_PLUGIN, editText, edits)
photo:applyDevelopPreset(preset, _PLUGIN)

 

 

 Currently, as a workaround I'm having to do this to keep existing Corrections applied between edits:

 

 

edits.PaintBasedCorrections = photoSettings.PaintBasedCorrections
edits.CircularGradientBasedCorrections = photoSettings.CircularGradientBasedCorrections
edits.GradientBasedCorrections = photoSettings.GradientBasedCorrections

 

 

 This did not happen in Lightroom Classic 9.2, and all other settings seem to be unaffected.

TOPICS
SDK

Views

403

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Jun 27, 2020 Jun 27, 2020

Got it, I didn't test for local adjustments. I observe the same behavior.

 

I recommend you post a bug report in the official Adobe feedback forum, where Adobe wants all bug reports and feature suggestions: 
https://feedback.photoshop.com/photoshop_family/categories/photoshop_family_photoshop_lightroom

 

(Safari users, uncheck the option Safari > Preferences > Privacy > Prevent Cross-Site Tracking or use Chrome or Firefox.)

Be sure to include the first ten lines of the menu command Help > System I

...

Votes

Translate

Translate
LEGEND ,
Jun 27, 2020 Jun 27, 2020

Copy link to clipboard

Copied

I just did a quick test and photo:applyDevelopPreset() appears to be working correctly.  It sounds like you might be defining a preset that sets all the develop settings, not just Exposure2012.  You can quickly check that by clicking Preferences > Presets > Show All Other Lightroom Presets, going to the subfolder "Plugin Develop Presets/<your plugin>", and editing the .lrtemplate file corresponding to the preset.  It should only contain one develop setting, e.g.

s = {
	id = "9D7E33D2-DC8C-41C3-AF26-BC2D2EE4F9AE",
	internalName = "Preset1",
	title = "Preset1",
	type = "Develop",
	value = {
		Exposure2012 = 4,
	},
	version = 0,
}

 

[Use the blue reply button under the first post to ensure replies sort properly.]

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 27, 2020 Jun 27, 2020

Copy link to clipboard

Copied

Hi John,

Thanks for your response! I just checked and here's the preset the plugin is generating.

 

s = {
	id = "35819D5A-5461-4BDA-802C-0A2AF7D3E4AC",
	internalName = "Exposure  +0.3  1.8",
	title = "Exposure  +0.3  1.8",
	type = "Develop",
	value = {
		Exposure2012 = 1.8,
	},
	version = 0,
}

 

Applying this preset to an image that has any "Corrections" on it (local adjustment brush, radial or graduated filter), these corrections are removed. All other image settings are not affected. (I realise my original post might not have been clear about this, I've updated it to reflect this point)

 

I should point out this only happens in LRC 9.3. This didn't happen in LRC 9.2 and prior.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jun 27, 2020 Jun 27, 2020

Copy link to clipboard

Copied

Got it, I didn't test for local adjustments. I observe the same behavior.

 

I recommend you post a bug report in the official Adobe feedback forum, where Adobe wants all bug reports and feature suggestions: 
https://feedback.photoshop.com/photoshop_family/categories/photoshop_family_photoshop_lightroom

 

(Safari users, uncheck the option Safari > Preferences > Privacy > Prevent Cross-Site Tracking or use Chrome or Firefox.)

Be sure to include the first ten lines of the menu command Help > System Info.  Package up a complete, self-contained test plugin with as few lines as possible into a .zip that can be unzipped, installed, and run, which demonstrates the problem.  Unfortunately, support for the SDK is absolutely minimal for the past many years, and unless you lead Adobe by the hand, it's very unlikely they'll even file an internal bug report.

 

A workaround is to use the undocumented photo:applyDevelopSettings() to apply the desired settings.

 

[Use the blue reply button under the first post to ensure replies sort properly.]

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 27, 2020 Jun 27, 2020

Copy link to clipboard

Copied

Awesome! Thanks for testing it out and the advice. I'll raise a bug report as suggested.

 

Also thanks for the `photo:applyDevelopSettings() ` tip! That'll come handy. 😁

 

Appreciate your help!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jun 27, 2020 Jun 27, 2020

Copy link to clipboard

Copied

Hi John!

 

For completeness of this thread, and for anyone reading in the future, I thought I'd add that I followed your advice and raised a ticket in the Adobe feedback forum:

https://feedback.photoshop.com/photoshop_family/topics/calling-applydeveloppreset-with-a-plugin-pres...

 

An Adobe rep reached out to me, and I've built them a minimal demo plugin showing the issue:

https://github.com/cajames/lightroom-preset-error-demo

 

Hoping this helps them fix the issue. In the meantime I've switched to using `photo:applyDevelopSettings()` as it's more representative of what I'm trying to do in the plugin.

 

Thanks once again for your guidance! 😊

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jun 28, 2020 Jun 28, 2020

Copy link to clipboard

Copied

Great. If the status of that bug report (at the top) changes from Problem to Acknowledged, that means they've filed an internal bug report. Sometimes they then change the status to In Progress to mean they're actually working on it, but sometimes they forget to do that (and many Acknowledged bugs remain deprioritized and unfixed).

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Oct 22, 2020 Oct 22, 2020

Copy link to clipboard

Copied

LATEST

This bug was fixed in LR 10.0:

https://feedback.photoshop.com/conversations/lightroom-classic/lightroom-classic-93-calling-applydev...

 

[Use the blue reply button under the first post to ensure replies sort properly.]

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines