Torstein Posted October 14, 2023 Share Posted October 14, 2023 I often want to add some blur to backgrounds in my photos. I normally make a copy of the layer, make a mask of the motive and add live layer with blur, gaussian or to blur the background. But when I add plenty of blur AP seems like it also considers the masked area and I get a "halo / gloria" effect around the subject. A work around is to create a new pixel layer where the foreground is totally erased, but it makes the process more cumbersome and it takes more time. I don't know if this is unavoidable, user error or a bug... Quote Link to comment Share on other sites More sharing options...
NotMyFault Posted October 15, 2023 Share Posted October 15, 2023 If you already have a mask for the motive, why not duplicate it and invert for use as background mask? You may record the process as macro to do all automatically (just need background, mask layer) Quote Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080 LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5 iPad Air Gen 5 (2022) A2589 Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps. Link to comment Share on other sites More sharing options...
NotMyFault Posted October 15, 2023 Share Posted October 15, 2023 10 hours ago, Torstein said: I don't know if this is unavoidable, user error or a bug... It is missing „automagically“ for such tasks. Newer IPhones have depth detection and deliver a height map. This can be used for Computational blur. Some competing apps try to create AI based depth map Formant image. Quote Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080 LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5 iPad Air Gen 5 (2022) A2589 Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps. Link to comment Share on other sites More sharing options...
Torstein Posted October 15, 2023 Author Share Posted October 15, 2023 5 hours ago, NotMyFault said: If you already have a mask for the motive, why not duplicate it and invert for use as background mask? You may record the process as macro to do all automatically (just need background, mask layer) Thats exactly what I do. I replicate the mask, invert it and use for the background mask. But when I add the blur it's as the blur function also consider pixels that are masked. My work around is to make a new pixel background layer from the masked background layer, but where the masked area is 100 % transparent. That seems to work fine, but it's extra steps with work that should not be necessary. Quote Link to comment Share on other sites More sharing options...
thomaso Posted October 15, 2023 Share Posted October 15, 2023 16 hours ago, Torstein said: But when I add plenty of blur AP seems like it also considers the masked area and I get a "halo / gloria" effect around the subject. I think you can't avoid a "halo / gloria" by this simulation of depth of field since a blur effect always increases a blurred detail, e.g. the edge (diameter) of this apple: Quote macOS 10.14.6 | MacBookPro Retina 15" | Eizo 27" | Affinity V1 Link to comment Share on other sites More sharing options...
lepr Posted October 15, 2023 Share Posted October 15, 2023 blurred background (AP1).afphoto Quote Link to comment Share on other sites More sharing options...
- S - Posted October 15, 2023 Share Posted October 15, 2023 Did you tick "Preserve Alpha" in the Gaussian Blur live filter? Quote Link to comment Share on other sites More sharing options...
NotMyFault Posted October 15, 2023 Share Posted October 15, 2023 @lepr With a trick you can avoid inpainting, and create a fully non-destructive version. the issue when using a mask and the inverted mask: it does not add to 100%, and creates a gap whenever you have semi-transparent areas. you can heal this with help of a levels adjustment, to boost alpha back to 100%. blurred background ohne inpaint.afphoto lepr 1 Quote Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080 LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5 iPad Air Gen 5 (2022) A2589 Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps. Link to comment Share on other sites More sharing options...
lepr Posted October 15, 2023 Share Posted October 15, 2023 8 minutes ago, NotMyFault said: you can heal this with help of a levels adjustment, to boost alpha back to 100%. excellent Quote Link to comment Share on other sites More sharing options...
thomaso Posted October 15, 2023 Share Posted October 15, 2023 8 hours ago, lepr said: (original inpainted) Note, it seems the OP wants to avoid such extra pixel editing: On 10/15/2023 at 12:46 AM, Torstein said: A work around is to create a new pixel layer where the foreground is totally erased, but it makes the process more cumbersome and it takes more time. @NotMyFault, I can't open your V2 document, … could you post a screenshot of your (unfolded) layers panel, please? 7 hours ago, NotMyFault said: the issue when using a mask and the inverted mask: it does not add to 100%, and creates a gap whenever you have semi-transparent areas. you can heal this with help of a levels adjustment, to boost alpha back to 100%. I am curious what I am missing in this solution: Quote macOS 10.14.6 | MacBookPro Retina 15" | Eizo 27" | Affinity V1 Link to comment Share on other sites More sharing options...
lepr Posted October 16, 2023 Share Posted October 16, 2023 4 hours ago, thomaso said: Note, it seems the OP wants to avoid such extra pixel editing: They should hire an assistant to click on Edit > Inpaint. PaulEC 1 Quote Link to comment Share on other sites More sharing options...
thomaso Posted October 16, 2023 Share Posted October 16, 2023 23 minutes ago, lepr said: click on Edit > Inpaint Ah, I hadn't noticed yet inpainting as menu command. It gets the worm of the apple … ;•) Quote macOS 10.14.6 | MacBookPro Retina 15" | Eizo 27" | Affinity V1 Link to comment Share on other sites More sharing options...
NotMyFault Posted October 16, 2023 Share Posted October 16, 2023 5 hours ago, thomaso said: @NotMyFault, I can't open your V2 document, … could you post a screenshot of your (unfolded) layers panel, please? Sure. you we’re using vector shapes as mask, combined with layer fx. when using bitmap masks, layer fx does not work. see the effects of the filter/adjustment layers in the video: the minimize filter removes the remaining reddish colored edge to avoid color spill the blur filter (without protect alpha) blurs everything (including canvas edges). See that some semi-transparent areas will show at all edges the levels adjustment will restore full alpha. Colors are not impacted / undamaged. a small negative side effect: if you have contrasting parallel lines like the darker lines on the wooden table, these will get distorted similar to a pinch effect. Depends on the actual image of this gets visible / distracting. Inpainting is able to recreate or remove these lines, whereas blur samples colors in a circular way. RPReplay_Final1697433368.mov blurred background (AP1) nmf.afphoto thomaso 1 Quote Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080 LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5 iPad Air Gen 5 (2022) A2589 Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps. Link to comment Share on other sites More sharing options...
NotMyFault Posted October 16, 2023 Share Posted October 16, 2023 To tackle the circular effect of gaussian blur, it helps to copy the levels adjustment. Fur ultimate results, add a motion blur. This will repeat the parallel lines and keep them parallel. i mention these tricks here as they can help in other situations: to prepare an area for a inpainting step, to get usable colors and patterns. blurred background (AP1) nmf v2.afphoto Quote Mac mini M1 A2348 | Windows 10 - AMD Ryzen 9 5900x - 32 GB RAM - Nvidia GTX 1080 LG34WK950U-W, calibrated to DCI-P3 with LG Calibration Studio / Spider 5 iPad Air Gen 5 (2022) A2589 Special interest into procedural texture filter, edit alpha channel, RGB/16 and RGB/32 color formats, stacking, finding root causes for misbehaving files, finding creative solutions for unsolvable tasks, finding bugs in Apps. Link to comment Share on other sites More sharing options...
lepr Posted October 16, 2023 Share Posted October 16, 2023 5 hours ago, thomaso said: Ah, I hadn't noticed yet inpainting as menu command. It gets the worm of the apple … ;•) You can see in the AD document I provided that I didn't have that problem. Quote Link to comment Share on other sites More sharing options...
thomaso Posted October 16, 2023 Share Posted October 16, 2023 21 minutes ago, lepr said: You can see in the AD document I provided that I didn't have that problem. You misunderstood me, I was positive surprised about the menu / 1-click option while the screenshot was rather a coincidentally funny result in this case. Of cause the result depends on the selection / the position of its edges. Thanks! lepr 1 Quote macOS 10.14.6 | MacBookPro Retina 15" | Eizo 27" | Affinity V1 Link to comment Share on other sites More sharing options...
lepr Posted October 16, 2023 Share Posted October 16, 2023 3 hours ago, thomaso said: You misunderstood me I'm quite good at that LOL NotMyFault 1 Quote Link to comment Share on other sites More sharing options...
lepr Posted October 16, 2023 Share Posted October 16, 2023 We've all been overcomplicating the solutions. Here's an AP1 document with four simple alternatives which give the same result: blurred background four variants (AP1).afphoto thomaso 1 Quote Link to comment Share on other sites More sharing options...
Torstein Posted October 16, 2023 Author Share Posted October 16, 2023 Thank you all for suggestions and ideas. Anyway, I must have done something stupid, because I now get everything to work as expected! Can it have had something with the preserve alfa selection? Quote Link to comment Share on other sites More sharing options...
lepr Posted October 16, 2023 Share Posted October 16, 2023 1 hour ago, Torstein said: Can it have had something with the preserve alfa selection? That and the order of operations is crucial. See my most recent example with four variations. In all four, Preserve Alpha is enabled and blurring is happening after masking. Quote Link to comment Share on other sites More sharing options...
Torstein Posted October 16, 2023 Author Share Posted October 16, 2023 Maybee I'm not so stupid.... Some more experimentation and I have found that the order you arrange Mask and Blur layers is important! (That feels like a bug too me!) These two orders of the layers don't give the same result! To my surprise, the last sample with Mask below Blur works fine, while the one with the Mask above the Blur do not! I would have expected the other way around... You can see the effect in the small samples. Quote Link to comment Share on other sites More sharing options...
Torstein Posted October 16, 2023 Author Share Posted October 16, 2023 59 minutes ago, lepr said: That and the order of operations is crucial. See my most recent example with four variations. In all four, Preserve Alpha is enabled and blurring is happening after masking. Now I do understand what you are saying.... Quote Link to comment Share on other sites More sharing options...
lepr Posted October 16, 2023 Share Posted October 16, 2023 19 minutes ago, Torstein said: Some more experimentation and I have found that the order you arrange Mask and Blur layers is important! Yes, that's what I told you. 19 minutes ago, Torstein said: (That feels like a bug too me!) I disagree. 19 minutes ago, Torstein said: To my surprise, the last sample with Mask below Blur works fine, while the one with the Mask above the Blur do not! Yes, I said the blurring with Preserve Alpha enabled must happen after the masking. 15 minutes ago, Torstein said: Now I do understand what you are saying.... Cool Quote Link to comment Share on other sites More sharing options...
Torstein Posted October 16, 2023 Author Share Posted October 16, 2023 1 hour ago, lepr said: Yes, that's what I told you. I disagree. Yes, I said the blurring with Preserve Alpha enabled must happen after the masking. Cool It works the way I expect with the Mask layer at bottom, as long as I don't select preserve alpha in the blur layer. With preserve alpha it gives the photo "aura" treatment in any way I order the Mask layer before or after the Blur layer(s). Quote Link to comment Share on other sites More sharing options...
lepr Posted October 17, 2023 Share Posted October 17, 2023 5 hours ago, Torstein said: It works the way I expect with the Mask layer at bottom, as long as I don't select preserve alpha in the blur layer. With preserve alpha it gives the photo "aura" treatment in any way I order the Mask layer before or after the Blur layer(s). No, Preserve Alpha prevents the "aura" effect. It should, logically, do that and it actually has worked correctly every time I have enabled it over the years. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.