Skip to main content
Participating Frequently
July 2, 2026
Question

Mask information in LRC. Where is it stored? Does the SDK allow me to read and write to it?

  • July 2, 2026
  • 3 replies
  • 51 views

I am writing a Python program that analyzes my images and gives me not only feedback about the images but editing tips. Currently it will write a new XMP file based on its findings. What is not included in the XMP file are any masking edits. Where are masking edits and their associated data stored, and are they in a place that I can access programmatically?

3 replies

jrendantAuthor
Participating Frequently
July 4, 2026

I am creating an AI agent that will help me analyze and develop my images and help me become better at my craft. The following is an example of what the agent does locally on my PC. I am looking to automate it's response to the masks as the XMP file already works just fine. This program is still in the very early stages of development but the XMP portion of it is working. This particular run of the program does not generate the XMP as I have not selected that option. I am still making sure that AI is not hallucinating by going through each and every step and creating the image using its input which is really amazing. Please let me know what you think. Would it be useful to other people?

Image Analysis Report

Generated: 2026-07-03 15:00:56 | ImageAnalyzer v0.10 RECOVERED.11.18 PANORAMA SUBJECT GUARD

Image

Image file

D:\analyzer data\landscapes\ChicagoSkyLine.tif

Prompt file

F:\Python_Working_Programs\Image_Analyzer\RIPL-PROMPTv3.txt

AI model

nemotron3:33b

Analysis source

rendered image file

Analysis basis

Rendered image pixels. This reflects edits already baked into the TIFF/JPEG/PNG input.

EXIF Facts Used

Camera make: Hasselblad
Camera model: Hasselblad H4D
Lens: HC 80
Focal length: 80.0 mm
Aperture: 19.0
Shutter speed: 0.6
ISO: 400
Exposure program: Aperture-priority AE
Metering mode: Center-weighted average
White balance: As Shot
Capture date: 2012:03:25 19:23:43

Image Analysis

PART 1 – IMAGE CRITIQUE

Compositional strengths & weaknesses

  • Strengths: The image presents a classic panoramic city‑skyline view with the water in the foreground providing a clear horizontal anchor. The skyline is evenly spaced, allowing each tower to occupy its own visual “slice” of the frame.
  • Weaknesses: Because the horizon line sits near the middle of the frame and the sky occupies roughly half the image, the composition feels balanced but not particularly dynamic; there is little foreground interest beyond a thin strip of water that does not lead the eye into the scene.

Visual hierarchy & eye flow

  • The tallest skyscraper (the Willis Tower) acts as an implicit focal point on the left‑center, drawing the viewer’s gaze. However, the lack of a strong foreground element or leading line prevents the eye from moving smoothly from front to back; the eye tends to linger on the middle band of buildings before returning to the water.

Tonal hierarchy

  • The image is dominated by mid‑tones with a relatively narrow dynamic range. Highlights in the sky are muted, and shadows under the buildings are deep but not fully black, resulting in a “flat” tonal distribution that reduces perceived depth.

Light quality & tonal separation

  • Light appears to be diffused twilight (the EXIF capture time 19:23 suggests early evening). The sky is overcast with soft, even illumination, which minimizes strong directional shadows and consequently limits the sense of three‑dimensional form on the buildings.

Subject clarity & emotional impact

  • Architectural detail is present but not crisp; the overall mood is subdued and atmospheric rather than dramatic. The image conveys a quiet urban evening but lacks a compelling emotional hook because the tonal contrast is limited.

Technical flaws & artistic weaknesses

  • Flatness: The primary issue is low contrast and insufficient separation between foreground water, middle‑ground skyline, and background sky.
  • Noise: ISO 400 at 0.6 s shutter speed introduces a subtle grain that, while acceptable for a night‑time cityscape, does not add texture that enhances depth.
  • Sharpness: The image appears slightly soft across the entire frame; there is no evident local sharpening on key architectural edges.

Potential award‑winning qualities

  • The panoramic format and natural lighting give it a solid foundation for fine‑art cityscape work, but without stronger tonal separation and foreground interest it would be unlikely to stand out in a competition that rewards depth and visual hierarchy.

What weakens the image artistically

  1. Insufficient foreground definition – the water strip is too thin to act as a leading element.
  2. Limited dynamic range – highlights are not bright enough, shadows are not deep enough, causing a “muddy” look.
  3. Weak light directionality – diffuse twilight eliminates strong shadows that would sculpt the buildings.

What could have been improved in‑camera

  • Use a longer focal length (e.g., 100 mm) to compress perspective and bring foreground water forward, or shoot from a slightly elevated position to include more of the shoreline as a leading element.
  • Shoot at a lower ISO (e.g., 200) with a tripod to allow a longer exposure that would deepen shadows while preserving highlight detail.
  • Consider a graduated neutral density filter to balance the bright sky against the darker cityscape, enhancing tonal separation.

PART 2 – EDITING DIRECTION

Preserve: Highlight recovery (the soft glow in the sky), subtle tonal transitions, natural color separation, realistic texture on concrete and glass surfaces, controlled darkness, reflected light from water, micro‑contrast on geological/structural surfaces.

Avoid: HDR look, artificial glow, oversaturation, crushed blacks, oversharpening, unrealistic color grading.

Style goals: Restrained, atmospheric, geological (focus on structure), immersive, natural, tonally controlled.

PART 3 – LIGHTROOM CLASSIC WORKFLOW

Global Adjustments
Slider Recommended Setting
Exposure +0.15 ev (slight lift to brighten overall scene)
Contrast +12 (adds gentle separation without harshness)
Highlights –30 (protects sky detail)
Shadows +25 (opens shadow detail under buildings)
Whites +10 (maintains a clean but not blown‑out sky)
Blacks –10 (deepens shadows just enough for depth)
Texture +8 (enhances surface detail on concrete/glass)
Clarity +6 (adds micro‑contrast to mid‑tones)
Dehaze 0 (no need; sky is already clear)
Vibrance +5 (subtle boost to keep colors natural)
Saturation 0 (keep saturation restrained)
Tone Curve
  • Mapping strategy: Slight lift in the shadows, modest roll‑off in highlights.
  • Point values (approximate):

```
Tone Curve:

  • Black point: Input 0 / Output 0
  • Shadows: Input 30 / Output 28
  • Darks: Input 55 / Output 53
  • Midtones: Input 128 / Output 132
  • Lights: Input 200 / Output 207
  • Highlights: Input 245 / Output 242
  • White point: Input 255 / Output 255

```

This creates a gentle “S” shape that adds depth while preserving the soft twilight ambience.

Color Grading (Lightroom Classic)
Area Hue Saturation Luminance
Shadows Cool blue‑teal (≈210 °) +5 –5
Midtones Neutral (no shift) 0 0
Highlights Warm amber‑gold (≈30 °) +8 +5

These restrained shifts reinforce a natural evening atmosphere without overt stylization.

Masking Workflow
  1. Water / Reflections – Linear Gradient from bottom edge upward, covering the water band:
  • Feather: 70
  • Exposure: +0.10 (brighten water slightly)
  • Shadows: +15 (recover detail in darker water tones)
  • Texture: +10 (enhance ripples)
  1. Canyon walls / Skyline – Radial Gradient centered on the tallest skyscraper, extending beyond its edges to include surrounding towers:
  • Feather: 85
  • Invert: Yes (apply to background)
  • Exposure: –0.12 (darken sky slightly for separation)
  • Highlights: –15 (protect sky detail)
  • Shadows: +10 (open shadowed façade)
  • Texture: +8 (bring out building surface texture)
  1. Foreground water edge – Brush with size 60‑70, feather 65, flow 12, density 90, Auto Mask On:
  • Target area: thin strip where water meets shoreline.
  • Exposure: +0.15 (enhance reflective surface)
  • Highlights: –10 (prevent blown‑out highlights on water)
  • Shadows: +8 (recover detail in darker water)
  • Texture: +12 (adds natural water texture)
  1. Atmospheric depth – Radial Gradient with center placed over the distant skyline, feather 90, invert No:
  • Dehaze: +5 (subtle atmospheric contrast)
  • Saturation: –3 (keep colors muted)
Local Adjustments
  • Dodging & Burning: Use a soft brush (size ~80, feather 70) to gently brighten the tops of the tallest towers (+0.10 exposure) and deepen shadows beneath overhangs (‑0.15 exposure). This reinforces three‑dimensional form without creating harsh contrast.
  • Texture Enhancement: Apply a modest +6 Clarity locally on building façades using a brush (size 40, feather 50) to accentuate surface detail while keeping the overall image smooth.
  • Micro‑contrast Control: Increase Texture (+8) globally; use a low‑strength Brush (+3 Clarity) on selected windows to add sparkle without oversharpening.
Detail Panel
Setting Recommendation
Sharpening – Amount 45 (moderate)
Radius 1.0 px
Detail 25
Masking 70 (protects smooth sky, sharpens edges of buildings)
Luminance Noise Reduction 30 (reduce ISO grain while preserving edge detail)
Color Noise Reduction 25 (maintains natural color integrity)
Crop & Transform
  • Crop Ratio: 2.39:1 (cinematic widescreen) to emphasize the panoramic sweep and give more breathing room to the water foreground.
  • Framing corrections: Slight upward tilt (‑0.5°) to level the horizon; ensure the skyline sits just above the lower third line, reinforcing depth.
  • Perspective: No major distortion detected; minor perspective correction (verticals within 1°) may be applied if needed.

PART 4 – FINAL OUTPUT

Final artistic edit direction
The edited image should retain its natural twilight mood while gaining a clear sense of three‑dimensional space: foreground water with subtle texture, mid‑ground skyline defined by gentle contrast and tonal separation, and background sky softened yet distinct. The overall palette remains muted, with cool blues in the shadows and warm amber highlights that echo the city lights.

Lightroom‑compatible XMP sidecar workflow
(Not applicable – this report analyzes an already‑rendered image; no sidecar file is required.)

Final export recommendations

  • Format: 16‑bit TIFF (maximum tonal depth)
  • Resolution: highest practical pixel dimensions of the source (e.g., 7500 × 2500 px for a typical 4 : 1 panorama)
  • DPI: 300 dpi for print‑ready output
  • Color Space: ProPhoto RGB (preserves the widest gamut for fine‑art printing)

ADDITIONAL REPORT REQUIREMENTS

Tone Curve: (see “Tone Curve” section above – specific Input/Output values provided).

Camera / Lens / Exposure Data Rule: All camera data are taken directly from the EXIF block supplied:

```
Camera make: Hasselblad
Camera model: Hasselblad H4D
Lens: HC 80
Focal length: 80.0 mm
Aperture: f/19.0
Shutter speed: 0.6 s
ISO: 400
Exposure program: Aperture‑priority AE
Metering mode: Center‑weighted average
White balance: As Shot
Capture date: 2012:03:25 19:23:43
```

Masking Requirements: All mask recommendations include practical starting settings as detailed in the “Masking Workflow” and “Local Adjustments” sections.

Editing Direction

The review is focused on restoring or evaluating dimensionality after a real three-dimensional scene has been flattened into a two-dimensional print or screen image. The goal is tonal separation, controlled detail, restrained color, believable texture, and visual depth without forcing HDR, artificial glow, crushed blacks, or excessive saturation.

Output guardrails are applied to prevent over-bright whites, lifted black anchors, excessive saturation, aggressive vibrance, harsh texture, or heavy dehaze from pushing the edit outside Jim Rendant's restrained fine-art landscape style.

Suggested Masking Workflow

These are manual Lightroom Classic or Photoshop masking suggestions. They are not automatically written as Lightroom mask objects.

Mask 1: Primary subject separation

Target

main subject or strongest visual anchor

Lightroom mask type

Subject, Object Select, or Brush

Purpose

pull the primary subject forward without globally brightening the whole image

Why it helps

small local lift and texture increase improve depth while preserving restraint

Suggested Settings

exposure +0.10
shadows +6
texture +8
clarity +3
saturation +0
feather +70
flow +50
density +80

Mask 2: Background restraint

Target

background or visually competing outer areas

Lightroom mask type

Background, Brush, Linear Gradient, or Luminance Range

Purpose

push secondary areas back so the image has stronger spatial layering

Why it helps

reducing contrast and saturation in competing areas helps the eye stay on the intended subject plane

Suggested Settings

exposure -0.10
highlights -10
texture -5
clarity -3
saturation -4
feather +85
density +75

Mask 3: Bright distraction control

Target

small bright highlights that pull attention away from the main visual path

Lightroom mask type

Brush or Luminance Range

Purpose

hold highlight structure and prevent flat bright spots from breaking depth

Why it helps

controlled highlights keep the print from feeling spotty or two-dimensional

Suggested Settings

exposure -0.15
highlights -20
whites -10
clarity -2
feather +65
flow +45
density +75

Validated Lightroom XMP Settings Applied

No Lightroom XMP settings were applied.
This was a report-only analysis of the rendered image.

Edit Comparison

EDIT COMPARISON
Rendered file inspected: D:\analyzer data\landscapes\ChicagoSkyLine.tif

Embedded Lightroom XMP develop settings were found in this rendered file. These values describe the already-baked/current edit metadata; Image Analyzer did not write a new XMP sidecar for this TIFF/JPEG/PNG run.

Setting Embedded Rendered Edit
------------------------ ------------------------
White Balance As Shot
Exposure +0.00
Contrast +0
Highlights +0
Shadows +0
Whites +0
Blacks +0
Texture +0
Clarity +10
Dehaze +0
Vibrance +0
Saturation +0
Sharpening +0
Noise Reduction +0
Color Noise Reduction +0
Lens Profile Enable +0
Profile Embedded
CG Shadow Hue +0
CG Shadow Sat +0
CG Shadow Lum +0
CG Midtone Hue +0
CG Midtone Sat +0
CG Midtone Lum +0
CG Highlight Hue +0
CG Highlight Sat +0
CG Highlight Lum +0
CG Blending +50
CG Balance +0
CG Global Hue +0
CG Global Sat +0
CG Global Lum +0
Curve 32 Output +32
Curve 128 Output +128
Curve 224 Output +224

Use this as the current-edit baseline when judging the critique. If these embedded settings are missing or stale, export the TIFF from Lightroom with metadata included.

Artist Style Guide

ARTIST STYLE GUIDE
No Artist Style Guide update was created because no XMP comparison was available.

Lightroom Classic Instructions

This report was generated from an already-rendered TIFF/JPEG/PNG image.
No Lightroom sidecar XMP was created.

Use this report as a critique, print-readiness review, and refinement guide.
If you want to revise the image, return to Lightroom or Photoshop and use the analysis and masking suggestions as guidance.

Output Files

Report: D:\analyzer data\landscapes\ChicagoSkyLine_image_analyzer_run_v0_10_recovered_11_18_panorama_subject_guard_20260703_145911\html_report.html
No Lightroom XMP was created because this was a report-only analysis of an already-rendered image file.

Rollback Instructions

No XMP rollback is needed because no new XMP file was created in report-only mode.

johnrellis
Legend
July 4, 2026

[View this post in your web browser. It contains formatting and images that don't appear in email.]

 

Please let me know what you think. Would it be useful to other people?

 

It looks intriguing, especially if the user can replay the verbal description with the actual appearance on screen!

jrendantAuthor
Participating Frequently
July 5, 2026

They can manually input them but still figuring out the masking aspect. The goal is to automatically update the .xmp which works for raw files but because tiff files use the embedded slider settings exif is used to crerate aa new file_DEX with the updates since tiff file cannot user the LRC Metadata→ Read from file option. It will start to build a style file based on your original edits and start using your style after about 100 images that are needed to build your style from. (still working on that)

jrendantAuthor
Participating Frequently
July 3, 2026

thank you for the information. I have something new to investigate.

 

johnrellis
Legend
July 2, 2026

Let’s tease apart what you mean by “masking edits”.

 

The SDK provides access to the the list of applied masks, each mask’s name, the develop settings applied by the mask (e.g. the slider values).  You can get access via the SDK call photo:getDevelopSettings(). These are also stored in the XMP settings stored in the .xmp sidecar (or in the photo file itself, for non-raws).

 

The pixel representations of masks that aren’t purely parametric (e.g. Sky) are stored in the catalog file <catalog>.lrcat-data, which is an open-source Rocksdb database file optimized for large binary objects.  How LR uses that database file is not publicly documented, and I’m not aware of anyone who has attempted to reverse engineer it.

 

These pixel masks are also stored in the .acr sidecars.

 

Years ago, when LR used to store pixel masks in the main catalog, someone discovered that the individual pixel masks were represented in TIFF format. That may or may not be true in the current representation.

 

The Extract Masks command of the Copy Settings plugin extracts all the masks of a photo as grey-scale virtual copies, suitable for use as layer masks in Photoshop. Extract a couple of masks and examine them in Develop, and you can see how it works.