Jump to content
How to Install Plugins ×

Photo Flood Fill Plug-In


pleska

Recommended Posts

Hi all,

I just wrote another plug-in effect. This one allows you to take an image and "flood-fill" it into the selection region repeating it over and over. If you have a repeating texture or other image this fill will load that texture. Options are included to change the origin of the image both positive and negative in both the X and Y. Also, stealing code from my gradient fill plug-in you can restrict the fill to a single masking color within the selection area.

If you use non-rectanglular selections this effect should work fine with the understanding that the the entire selection is actually bounded in a rectangle surrounding it. The image fill will be based on this imaginary bounding rectangle.

Play with it and let me know if there are any issues or questions on using it.

As with most effect plug-ins, download the binary zip file, and put the single DLL inside the zip into the effects directory of Paint.Net and then relaunch the application. The new effect should appear on the effects menu.

Enjoy,

Paul

 

MODERATORS NOTE:  This effect is incompatible with Paint.NET 4.0x

I would recommend using BoltBait's Fill From File instead. It does the same thing, but better and works in paint.net v4.

Effect DLL (Binary)

http://www.sapphireonline.com/Downloads/PhotoFloodFillPlugIn.zip

Effect Source Code

http://www.sapphireonline.com/Downloads/PhotoFloodFillPlugInSource.zip

Link to comment
Share on other sites

The image fill will be based on this imaginary bounding rectangle.

You're still clipping to the selection area though, right?

Yep,

I just use the rectanglular bounds of the selection region as a guide as to where to start the x and y repeating of the image. Although you only see the image in the selection area or the masked part of the selection area.

Paul

Link to comment
Share on other sites

Thanks so much for this, pleska!

I was desperately looking for a way to fill in pattern instead of colour, and this effect is exactly what I was looking for. Thanks for sharing it!

Greetings.

Link to comment
Share on other sites

  • 1 month later...

Yeh..

Also....

GRsites.com I think it is, has a BUNCH of free textures for you to use, make a seperate folder I suggest in My Pictures, and Select that with the pattern you want....That is what I am doing.

ravennm3.png
Link to comment
Share on other sites

  • 5 months later...

I have a request and I figured that this would be the best place to post it.

It would be nice to have the ability to set the blending mode of the image that is being imported. It would be similar to the Cloud effect that comes with PDN.

 

Take responsibility for your own intelligence. 😉 -Rick Brewster

Link to comment
Share on other sites

  • 1 month later...

Hello, crash report for ya. This was sent to me today.

This text file was created because Paint.NET crashed.
Please e-mail this file to paint.net@hotmail.com so we can diagnose and fix the problem.

Application version: Paint.NET v3.01 (Final Release build 3.01.2612.31539)
Time of crash: 19/03/2007 4:34:19 PM
Application uptime: 00:02:02.4062500
OS Version: 5.1.2600.131072 Service Pack 2 Workstation x86
.NET Framework version: 2.0.50727.42 x86
Processor: 2x "Intel(R) Pentium(R) 4 CPU 3.20GHz" @ ~3215MHz
Physical memory: 1023 MB
Tablet PC: no
Locale: pdnr.c: en-US, hklm: en-US, hkcu: n/a, cc: en-AU, cuic: en-US

Exception details:
System.IO.FileNotFoundException: pattern.png
  at System.Drawing.Image.FromFile(String filename, Boolean useEmbeddedColorManagement)
  at System.Drawing.Image.FromFile(String filename)
  at PaintDotNet.Effects.PhotoFloodFillEffectConfigDialog.ResetLimits()
  at PaintDotNet.Effects.PhotoFloodFillEffectConfigDialog.InitDialogFromToken(EffectConfigToken effectTokenCopy)
  at PaintDotNet.Effects.EffectConfigDialog.InitDialogFromToken()
  at PaintDotNet.Effects.EffectConfigDialog.set_EffectToken(EffectConfigToken value)
  at PaintDotNet.Menus.EffectMenuBase.RunEffect(Type effectType)
  at PaintDotNet.Menus.EffectMenuBase.EffectMenuItem_Click(Object sender, EventArgs e)
  at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
  at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
  at PaintDotNet.PdnMenuItem.OnClick(EventArgs e)
  at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
  at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
  at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
  at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
  at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
  at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
  at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
  at System.Windows.Forms.Control.WndProc(Message& m)
  at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
  at System.Windows.Forms.ToolStrip.WndProc(Message& m)
  at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
  at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
  at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
  at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
------------------------------------------------------------------------------

The Paint.NET Blog: https://blog.getpaint.net/

Donations are always appreciated! https://www.getpaint.net/donate.html

forumSig_bmwE60.jpg

Link to comment
Share on other sites

  • 5 weeks later...
  • 2 weeks later...

Thank you very much Paul!

This is a very useful tool, in fact it is just what I was searching for, since I am using a very small pattern and it would have taken me hours to fill my picture!!

So I just registered on the forum to thank you :)

(Sorry if I made mistakes in my post, because I am french :wink: )

Link to comment
Share on other sites

Hi Pleska,

Feel embarrassed with everyone thanking you for the great plugin when I am totally lost despite trying to use it.

Any chance of a step-by-step tutorial with graphics?

Link to comment
Share on other sites

  • 4 months later...

An idea to 'refresh' this plugin:

I've got an image with a transparent border (or not) like a single leave of tree.

I would like this plugin to fill randomly the selection with the image.

Randomly for the x,y position, and also with a random rotation +/- angle...

What do you think about it?

Link to comment
Share on other sites

I'm a fan of both ideas. ^^

But I haven't seen pleska for a while on the forum. Maybe the source could be of use?

Link to comment
Share on other sites

Apparently, according to the profile, pleska last visited the forums on 'Mon 1 October, 2007 5:32:52 am' (UTC DST).

The source code is also on the first post along with the plugin download. Whether that is the latest version or not I don't know; this is the first time I've visited this topic. Ever. Of any use Fisherman's Friend?

Link to comment
Share on other sites

Apparently, according to the profile, pleska last visited the forums on 'Mon 1 October, 2007 5:32:52 am' (UTC DST).

Ooops :oops: I didn't know you can see it on the profile page... :oops:

The source code is also on the first post along with the plugin download.

Well, this I have checked before I wrote my post. :) Of course it is.

Of any use Fisherman's Friend?

Maybe my imagination takes me too far, but how do you actually mean that?

I) If you ask me if you comment was helpful: Your well-written post are always welcome, and I'm convinced this was a help not only for me.

II) If you ask what I want to say with "of any use": I just wanted to suggest to use the sourcecode. MadJik is one of the finest developers here, and I'm sure he could create the desired things supported by the (public) source code. (Again: I have no knowledge about coding and programming, therefore I don't know if it's a help.)

III) Or is the phrase not correct? :oops: :oops: :oops:

Sorry if this is true.

Link to comment
Share on other sites

II) If you ask what I want to say with "of any use": I just wanted to suggest to use the sourcecode. MadJik is one of the finest developers here, and I'm sure he could create the desired things supported by the (public) source code. (Again: I have no knowledge about coding and programming, therefore I don't know if it's a help.)

That one.

My fault, I thought you were asking for the source and not suggesting it to others. My misinterpretation, not yours :oops:. Sorry for any confusion caused.

Link to comment
Share on other sites

An idea to 'refresh' this plugin:

I've got an image with a transparent border (or not) like a single leave of tree.

I would like this plugin to fill randomly the selection with the image.

Randomly for the x,y position, and also with a random rotation +/- angle...

What do you think about it?

Wonderful are you doing this one? I could use it.

I don't like asking for changes to plugins as I can't recontribute with any coding. but this is one thing I would most likely use.

thanks in advance! hint hint

Link to comment
Share on other sites

Sorry for any confusion caused.

Same for me... :oops:

Next time I'll do my best to make my point clear. And now I'd be interested what for example MadJik thinks about it, or especially whether pleska allows to use the source for an "advanced version" or not. :roll:

Link to comment
Share on other sites

  • 4 weeks later...

:? can you post some screenshots ? :?

:D then i know what im downloading .... :D

WHATZ.png

wear our signature and earn 50 studiocredits. pm me your username if you want to participate.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...