vinny_the_hack Posted December 8, 2016 Share Posted December 8, 2016 (edited) I'm a casual, but longtime user. I don't know why I waited this long to try to get an answer for this, but anyway...whenever I select something using the magic wand, it always comes with a little extra around the entire selection. It's almost like a narrow beach around an island. It's quite often white, and when I paste this into another image, i always have to use the eraser tool to remove this very noticeable "ring" around the selection. It is very time consuming. Am I doing it wrong? Is there an option to prevent this? Is there a way to avoid this problem? Is thee an easier way to remove this "beach"? Thanks for any guidance you can provide. Edited December 8, 2016 by vinny_the_hack Quote Link to comment Share on other sites More sharing options...
toe_head2001 Posted December 8, 2016 Share Posted December 8, 2016 Can you show us a screenshot of this behavior? Quote My Gallery | My Plugin Pack Layman's Guide to CodeLab Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 8, 2016 Author Share Posted December 8, 2016 (edited) My bad. I didn't mean the selection tool. I meant the magic wand. I just used it to select the white background of an image, then inverted the selection (to pick up what I want), and then copied it and pasted it into a black image (for contrast). Notice all the white around the image that got picked up from the background from the original image. Edited December 8, 2016 by vinny_the_hack Quote Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted December 8, 2016 Share Posted December 8, 2016 The ring around the image is composed of pixels which are not the background color. Most likely they are intermediate colors to assist with anti-aliasing. The technique you're using will often result in these artifacts. Best solution? Paste the graphic into a transparent layer and run AA's Assistant on the layer. AA's Assistant can be found in this plugin pack.. 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 Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted December 8, 2016 Share Posted December 8, 2016 The other option I often use to remove solid black or white backgrounds is AlphaSpace. You can simply run this plugin over the unedited source image. 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 Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 (edited) I have confirmed that the "ring" around the object is indeed picked up from the background of the original image. I tested this by colouring it red before performing the same test I did above and here's the result. It's a little difficult to see in this one, but there are red pixels around the entire image. I installed the plugins, but I'm at a loss as to how to use AA's Assistant. I tried various values and I saw no effect whatsoever on the image. Could you please list step-by-step what I should do? Thanks for your help. Edited December 9, 2016 by vinny_the_hack Quote Link to comment Share on other sites More sharing options...
toe_head2001 Posted December 9, 2016 Share Posted December 9, 2016 I just used 'AA's Assistant' on its default values, and it worked fine. 0) Start with large resolution --> https://s3-ap-southeast-1.amazonaws.com/cdn1.zepo.in/upload/product_photos/base/0/33/93/original1.2186538.1.jpg 1) Use the Magic Wand to select the region(s) you wish to remove 2) Delete the selection 3) Run the 'AA's Assistant' plugin. Quote My Gallery | My Plugin Pack Layman's Guide to CodeLab Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted December 9, 2016 Share Posted December 9, 2016 Just to clarify: AA's Assistant works on groups of pixels which border transparent areas. It is the opaque/transparent border where the cleaning up actually happens. So, you need to cut the image from the background, deselect the area, then run the plugin on the whole layer. 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 Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 I get no discernible effect from running AA's Assistant. I even used your high resolution image to start with. Result is same (white border). Have you verified that you have leftover white pixels bordering the image after removing the white background and before running AA's Assistant? I'm wondering if Paint.Net isn't behaving differently on your machine and mine. Thanks again for your continued help. Quote Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted December 9, 2016 Share Posted December 9, 2016 Please post the image so we can confirm what you're explaining. 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 Link to comment Share on other sites More sharing options...
Pixey Posted December 9, 2016 Share Posted December 9, 2016 I had to use the AA's Assistant 2 to 3 times to get rid of the white halo. 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. Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 14 hours ago, Ego Eram Reputo said: Please post the image so we can confirm what you're explaining. It's exactly like the one I posted above in my second post. Quote Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 3 hours ago, Pixey said: I had to use the AA's Assistant 2 to 3 times to get rid of the white halo. I just ran it five times and it didn't make a lick of difference. Quote Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 Why is there a halo at all? Isn't this a bug? Shouldn't everything up to the black border of the image be removed after selecting and cutting the white background? Just sayin'. Quote Link to comment Share on other sites More sharing options...
Eli Posted December 9, 2016 Share Posted December 9, 2016 No, it is not a bug. That is how it works. You can change the TOLERANCE to determine how much you want to select. Zoom and look at the black borders you talk about. They are not BLACK. That is why you have a halo. Quote Link to comment Share on other sites More sharing options...
Pixey Posted December 9, 2016 Share Posted December 9, 2016 As Eli says: 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. Link to comment Share on other sites More sharing options...
MJW Posted December 9, 2016 Share Posted December 9, 2016 3 hours ago, vinny_the_hack said: Why is there a halo at all? Isn't this a bug? Shouldn't everything up to the black border of the image be removed after selecting and cutting the white background? Just sayin'. In order to make the edge look smooth and not jagged and stair-steppy, the pixels on the edge are a blend of the background and foreground colors. So if you have a white foreground and a black background, the edge pixels are various shades of gray. The problem is the edge pixels are partly background and partly foreground, so if you remove them, you remove some of the foreground, while if you leave them, you leave part of the background. One method is to: Use the Color Picker to set the Primary Color to the background color. Use the Magic Wand to select the background with a low tolerance so the edge pixels aren't selected. Add a new layer and make it the active layer. Fill the selection. (The foreground area of the added layer will be transparent; the background filled with a fixed color.) Make the new layer invisible. (This isn't necessary, but I think it makes it easier.) Activate the original layer. (This actually -- and unfortunately, IMHO! -- happens automatically when the new layer is made invisible). Erase the selection. You should have a foreground area surrounded by a halo. Activate the added layer. Apply a Gaussian Blur with a Radius around 5. (The best radius somewhat depends on the image.) Use the Magic Wand to select the background area of the added layer. Adjust the Tolerance to move the selection inside the edge. It will move smoothly. Activate the original layer. Run the Color Clearer plugin. Click the reset button on Color to Make Transparent to set the color to the current Primary Color. The Color Clearer will "remove" the background color from the edge pixels. Delete the added layer. Make sure at all times that the correct layer is the active layer. It's easy to have the wrong layer active. EDIT: Modified method. EDIT: Fixed error in specifying which area of the new layer will be filled with color and which will be transparent. Quote Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 There is NO tolerance level that will make a clean cut/selection of all the white background. It goes from leaving a halo to selecting the entire image. Here's something interesting. I started with a layer of black. I added a second layer and drew a black circle. I dumped a bucket of white at 30% tolerance into the background. I selected the white background at 30% tolerance, and cut it out. There's a halo left around the black circle. Shouldn't paint-canning at 30% tolerance and then removing at 30% tolerance cancel each other out, leaving no white behind? Another interesting thing: I then used AA's Assistant and it removed the halo, unlike my previous experience with the original image. I have an idea for a further experiment. I'll be back with the results soon. And thank-you all for your help. Quote Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 I posted the above just as MJW posted a reply. Quote Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 Thanks for that great explanation, MJW. Quote Link to comment Share on other sites More sharing options...
vinny_the_hack Posted December 9, 2016 Author Share Posted December 9, 2016 (edited) Okay, I tried running AA's Assistant again on the original image (after cutting out the background), and after several iterations, the halo disappeared. What I found was that the border around the little man was not fully black, and so it appeared to have a halo around it when I had tried it the first time. I confirmed this by selecting the black colour from the colour chart, and drew a line over it. Don't know if that made sense to anyone, but suffice to say, I'm happy, and thanks to all for your help. Edited December 9, 2016 by vinny_the_hack Quote Link to comment Share on other sites More sharing options...
MJW Posted December 9, 2016 Share Posted December 9, 2016 I edit my original comment with a better approach. You might give it a try. Quote Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted December 10, 2016 Share Posted December 10, 2016 5 hours ago, vinny_the_hack said: What I found was that the border around the little man was not fully black, On 9/12/2016 at 10:19 AM, Ego Eram Reputo said: The ring around the image is composed of pixels which are not the background color. Most likely they are intermediate colors to assist with anti-aliasing. 7 hours ago, vinny_the_hack said: It's exactly like the one I posted above in my second post. Pwned! See what happens when I speed read? 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 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.