Sign in to follow this  
ArgusMagnus

FFT / IFFT Effect

Recommended Posts

Download: https://forums.getpaint.net/topic/32337-argusmagnus-plugin-pack-20181019/

(Copy the file "ArgusPDN.FFTEffects.dll" to the "paint.net/Effects" folder)

 

 

This Plugin contains 4 effects related to Fast Fourier Transform and Signal Processing in the Frequency Domain:

 

1. Transform->Fast Fourier Transform: Transforms either intensity image or one of the channels (R,G,B ) to and from the frequency domain. The transformed image contains the magnitude information in the R and G values and the phase information in the B value (which basically means: don't change the B value of any pixel too much are at all if you want to get a meaningful result when transforming back).

If you want to get a meaninful result when transforming back, there are two limitations: 1. Don’t change the B component (the phase information is important), 2. Non-rectangular Selections won’t work.

 

2. Signal Processing->Low Pass Filter: The same as using the transform effect, removing (setting to black or transparent) all pixel outside a rectangle around the center and transforming back only this is faster, more accurate (less information is lost) and easier to control

 

3. Signal Processing->High Pass Filter: The same as using the transform effect, removing all pixels inside a rectangle around the center and transforming back (again, faster, more accurate, easier controlled)

 

5. Signal Processing->Band Pass Filter: Combination of Low and High Pass Filter.

 

Example: FFT

lw59GV.png

 

Example images (high pass filtered, adjusted and blended together):

09sGip.pngJKzh9N.png

 

 

The plugin actually uses the FFTW library (fftw.org), I have not written the transformation code myself (mainly for performance reasons)

Edited by ArgusMagnus
Added links to zipped DLL of Null54's updated version
  • Upvote 1

Share this post


Link to post
Share on other sites
8 hours ago, Pratyush said:

Do you have update of the effect. It is not working on PDN v.4.0.20.

 

These effects seem to work just fine for me on PDN v4.0.21.  What issue are you seeing?

Share this post


Link to post
Share on other sites
On 8/25/2015 at 6:02 AM, ArgusMagnus said:

Copy the files "ArgusPaintNet.FTT.dll" and "ArgusPaintNet.Shared.dll" and the folder "NativeBinaries" to the "paint.net/Effects" folder

 

Did you do this??

 

Are you using the Windows Store version? The locations are slightly different see https://www.getpaint.net/doc/latest/InstallPlugins.html#4

Share this post


Link to post
Share on other sites
On 8/24/2015 at 11:32 PM, ArgusMagnus said:

"NativeBinaries" to the "paint.net/Effects" folder

 

I messed that part. I took x64 DLL from x64 folder & deleted all other dll and folder and from from native Binaries. After putting dll in X64 folder in NativeBinaries. Now it is working fine. I placed DLL.

Edited by Pratyush

Share this post


Link to post
Share on other sites

Just a heads up, this plugin will not work in the upcoming Paint.NET v4.1 update. (see here: https://forums.getpaint.net/topic/113153-paintnet-41-beta-build-6808/?do=findComment&comment=548571 )

 

 

The reason is the use of PointInt32 which has been renamed to Point2Int32. I'm also planning on moving that type, and others (e.g. RectInt32), into a different namespace. So, I'd advise against using it for now.

Share this post


Link to post
Share on other sites

Every time I try to use the effects it gives me this error message:

Quote

File: C:\Users\User\Downloads\paint.net latest\paint.net latest\Effects\ArgusPaintNet.FFT.dll
      Name: ArgusPaintNet.FFT.BandPassFilterEffect
      Version: 1.0.0.0
      Author: Argus Magnus
      Copyright: Copyright © ArgusMagnus 2015
      Website: http://forums.getpaint.net/index.php?/topic/32205-fft-ifft-effect/
      Full error message: PaintDotNet.WorkerThreadException: Worker thread threw an exception ---> System.EntryPointNotFoundException: Unable to find an entry point named 'fftw_alloc_complex' in DLL 'libfftw3-3.dll'.
   at ArgusPaintNet.FFT.FFTWInterop.FFTW.fftw_alloc_complex(Int32 size)
   at ArgusPaintNet.FFT.FFTWInterop.FFTW.GetTwoWayPlan(Int32 width, Int32 height)
   at ArgusPaintNet.FFT.BandPassFilterEffect.OnRenderCore(Rectangle[] renderRects, Int32 startIndex, Int32 length)
   at PaintDotNet.Effects.Effect`1.Render(EffectConfigToken parameters, RenderArgs dstArgs, RenderArgs srcArgs, Rectangle[] rois, Int32 startIndex, Int32 length) in D:\src\pdn\src\Effects\Effect`1.cs:line 99
   at PaintDotNet.Effects.BackgroundEffectRenderer.RenderWithClipMask(Effect effect, EffectConfigToken token, RenderArgs dstArgs, RenderArgs srcArgs, RectInt32[] rois, IRenderer`1 clipMaskRenderer) in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 196
   at PaintDotNet.Effects.BackgroundEffectRenderer.RendererContext.RenderTile(EffectConfigToken token, Int32 tileIndex) in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 175
   at PaintDotNet.Effects.BackgroundEffectRenderer.RendererContext.RenderNextTile(EffectConfigToken token) in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 167
   at PaintDotNet.Effects.BackgroundEffectRenderer.ThreadFunction() in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 267
   --- End of inner exception stack trace ---
   at PaintDotNet.Effects.BackgroundEffectRenderer.DrainExceptions() in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 443
   at PaintDotNet.Effects.BackgroundEffectRenderer.Abort() in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 399
   at PaintDotNet.Effects.BackgroundEffectRenderer.Start() in D:\src\pdn\src\PaintDotNet\Effects\BackgroundEffectRenderer.cs:line 345
   at PaintDotNet.Menus.EffectMenuBase.<>c__DisplayClass47_5.<RunEffectImpl>b__5() in D:\src\pdn\src\PaintDotNet\Menus\EffectMenuBase.cs:line 1068
 

 

Share this post


Link to post
Share on other sites
13 minutes ago, Sakana Oji said:

Every time I try to use the effects it gives me this error message

 

Do you have the DLL file libfftw3-3.dll installed on your system?

Share this post


Link to post
Share on other sites
1 minute ago, BoltBait said:

 

Do you have the DLL file libfftw3-3.dll installed on your system?

Yes, I already copied it to my folder and it's fixed!

Share this post


Link to post
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.

Sign in to follow this