Lens Flare Removal and Reconstruction
Organizations: Meta Reality Labs Research, Redmond, USA · Meta Reality Labs, New York, USA · TU Munich, MCML, Munich, Germany
Abstract
The presence of lens flares in images can significantly reduce the quality of downstream application results for tasks such as 3D scene reconstruction. This is because lens flares are a property of the camera imaging system, and not a part of the underlying scene being modeled. There are previous methods that tackle the removal of small flares focused around a light source. However, existing methods struggle with large flares, such as those that fill the entire image. In this work, we compile a novel dataset for large-flare removal, combining publicly available real-world data with a procedural generation pipeline. We fine-tune a diffusion-based model on our dataset to remove complex, large lens flares. On the other hand, lens flares remain effective artistic tools, widely used in the media. While there are ways to simulate 2D flares, representing and reconstructing lens flares consistently across multiple views has not yet been explored. To achieve this, we introduce a flare representation model that leverages the symmetry of lens flares about the camera's principal point. We propose a computational pipeline to jointly optimize this flare model and a Gaussian splatting model (3DGS). This enables the decomposition of a 3D scene into lens flares and the scene itself, using our flare-removal model. Because the reconstructed flare is explicit and re-renderable, it can be edited and transferred to novel images and new 3D scenes. We evaluate removal on an established benchmark and a new one for large reflective flares, quantify the flare/scene decomposition directly, and show that the pipeline is robust to errors in automatic light-source localization.
Figures & tables
Scattering'', show a hallway ceiling light with radial streaks (labeled Streaks'') and a bright purple-white light with a hazy vertical beam (labeled Glare''). The right photo, labeled Reflective'', shows a bright light on a wooden deck railing at night with a distinct circular reflective ghost artifact nearby.| Stock flares | Procedural | Physically-based | Ours | |
|---|---|---|---|---|
| No lens/optical model needed | ✓ | ✓ | ✗ | ✓ |
| No precise 3D light geometry needed d | ✓ | ✓ | ✗ | ✓ |
| Viewpoint-correct optical appearance a | ✗ | ✗ | ✓ | ✓ |
| Reproduces the target scene’s own captured flare signature | ✗ | ✗ | ✗ | ✓ |
| 3D-consistent transfer of a captured flare to new scenes c | ✗ | ✗ | ✗ | ✓ |
| Real-time rendering b | ✓ | ✓ | ✓ | ✓ |
Same light, different lenses'', show a tree-trunk scene and a chair scene each with a different lens flare pattern despite similar lighting. The third photo, under the label Different lights, same lens'', shows a distinct starburst-shaped light source flare.Input'', 3DGS'', and ``Def-3DGS''. The Input photo shows a small blue circular flare artifact beside the light, marked with a green circle. In the 3DGS and Def-3DGS reconstructions, this same location is marked with a red circle, and the blue flare artifact is missing or much fainter, showing that both 3D reconstruction methods fail to reproduce it.Canonical Flare Gaussians in 1D'': a row of pink ellipses of varying size and orientation arranged along a single axis, with scalar mean mu, fed into a Deformations'' box conditioned on principal point p and light position l. Second, Flare Gaussians in 2D'': the deformed ellipses arranged along a diagonal dashed line inside a square, connecting a black dot labeled Principal point p'' to a yellow dot labeled Corrected light l plus delta-l''. Third, Flare Gaussians in 3D'': a camera icon projects the same line through an image plane onto a near-plane offset in front of a scene panel, placing the flare Gaussians as standard 3DGS primitives along the optical axis between the camera and the light source.Ground Truth'', Render'', Scene'', and Flare''. Ground Truth and Render show near-identical photographs of the cabinet with a faint blue-green flare glow entering from the left edge. The Scene image shows the cabinet without any flare, appearing cleaner and slightly darker on the left. The Flare image is a mostly dark frame showing only the isolated bluish-green flare glow, with the light source itself outside the visible frame.Full image real flares'', show a soft glowing oval shape filling most of a dark frame and a vertical greenish-blue streak with a bright spot at its base. The third, under Ring flares'', shows a procedurally generated green ring-shaped flare with opacity fading from the ring toward the center of the image.| Ablations on Ours-wGlare | |||||||||||
| Benchmark | Metric | LightsOut | FR | Flare7K++ | ACL-FR | FlareX | Ours-wGlare | Ours | wo | wo | wo |
| ( Tsai et al., 2025 ) | ( Wu et al., 2021 ) | ( Dai et al., 2023a ) | ( Zhou et al., 2025 ) | ( Lishen et al., 2025 ) | light | enc FT | VFX | ||||
| Flare7k++ | PSNR | 16.04 | 24.49 | 26.42 | 24.48 | 25.26 | 26.68 | 25.76 | 25.84 | 25.64 | 26.96 |
| SSIM | 0.6954 | 0.8797 | 0.8926 | 0.8689 | 0.8870 | 0.8993 | 0.8925 | 0.8831 | 0.8696 | 0.8850 | |
| LPIPS | 0.2686 | 0.0980 | 0.0908 | 0.0925 | 0.0934 | 0.0777 | 0.0848 | 0.0850 | 0.0856 | 0.0767 | |
| vfx_dataset | PSNR | 13.04 | 21.04 | 21.37 | 20.20 | 24.17 | 25.93 | 27.06 | 25.03 | 23.75 | 24.77 |
| Scene | Vanilla 3DGS | w BilateralGrid | w Flare7k++ | w FR | w ACL-FR | w FlareX | w Ours-wGlare | w Ours | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | |
| amp | 12.25 | 0.518 | 0.599 | 14.40 | 0.637 | 0.413 | 17.24 | 0.714 | 0.435 | 18.50 | 0.689 | 0.450 | 16.75 | 0.669 | 0.455 | 17.03 | 0.681 | 0.440 | 19.84 | 0.743 | 0.379 | 21.06 | 0.751 | 0.377 |
| billboard | 18.93 | 0.645 | 0.327 | 19.59 | 0.707 | 0.273 | 19.16 | 0.656 | 0.345 | 19.84 | 0.686 | 0.319 | 18.61 | 0.668 | 0.336 | 19.43 | 0.680 | 0.301 | 20.67 | 0.740 | 0.256 | 20.47 | 0.705 | 0.286 |
| dog | 21.77 | 0.869 | 0.185 | 21.74 | 0.903 | 0.146 | 27.22 | 0.931 | 0.118 | 25.88 | 0.917 | 0.149 | 25.01 | 0.888 | 0.173 | 25.44 | 0.916 | 0.135 | 28.42 | 0.945 | 0.090 | 28.48 | 0.943 | 0.089 |
| guitar | 20.07 | 0.835 | 0.255 | 20.03 | 0.866 | 0.242 | 24.53 | 0.903 | 0.171 | 25.65 | 0.905 | 0.173 | 22.64 | 0.870 | 0.214 | 24.97 | 0.900 | 0.176 | 26.21 | 0.911 | 0.151 | 25.72 | 0.910 | 0.162 |
| plant | 20.36 | 0.836 | 0.226 | 19.05 | 0.820 | 0.266 | 23.83 | 0.872 | 0.192 | 23.40 | 0.848 | 0.218 | 22.53 | 0.848 | 0.215 | 21.32 | 0.815 | 0.258 | 21.06 | 0.831 | 0.252 | 23.91 | 0.874 | 0.186 |
wo enc FT' (VAE encoder not fine-tuned, showing color shifts), wo light' (light source added back after removal, appearing less accurate), `wo VFX data' (large flares only partially removed), the full model with lens glare, and the full model without lens glare. The two rightmost results in each row most closely match a flare-free, correctly colored scene.| Flare - Decomposed | |||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Design alternatives | Component ablations | ||||||||||||||||||||
| Scene | Ours 2D | Ours sup in-flare | Ours unsup | Ours wo | Ours wo G-SAM2 | Ours wo | Ours | ||||||||||||||
| PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | PSNR | SSIM | LPIPS | |
| hat | 31.14 | 0.850 | 0.299 | 28.01 | 0.659 | 0.358 | 30.29 | 0.720 | 0.301 | 37.22 | 0.873 | 0.271 | 35.75 | 0.862 | 0.286 | 36.93 | 0.867 | 0.268 | 37.24 | 0.876 | 0.273 |
| park | 24.93 | 0.508 | 0.355 | 18.79 | 0.666 | 0.307 | 20.90 | 0.704 | 0.285 | 32.24 | 0.809 | 0.269 | 32.07 | 0.785 | 0.276 | 32.14 | 0.839 | 0.244 | 32.36 | 0.820 | 0.258 |
| outtrunk | 27.96 | 0.855 | 0.291 | 16.87 | 0.446 | 0.516 | 19.78 | 0.511 | 0.427 | 33.03 | 0.876 | 0.294 | 30.52 | 0.867 | 0.303 | 32.59 | 0.871 | 0.294 | 33.22 | 0.877 | 0.293 |
Ours 2D', in-flare', unsup', wo delta-l', wo G-SAM2', wo delta-f', and Ours', plus a reference column. The 3DGS column shows scenes with reflective flares either missing or baked in as artifacts, while later columns progressively better isolate and reconstruct distinct flare shapes near each scene's light source(s), with the final Ours' column most closely matching the reference decomposition into scene and flare components.Flare'' render shows a glowing ring with a dark hollow center instead of the expected ring shape. The Scene'', Render'', and GT'' (ground truth) images look nearly identical, showing the tree trunk with a bright light and, in the ground truth, a faint colorful ring artifact near the blue secondary flare that is missing from the reconstructed render.Appendix figures & tables3 assets
Supplementary material from the paper’s appendix.
Appendix
Training images'' / Given'') shows several photos of a scene with visible lens flares. The middle row (Training images'' / \ourswo) shows the same photos with flares removed by our model. The bottom row (Test images'' / ``Given'') shows held-out photos of the scene without flares, used as evaluation ground truth.Grounded-SAM2 light masks: PR curve (box-threshold sweep)''. Two lines, with every other point labeled by its GroundingDINO confidence threshold (the sweep runs from 0.05 to 0.80), plot precision (pixel) on the y-axis against recall (pixel) on the x-axis. The blue Raw Grounded-SAM2'' line peaks near precision 0.43 at low recall and falls steadily to near 0 precision at recall 1.0, with a star marking its best-F1 point around precision 0.25, recall 0.40. The green ``Refined pipeline'' line stays well above the blue line across the range, peaking near precision 0.85 at low recall and remaining around 0.35–0.5 precision at high recall, with a star marking its best-F1 point around precision 0.51, recall 0.93.