acoustichead Posted December 6, 2015 Share Posted December 6, 2015 I'm new here so sorry if I'm posting in the wrong forum section, I didn't see any section for plugins. What I'm looking for is a plugin that essentially will allow me to copy an image such as a texture I drew and be able to fill it in to fit a selected area. Now to be clear I am not talking about tiling it, I want it the texture to conform to the shape of the selected area. In a sense a fill plugin that will allow me to flood fill my clipboard into the shape of my selected area. Does this already exist? If not can it please?Thank you. Quote Link to comment Share on other sites More sharing options...
Eli Posted December 6, 2015 Share Posted December 6, 2015 (edited) You can use Boltbait's Fill from file or Fill from clipboard effect. Just make your selection and run it. Edited December 6, 2015 by Eli Quote Link to comment Share on other sites More sharing options...
acoustichead Posted December 6, 2015 Author Share Posted December 6, 2015 (edited) You can use Boltbai's Fill from file or Fill from clipboard effect. Just make your selection and run it. I've tried using that it does not do what I'm talking about. That tiles the clipboard I don't want it to tile. I want it to paste into the selected area and conform into the shape of what I selected, similar to how the paintbucket simple conforms to the area you put the color in. Edited December 6, 2015 by acoustichead Quote Link to comment Share on other sites More sharing options...
Eli Posted December 6, 2015 Share Posted December 6, 2015 (edited) I am not sure what you want to achieve. Can you post an example of what you want to achieve? Perhaps using the Alpha mask effect can help you. Edited December 6, 2015 by Eli Quote Link to comment Share on other sites More sharing options...
acoustichead Posted December 6, 2015 Author Share Posted December 6, 2015 (edited) I am not sure what you want to achieve. Can you post an example of what you want to achieve? Perhaps using the Alpha mask effect can help you. Ok say I have this empty area in a sorta odd shape and I had this texture i drew on the left. I want to fill that exact texture into that transparent area and have it take on the shape it is. Now to do this I would have to put it into the shape and drag my select tool across it by each level of the shape pixel by pixel increments and drag it over to re-size it to shape. I am not looking for something that will simply turn it into a circle or square I am looking to be able to copy a texture or pattern and easily paste it to conform and bend into the shape on the right in a flood fill like manner. The result here would be this. Edited December 6, 2015 by acoustichead Quote Link to comment Share on other sites More sharing options...
Eli Posted December 6, 2015 Share Posted December 6, 2015 I do not know of an effect that will fill a shape inside another shape and follow the contours of the last one. However, if all you want to do is to fill the shape with some gradients, you can use TR's Contour filler and then soften it with Gaussian blur. Quote Link to comment Share on other sites More sharing options...
acoustichead Posted December 6, 2015 Author Share Posted December 6, 2015 I do not know of an effect that will fill a shape inside another shape and follow the contours of the last one. However, if all you want to do is to fill the shape with some gradients, you can use TR's Contour filler and then soften it with Gaussian blur. Not what I was looking for but thanks for the help nonetheless. . I really needed it to be for specific clipboard textures but oh well. Quote Link to comment Share on other sites More sharing options...
BoltBait Posted December 6, 2015 Share Posted December 6, 2015 Try this plugin: http://forums.getpaint.net/index.php?/topic/14278- It is really old. And, the images are gone from the thread. But, my (admittedly faulty) memory says it may be what you need. Quote Download: BoltBait's Plugin Pack | CodeLab | and a Free Computer Dominos Game Link to comment Share on other sites More sharing options...
MJW Posted December 6, 2015 Share Posted December 6, 2015 (edited) I don't think that plugin does anything more than superimpose one image over another. As I interpret acoustichead's request, it's for a plugin that spacially distorts the image to fit into the selection. I'm not sure the goal is well-defined enough to implement as a plugin for anything but trivial cases, and perhaps not even for that. It appears to me that in the example given, the pattern is compressed in the X direction to fit the selection, and would look different if it were compressed in the Y direction instead. EDIT: I can see a simple algorithm for mapping a rectangular region to a convex region. For any point in the convex region, compute the rectangle's X coordinate based on the proportion of the distance between the convex region's left and right boundaries at the Y value, and the Y coordinate based on the proportion of the distance between the upper and lower boundaries at the X value. In other words, bilinear interpolation based on the convex region's current X row and Y column. This could be extended to map a convex region to another convex region by essentially first mapping the source convex region to a rectangle, using the same idea. Edited December 6, 2015 by MJW Quote Link to comment Share on other sites More sharing options...
Red ochre Posted December 6, 2015 Share Posted December 6, 2015 Midora made something along those lines ... I can't find the thread but do have the codelab code. I've just named it "MidorasStretchObjectSideToSides". (All his work, not mine).Could be relevant if adapted? //Midora's stretch object to edges void Render(Surface dst, Surface src, Rectangle rect) { float CenterX = src.Width / 2f; // for each row for (int y = rect.Top; y < rect.Bottom; y++) { int x; // Determine the number of transparent pixels on the left side // Determine the scale factor which is (opaque pixels / max pixels) for (x = 0; x < CenterX; x++) { if (src[x,y].A == 255) break; } float lScale = (CenterX - x) / CenterX; // Same for the right side for (x = src.Width - 1; x >= CenterX; x--) { if (src[x,y].A == 255) break; } float rScale = (x - CenterX) / CenterX; // Render the pixels of the row for (x = rect.Left; x < rect.Right; x++) { if (x < CenterX) { dst[x,y] = src.GetBilinearSample(CenterX - ((CenterX - x) * lScale),y); } else { dst[x,y] = src.GetBilinearSample(CenterX + ((x - CenterX) * rScale),y); } } } } Quote Red ochre Plugin pack.............. Diabolical Drawings ................Real Paintings Link to comment Share on other sites More sharing options...
Ego Eram Reputo Posted December 6, 2015 Share Posted December 6, 2015 How about this one: http://forums.getpaint.net/index.php?/topic/28298-trs-paste-warp/ 1 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...
BoltBait Posted December 6, 2015 Share Posted December 6, 2015 How about this one: http://forums.getpaint.net/index.php?/topic/28298-trs-paste-warp/ That's the one I was thinking of when I posted the other link above. So, ignore my post and look at this link. Quote Download: BoltBait's Plugin Pack | CodeLab | and a Free Computer Dominos Game Link to comment Share on other sites More sharing options...
Red ochre Posted December 6, 2015 Share Posted December 6, 2015 My memory is useless! Quote Red ochre Plugin pack.............. Diabolical Drawings ................Real Paintings Link to comment Share on other sites More sharing options...
Cc4FuzzyHuggles Posted December 6, 2015 Share Posted December 6, 2015 (edited) Perhaps the seamless texture helper plugin used with boltbaits fill plugin can help you. Although his fill plugin tiles, you might be able to play with the tiling enough to where you get something that is OK.http://forums.getpaint.net/index.php?/topic/2244-seamless-texture-helper-plugin/(note, the texture plugin page links to a different fill plugin, but that fill plugin doesn't work anymore. So just try boltbait's instead.) Edited December 6, 2015 by Cc4FuzzyHuggles Quote *~ Cc4FuzzyHuggles Gallery ~* Link to comment Share on other sites More sharing options...
acoustichead Posted December 8, 2015 Author Share Posted December 8, 2015 (edited) I don't think that plugin does anything more than superimpose one image over another. As I interpret acoustichead's request, it's for a plugin that spacially distorts the image to fit into the selection. I'm not sure the goal is well-defined enough to implement as a plugin for anything but trivial cases, and perhaps not even for that. It appears to me that in the example given, the pattern is compressed in the X direction to fit the selection, and would look different if it were compressed in the Y direction instead. EDIT: I can see a simple algorithm for mapping a rectangular region to a convex region. For any point in the convex region, compute the rectangle's X coordinate based on the proportion of the distance between the convex region's left and right boundaries at the Y value, and the Y coordinate based on the proportion of the distance between the upper and lower boundaries at the X value. In other words, bilinear interpolation based on the convex region's current X row and Y column. This could be extended to map a convex region to another convex region by essentially first mapping the source convex region to a rectangle, using the same idea. You are 100% correct with what you're understanding from what I wrote. I do want it to intentionally distort the image to fit the space selected when pasted in. I really need to thank you all I had no idea the forums here were so welcoming and helpful . This is exactly what I was looking for! http://forums.getpaint.net/index.php?/topic/28298-trs-paste-warp/ Thank you all so much! Edited December 8, 2015 by acoustichead 1 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.