Popular Post null54 Posted April 21, 2018 Popular Post Posted April 21, 2018 Content aware filling replaces the contents of the selection with pixels that are the closest match in the areas outside the selection. This allows parts of an image to be removed and blended with the background. This plugin is based on the GIMP Resynthesizer plugin. Compatibility: 5.1+ Menu location: Effects > Selection > Content Aware Fill Download: ContentAwareFill.zip Source Code: https://github.com/0xC0000054/pdn-content-aware-fill 11 7 Quote Plugin Pack | PSFilterPdn | Content Aware Fill | G'MIC | Paint Shop Pro Filetype | RAW Filetype | WebP Filetype The small increase in performance you get coding in C++ over C# is hardly enough to offset the headache of coding in the C++ language. ~BoltBait
Ego Eram Reputo Posted April 22, 2018 Posted April 22, 2018 OMG! ? This is AWESOME!! I couldn't believe how good this is. To try it out, I cut a circle out of a reasonably complex scene. The two different replacements were created with different settings. Both are very believable! Thanks so much @null54. This definitely goes into my "essentials" toolbox. Quote ebook: Mastering Paint.NET | resources: Plugin Index | Stereogram Tut | proud supporter of Codelab plugins: EER's Plugin Pack | Planetoid | StickMan | WhichSymbol+ | Dr Scott's Markup Renderer | CSV Filetype | dwarf horde plugins: Plugin Browser | ShapeMaker
Pixey Posted April 22, 2018 Posted April 22, 2018 Excellent Plugin @null54 - Thank you. I played with it and discovered that if one increases the Tolerance slightly, there will be no 'ring' left behind Quote How I made Jennifer & Halle in Paint.net My Gallery | My Deviant Art "Rescuing one animal may not change the world, but for that animal their world is changed forever!" anon.
Seerose Posted April 22, 2018 Posted April 22, 2018 @null54! You did excellent on these. Thank you for the sharing. Quote Live as if you were to die tomorrow. Learn as if you were to live forever. Gandhi
lynxster4 Posted April 22, 2018 Posted April 22, 2018 I just tried this on one of my shapes pictures. With the proper settings, I couldn't even tell where I made the selection! Excellent! Thanks, @null54 1 Quote My Art Gallery | My Shape Packs | ShapeMaker Mini Tut | Air Bubble Stained Glass Chrome Text with Reflections | Porcelain Text w/ Variegated Coloring | Realistic Knit PatternOpalescent Stained Glass | Frosted Snowman Cookie | Leather Texture | Plastic Text | Silk Embroidery Visit my Personal Website "Never, ever lose your sense of humor - you'll live longer"
Roly Poly Goblinoli Posted April 23, 2018 Posted April 23, 2018 (edited) I managed to get an error that crashes PDN. Seems to occur for selections that include pixels along the bottom of the image; I didn't test other sides. It's an index out-of-range error. Details: Spoiler File: C:\Program Files\paint.net\Effects\ContentAwareFill.dll Name: ContentAwareFill.ContentAwareFillEffect Version: 1.0.0.0 Author: null54 Copyright: Copyright © 2018 Nicholas Hayes (aka null54) Website: https://www.getpaint.net/redirect/plugins.html Full error message: PaintDotNet.WorkerThreadException: Worker thread threw an exception ---> System.IndexOutOfRangeException: Index was outside the bounds of the array. at ContentAwareFill.Resynthesizer.PrepareNeighbors(Point position) at ContentAwareFill.Resynthesizer.Synthesize(Int32 pass, Func`1 abortCallback) at ContentAwareFill.Resynthesizer.ContentAwareFill(Func`1 abortCallback) at ContentAwareFill.ContentAwareFillEffect.OnSetRenderInfo(EffectConfigToken parameters, RenderArgs dstArgs, RenderArgs srcArgs) at PaintDotNet.Effects.BackgroundEffectRenderer.ThreadFunction() in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 227 --- End of inner exception stack trace --- at PaintDotNet.Effects.BackgroundEffectRenderer.DrainExceptions() in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 418 at PaintDotNet.Menus.EffectMenuBase.DoEffect(Effect effect, EffectConfigToken token, PdnRegion selectedRegion, PdnRegion regionToRender, IRenderer`1 clipMaskRenderer, Surface originalSurface, Exception& exception) in D:\src\pdn\src\PaintDotNet\Menus\EffectMenuBase.cs:line 1556 Edited April 23, 2018 by Joshua Lamusga Quote
null54 Posted April 23, 2018 Author Posted April 23, 2018 2 hours ago, Joshua Lamusga said: I managed to get an error that crashes PDN. Seems to occur for selections that include pixels along the bottom of the image; I didn't test other sides. It's an index out-of-range error. That crash and the dialog tab order have been fixed in version 1.1. 1 Quote Plugin Pack | PSFilterPdn | Content Aware Fill | G'MIC | Paint Shop Pro Filetype | RAW Filetype | WebP Filetype The small increase in performance you get coding in C++ over C# is hardly enough to offset the headache of coding in the C++ language. ~BoltBait
Roly Poly Goblinoli Posted April 23, 2018 Posted April 23, 2018 Interesting. Did you release v1.1 in response, or did you upload it within the last two hours? I suspect if your answer is no, then I was served an older version. Quote
null54 Posted April 23, 2018 Author Posted April 23, 2018 12 minutes ago, Joshua Lamusga said: Did you release v1.1 in response, or did you upload it within the last two hours? It was released in response. Quote Plugin Pack | PSFilterPdn | Content Aware Fill | G'MIC | Paint Shop Pro Filetype | RAW Filetype | WebP Filetype The small increase in performance you get coding in C++ over C# is hardly enough to offset the headache of coding in the C++ language. ~BoltBait
Roly Poly Goblinoli Posted April 23, 2018 Posted April 23, 2018 Good to know the report was useful Quote
null54 Posted April 27, 2018 Author Posted April 27, 2018 Fixed the Paint.NET Dark theme support and improved performance. File version updated to 1.2.0.0. 1 Quote Plugin Pack | PSFilterPdn | Content Aware Fill | G'MIC | Paint Shop Pro Filetype | RAW Filetype | WebP Filetype The small increase in performance you get coding in C++ over C# is hardly enough to offset the headache of coding in the C++ language. ~BoltBait
Zevel Posted April 27, 2018 Posted April 27, 2018 Can you move the menu entry from "Photo" to "Selection"? Quote
null54 Posted April 27, 2018 Author Posted April 27, 2018 40 minutes ago, Zevel said: Can you move the menu entry from "Photo" to "Selection"? Done. Changed the submenu from "Photo" to "Selection" and updated the PluginSupportInfo to point to the forum thread. File version updated to 1.2.1.0. 4 1 Quote Plugin Pack | PSFilterPdn | Content Aware Fill | G'MIC | Paint Shop Pro Filetype | RAW Filetype | WebP Filetype The small increase in performance you get coding in C++ over C# is hardly enough to offset the headache of coding in the C++ language. ~BoltBait
Seerose Posted April 27, 2018 Posted April 27, 2018 ? @null54! Thanks a lot for the new version. Quote Live as if you were to die tomorrow. Learn as if you were to live forever. Gandhi
alexo Posted April 27, 2018 Posted April 27, 2018 Thank you null54, I've been waiting for a long time for something like this! Quote
BoltBait Posted April 27, 2018 Posted April 27, 2018 5 hours ago, Zevel said: Can you move the menu entry from "Photo" to "Selection"? I don't actually think this is a good idea. All plugins work on selections. But, the plugins in the selection submenu change their behavior based on the shape of the selection.* This plugin doesn't do that. I'd put it back in the photo menu as I think it is really designed for repairing photos. *For example, outline selection draws an outline in the shape of the selection. 1 Quote Download: BoltBait's Plugin Pack | CodeLab | and a Free Computer Dominos Game
MJW Posted April 28, 2018 Posted April 28, 2018 I think either Photo or Selection makes sense. This plugin depends on the selection in a way most plugins don't. In most plugins, the same thing occurs in the selected area as would occur if there were no selections at all. The selection merely restricts the region that's affected. In this plugin, the results are determined by the pixels on the selection boundary. 1 Quote
alexo Posted April 28, 2018 Posted April 28, 2018 (edited) I agree with MJW on this one. The plugin requires a selection, and I don't see much of a difference between it's positioning and the "feather selection" one. My vote is for selection. Edited April 28, 2018 by alexo Quote
null54 Posted April 28, 2018 Author Posted April 28, 2018 I originally placed the plugin on the Photo menu because that was the location of BoltBait's Seam Carving plugin, which was the closest existing "content aware" plugin. The purpose of this plugin is to replace the contents of a selection based on the pixels outside the selection. Which as @Ego Eram Reputo's example above illustrates is useful for more than just photographs. 13 hours ago, BoltBait said: All plugins work on selections. But as @MJW has noted most plugins do not require a selection to operate, and there are not many other categories to make that requirement clear to users. Quote Plugin Pack | PSFilterPdn | Content Aware Fill | G'MIC | Paint Shop Pro Filetype | RAW Filetype | WebP Filetype The small increase in performance you get coding in C++ over C# is hardly enough to offset the headache of coding in the C++ language. ~BoltBait
alexo Posted April 28, 2018 Posted April 28, 2018 19 minutes ago, null54 said: @Ego Eram Reputo@MJWI originally placed the plugin on the Photo menu because that was the location of BoltBait's Seam Carving plugin, which was the closest existing "content aware" plugin. Which ironically does not work with selections. Quote
Syn Posted June 3, 2018 Posted June 3, 2018 I recently switched over from PS to Paint.Net and I've been trying to get this content aware plugin to work. I'm not expecting the exact same results as PS, but I can't even come close... I've been trying to remove the woman in the attached image as a test for the plugin and it's been horrendous results. Any tips? I'm using default plugin settings when when the selection > content aware window pops up. Quote
Ego Eram Reputo Posted June 4, 2018 Posted June 4, 2018 1. Don't trust the defaults. The tiniest change in the sample size can have a big effect on the outcome, as does the selection itself. The first try I had with your image used a sample size of 15. Redoing the selection + 15 looked awful. I had better results with 67. 2. Don't remove the object first. Take our time and select around it with care. Then run the plugin directly on the selected lady. Your object in the image is taller than it is wide, so I'd select the refill from the sides. This will take the refill pixels from more horizontal offsets than vertical. I tend to use Inwards fill. It just seems to be better at object removal. So, try something like these settings: In saying that, I don't think you're going to get a seamless result out of the box. You're going to have to do some manual fixing. 2 Quote ebook: Mastering Paint.NET | resources: Plugin Index | Stereogram Tut | proud supporter of Codelab plugins: EER's Plugin Pack | Planetoid | StickMan | WhichSymbol+ | Dr Scott's Markup Renderer | CSV Filetype | dwarf horde plugins: Plugin Browser | ShapeMaker
AndrewDavid Posted June 4, 2018 Posted June 4, 2018 Hi @Syn Welcome to the Forum. A fairly new plugin - but I believe I am getting the hang of it. THe first step is to remove the area you need filled. Then work with small areas to fill with the content you are looking for. Just 15 minutes and I managed to provide this quick example. More time spent will produce a better result. I should mention a directional blur was added to blend the colors better after the content aware fill. I am sure this will get you pointed in the right direction. Any questions just ask. @Ego Eram Reputo is much faster than I ? 2 Quote
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.