Glitch Art Filters?


#81

@Joan_Rake1 I believe I know how to theoretically replicate codebook filter. Each pixel color have 5 vertical lines as repeating that are randomized on lch color space. That is all there is on codebook filter. User input on constraints would help.

I think I might have to experiment with that. Most likely, the randomization could be swapping channels within different color space and using different color space. That to get something very similar to codebook. Or maybe xor operation per colors.

Hmm, I think I’ll shall make a filter.


News! I’m on to something here!

image

image

https://i.stack.imgur.com/WGZu1.jpg - for comparison to the above image.


(dumb) #82

While you haven’t got the insecure encryption effect (which is a bit messier), you’ve got an interesting effect nonetheless. Right now I’m trying to think how one could emulate broken screens because I took a one-off trip to Reddit and found this:

I’m thinking of something that moves along block-by-block and inserts rectangles of different sizes using patterns of colours which are randomly disrupted and replaced.


#83

Yeah, it’s not quite the best. I’m close to a solution to emulating the filter though even though it won’t be the same. I need to know how to make random color mapping. My solution to emulate the stripe effect found in Codebook is to use f “x %$1” n 0,255 . And then assign a random gradient map with random numbers.


(dumb) #84

Though going by the book and using a complete AES electronic codebook mode encryption algorithm to mess up the data is good, this could have far more potential due to easier tweakability. With regards to random maps, you could make use of the mesh blend filter.


#85

Okay, I think I got it now. Sorry about all of those edits. I discovered the pseudo_c command, and running the filter twice in a row gives the same result that you see in pdn version.

#@gui _
#@gui Psuedo-ECB (Electronic Code Book Algorithm): psuedo_ecb, _psuedo_ecb_preview(0)
#@gui : note = note("This filter is inspired by one of the glitch plugin for Paint.NET This doesn't actually emulate how the codebook encryption algorithm actually work, but it is inspired from it.  This filter uses bomb blending mode which involves RGBA Transfer Function Mesh. See Mesh Blend filter for a link. \n\n <u>Note that the filter works best on images with large patches of single colors.</u> ")
#@gui : sep = separator()
#@gui : Length of Gradient = int (3,1,16)
#@gui : ECB Angle = float(45,0,360)
#@gui : ECB Inversion = bool(0)
#@gui : Sharpening Noise Processing = float (15,0,200)
#@gui : sep = separator()
#@gui : Transfer Mesh Size for Image (Squared) = int (256,4,256)
#@gui : Image Mesh Contrast = int (75,25,100)
#@gui : Transfer Mesh Size for Gradient (Squared) = int (16,4,256)
#@gui : Gradient Mesh Contrast = int (100,25,100)
#@gui : Full Encryption Effect? = bool(0)
#@gui : sep = separator(), Preview type = choice("Full","Forward horizontal","Forward vertical","Backward horizontal","Backward vertical","Duplicate top","Duplicate left","Duplicate bottom","Duplicate right","Duplicate horizontal","Duplicate vertical","Checkered","Checkered inverse")
#@gui : sep = separator(), note = note("<small>Author : <i>Reptorian</i>      Latest update: <i>2018/12/27</i>.</small>")

psuedo_ecb:
repeat {$9+1}
psuedo_ecb_generate $1,$2,$3,$4,$5,$6,$7,$8
done

psuedo_ecb_generate:
+ac "ecb_gradient_base[0] $1,$2,$3",rgb
local[0]
sharpen $4
+pseudo_c[0]
+fx_blend_bomb[0] 0,1,$5,$5,0,0,$6,0,0,0,1,0
blend xor
endlocal
fx_blend_bomb[1] 0,1,$7,$7,0,0,$8,0,0,0,0,0
blend xor
ecb_gradient_base:
f "ang=pi*$2/180;G=x*cos(ang)+y*sin(ang);G%$1"  n 0,255 
if {$3==1}mul -1 abs fi

_psuedo_ecb_preview :
gui_split_preview "psuedo_ecb ${1--2}",$-1

And the samples of the finished ECB filter. You can clearly see it resemblance to the pdn filter. Plus, this really does look glitched.

image

image


(dumb) #86

What wizardry is this? I certainly love it, and I’ve tweaked quite a few aspects of the filter to make it even more eccentric. All blend modes apart from ‘edges’ are included.

#@gui Pseudo-ECB (Electronic Code Book Algorithm): pseudo_ecb, _pseudo_ecb_preview(0)
#@gui : note = note("This filter is inspired by one of the glitch plugin for Paint.NET This doesn't actually emulate how the codebook encryption algorithm actually work, but it is inspired from it.  This filter uses bomb blending mode which involves RGBA Transfer Function Mesh. See Mesh Blend filter for a link. \n\n <u>Note that the filter works best on images with large patches of single colors.</u> ")
#@gui Pseudo-ECB (Electronic Code Book Algorithm): pseudo_ecb, _pseudo_ecb_preview(0)
#@gui : note = note("This filter is inspired by one of the glitch plugin for Paint.NET This doesn't actually emulate how the codebook encryption algorithm actually work, but it is inspired from it.  This filter uses bomb blending mode which involves RGBA Transfer Function Mesh. See Mesh Blend filter for a link. \n\n <u>Note that the filter works best on images with large patches of single colors.</u> ")
#@gui : sep = separator()
#@gui : 1. Length of Gradient = float(3,0,32)
#@gui : 2. ECB Angle = float(135,0,360)
#@gui : 3. ECB Inversion = bool(0)
#@gui : 4. Sharpening Noise Processing = float(15,0,200)
#@gui : sep = separator()
#@gui : 5. Transfer Mesh Size for Image (Squared) = int(256,2,256)
#@gui : 6. Image Mesh Contrast = int(75,25,100)
#@gui : 7. Transfer Mesh Size for Gradient (Squared) = int(16,2,256)
#@gui : 8. Gradient Mesh Contrast = int(100,25,100)
#@gui : 9. Double Encryption Effect = bool(0)
#@gui : 10. Inner Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 11. Inner Blend Opacity = float(1,0,1)
#@gui : 12. Outer Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 13. Outer Blend Opacity = float(1,0,1)
#@gui : sep = separator(), 14-16. Preview type = choice("Full","Forward horizontal","Forward vertical","Backward horizontal","Backward vertical","Duplicate top","Duplicate left","Duplicate bottom","Duplicate right","Duplicate horizontal","Duplicate vertical","Checkered","Checkered inverse"), Preview split = point(50,50,0,0,200,200,200,0,10,0)
#@gui : sep = separator(), note = note("<small>Author : <i>Reptorian</i>      Latest update: <i>2018/12/27</i>.</small>")

pseudo_ecb:
repeat $! l[$>]
repeat {$9+1}
pseudo_ecb_generate $1,$2,$3,$4,$5,$6,$7,$8,$10,$11,$12,$13
done
endl done

pseudo_ecb_generate:
-m "MergeChoice : $""=_mode" -MergeChoice "add","alpha","and","average","blue","burn","darken","difference","divide","dodge","exclusion","freeze","grainextract","grainmerge","green","hardlight","hardmix","hue","interpolation","lighten","lightness","linearburn","linearlight","luminance","multiply","negation","or","overlay","pinlight","red","reflect","saturation","screen","shapeaverage","softburn","softdodge","softlight","stamp","subtract","value","vividlight","xor","edges","error"
+ac "ecb_gradient_base[0] $1,$2,$3",rgb
local[0]
sharpen $4
+pseudo_c[0]
+fx_blend_bomb[0] 0,1,$5,$5,0,0,$6,0,0,0,1,0
blend ${_mode{$9+1}},$10
endlocal
fx_blend_bomb[1] 0,1,$7,$7,0,0,$8,0,0,0,0,0
blend ${_mode{$11+1}},$12

ecb_gradient_base:
f "ang=pi*$2/180;G=x*cos(ang)+y*sin(ang);G%$1" n 0,255
if {$3==1} mul -1 abs fi

_pseudo_ecb_preview :
gui_split_preview "pseudo_ecb $*",${-3--1}

image

image


#87

I like the changes, but I don’t really like the part about Gradient size being float value. The changes isn’t needed there. The other part is fine. I wanted to add more blending mode, but didn’t thought about opacity or inner/outer, but I think I have full control over the ECB effect now. It’s pretty easy to get what you want.


#88

@Joan_Rake1, @Reptorian,

Thank you for your interesting filters.

Is the following filter suitable for “improvement” :grinning: ? :

G’MIC>Testing>Jayprich>Jpr Phasecongruence?


#89

Never mind about the thing about them being two separate filter. I think I’m convinced about implementing the contour looks. Either Joan or I could do it.

That gives me a idea. I wonder if there could be a filter that copy gui from other filter, and applies filters just as if you were using them in one some day.

@David_Tschumperle ^^ Is this thing even possible? The thing about a filter copying gui from other filter and applies effect.


Here’s the suggest filter mixed with the Joan modification of my filter


(dumb) #90

That would require a GUI that can add and remove all the possible things that a G’MIC plugin GUI could have. The plugin cannot do this, but one could make an interactive window using G’MIC itself (such as those in the ‘games & demos’ script or the interactive curves filter).


(dumb) #91

@iarga I’m not sure how I could mess with that edge-detection algorithm but I know that a stripped down version for a single direction in the XY plane could be useful for things like the encryption thing - one could use it as a mask to sharpen things in that direction only or tangential to it to produce even more artefacts.

Meanwhile, I’m looking at the streak command to see if one can do anything there. The results I’m getting with the following filter are too poor because I end up getting images with no alpha values:

#@gui Superstreak: fx_superstreak, fx_superstreak_preview(0)
#@gui : sep = separator()
#@gui : 1. Iterations = int(10,1,20)
#@gui : 2. Propagation = choice(3,“Backward”,“Forward”,“Bidirectional [Sharp]”,“Bidirectional [Smooth]”)

_superstreak :
repeat $! l[$>]
to_rgba
if {!$4} T,R,G,B,A=0 else T,R,G,B,A=${1-5} fi +select_color $T,$R,$G,$B,$A
if {$8==3} srgb2rgb.. fi
f.. "
const step = max(1,$6%*min(w,h));
const angle = $7*pi/180;
const dx = step*cos(angle);
const dy = step*sin(angle);
if (!i(#-1),I,
ixf = xf = x; iyf = yf = y; lf = 0; if ($8>=1, while (i(#-1,ixf=round(xf),iyf=round(yf)), ++lf; xf-=dx; yf-=dy));
ixb = xb = x; iyb = yb = y; lb = 0; if ($8!=1, while (i(#-1,ixb=round(xb),iyb=round(yb)), ++lb; xb+=dx; yb+=dy));
$8==0?I(ixb,iyb):
$8==1?I(ixf,iyf):
$8==2?(lf<lb?I(ixf,iyf):I(ixb,iyb)):
(lb*lb*I(ixf,iyf) + lf*lf*I(ixb,iyb))/(lb^2+lf^2);
)"
if {$8==3} rgb2srgb.. fi
rm.
endl done
fx_superstreak :
repeat $! l[$>]
repeat $1
a={u(0,512)}
b={round(u(0,255))}
c={round(u(0,255))}
d={round(u(0,255))}
e={round(u(0,255))}
f={u(10,30)}
g={u(0,360)}
_superstreak {$a},{$b},{$c},{$d},{$e},{$f},{$g},$2
done
endl done
fx_superstreak_preview :
fx_superstreak $*

#92

Since I’m gonna take a break from making filter. Do you think you could implement double gradients that blend with each other and with multiple blend modes? Also, a option to use one or two gradients. I believe that would help give a “true ECB” effect


(dumb) #93

That can be done relatively easily, I imagine. Meanwhile, here’s an odd result from an ‘attenuate red eye’ filter applied twice on an image that had an intense radial blur:

image


#94

Ended up taking a break and adding the double gradient effect. Also added final interpolation blending after equalize. Now the result should have a lot of contrast.

#@gui Pseudo-ECB (Electronic Code Book Algorithm): pseudo_ecb, _pseudo_ecb_preview(0)
#@gui : note = note("This filter is inspired by one of the glitch plugin for Paint.NET This doesn't actually emulate how the codebook encryption algorithm actually work, but it is inspired from it.  This filter uses bomb blending mode which involves RGBA Transfer Function Mesh. See Mesh Blend filter for a link. \n\n <u>Note that the filter works best on images with large patches of single colors.</u> ")
#@gui : sep = separator()
#@gui : note = note("<b>ECB Pattern Key Generator</b>")
#@gui : 1. Double Gradient? = bool(0)
#@gui : 2. Length of Gradient#1 = int(3,0,32)
#@gui : 3. ECB Angle#1 = float(135,0,360)
#@gui : 4. ECB Inversion#1 = bool(0)
#@gui : 5. Length of Gradient#2 = int(3,0,32)
#@gui : 6. ECB Angle#2 = float(135,0,360)
#@gui : 7. ECB Inversion#2 = bool(0)
#@gui : 8. Gradient Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 9. Gradient Blend Opacity = float(1,0,1)
#@gui : sep = separator()
#@gui : note = note("<b>Sharpen Filtering</b>")
#@gui : 10. Sharpening Noise Processing = float(15,0,200)
#@gui : sep = separator()
#@gui : note = note("<b>ECB Image Processing</b>")
#@gui : 11. Transfer Mesh Size for Image (Squared) = int(256,2,256)
#@gui : 12. Image Mesh Contrast = int(75,25,100)
#@gui : 13. Transfer Mesh Size for Gradient (Squared) = int(16,2,256)
#@gui : 14. Gradient Mesh Contrast = int(100,25,100)
#@gui : 15. Double Encryption Effect = bool(0)
#@gui : 16. Inner Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 17. Inner Blend Opacity = float(1,0,1)
#@gui : 18. Outer Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 19. Outer Blend Opacity = float(1,0,1)
#@gui : sep = separator(), 20-22. Preview type = choice("Full","Forward horizontal","Forward vertical","Backward horizontal","Backward vertical","Duplicate top","Duplicate left","Duplicate bottom","Duplicate right","Duplicate horizontal","Duplicate vertical","Checkered","Checkered inverse"), Preview split = point(50,50,0,0,200,200,200,0,10,0)
#@gui : sep = separator(), note = note("<small>Author : <i>Reptorian</i>      Latest update: <i>2018/12/28</i>.</small>")

pseudo_ecb:
repeat $! l[$>]
repeat {$15+1}
pseudo_ecb_generate $1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$16,$17,$18,$19
done
endl done

pseudo_ecb_generate:
-m "MergeChoice : $""=_mode" -MergeChoice "add","alpha","and","average","blue","burn","darken","difference","divide","dodge","exclusion","freeze","grainextract","grainmerge","green","hardlight","hardmix","hue","interpolation","lighten","lightness","linearburn","linearlight","luminance","multiply","negation","or","overlay","pinlight","red","reflect","saturation","screen","shapeaverage","softburn","softdodge","softlight","stamp","subtract","value","vividlight","xor","edges","error"
+ac "ecb_gradient_base[0] $2,$3,$4",rgb
pseudo_c[1]
local[1]
if {$1==1} +ac "ecb_gradient_base[0] $5,$6,$7",rgb
pseudo_c[1]
blend ${_mode{$8+1}},$9 equalize fi
endlocal
local[0]
sharpen $10
+pseudo_c[0]
+fx_blend_bomb[0] 0,1,$11,$11,0,0,$12,0,0,0,1,0
blend ${_mode{$15+1}},$16
endlocal
fx_blend_bomb[1] 0,1,$13,$13,0,0,$14,0,0,0,0,0
equalize[1]
blend ${_mode{$17+1}},$18
+equalize
blend interpolation

ecb_gradient_base:
f "ang=pi*$2/180;G=x*cos(ang)+y*sin(ang);G%$1" n 0,255
if {$3==1} mul -1 abs fi

_pseudo_ecb_preview :
gui_split_preview "pseudo_ecb $*",${-3--1}

Example of the ECB Key -

image

Example with double gradient used -

image

Original - https://www.pcper.com/files/imagecache/article_max_width/news/2013-04-30/Tux.jpg

Another tux glitched with ECB


(dumb) #95

Anyone want a wallpaper?


#96

@racer-x

Since you have a similar avatar, I’m going to assume you are dipstick at the Paint dot net forum. I can’t seem to access QAM Fault with this image even with the required dll inside.

image

I need to see result to make a theory of how I can do QAM Fault for G’MIC. Last time I was able to use QAM Fault, I saw 2 channels, and three tabs. I would like to know which one of those tabs refers to boosting signal. I guess the other two refers to phase-shift.

The G’MIC QAM Filter would actually have more features to it like restricting QAM to X or Y and/or the pixel values.


(dumb) #97

First, I’ve worked on the ECB filter once more and used a patched pseudo_c command:

#@gui Pseudo-ECB (Electronic Code Book Algorithm): pseudo_ecb, _pseudo_ecb_preview(0)
#@gui : note = note("This filter is inspired by one of the glitch plugin for Paint.NET This doesn't actually emulate how the codebook encryption algorithm actually work, but it is inspired from it.  This filter uses bomb blending mode which involves RGBA Transfer Function Mesh. See Mesh Blend filter for a link. \n\n <u>Note that the filter works best on images with large patches of single colors.</u> ")
#@gui : sep = separator()
#@gui : note = note("<b>ECB Pattern Key Generator</b>")
#@gui : 1. Double Gradient? = bool(0)
#@gui : 2. Length of Gradient#1 = float(3,0,32)
#@gui : 3. ECB Angle#1 = float(135,0,360)
#@gui : 4. ECB Inversion#1 = bool(0)
#@gui : 5. Length of Gradient#2 = float(3,0,32)
#@gui : 6. ECB Angle#2 = float(135,0,360)
#@gui : 7. ECB Inversion#2 = bool(0)
#@gui : 8. Gradient Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 9. Gradient Blend Opacity = float(1,0,1)
#@gui : sep = separator()
#@gui : note = note("<b>Sharpen Filtering</b>")
#@gui : 10. Sharpening Noise Processing = float(15,0,200)
#@gui : sep = separator()
#@gui : note = note("<b>ECB Image Processing</b>")
#@gui : 11. Transfer Mesh Size for Image (Squared) = int(256,2,256)
#@gui : 12. Image Mesh Contrast = float(100,0,100)
#@gui : 13. Transfer Mesh Size for Gradient (Squared) = int(16,2,256)
#@gui : 14. Gradient Mesh Contrast = float(100,0,100)
#@gui : 15. Double Encryption Effect = bool(0)
#@gui : 16. Blend 1 = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 17. Blend 1 Opacity = float(1,0,1)
#@gui : 18. Blend 2 = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 19. Blend 2 Opacity = float(1,0,1)
#@gui : 20. Blend 3 = choice(18,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : 21. Blend 3 Opacity = float(1,0,1)
#@gui : 22. Pseudocolouring = bool(1)
#@gui : sep = separator(), 23-25. Preview type = choice("Full","Forward horizontal","Forward vertical","Backward horizontal","Backward vertical","Duplicate top","Duplicate left","Duplicate bottom","Duplicate right","Duplicate horizontal","Duplicate vertical","Checkered","Checkered inverse"), Preview split = point(50,50,0,0,200,200,200,0,10,0)
#@gui : sep = separator(), note = note("<small>Author : <i>Reptorian</i>      Latest update: <i>2018/12/28</i>.</small>")

_pseudo_c : v - if {s!=1} to_gray. fi {max(1,iM)},1,1,3,u(255) round. map.. . rm.  v +

pseudo_ecb:
repeat $! l[$>]
repeat {$15+1}
pseudo_ecb_generate ${1-14},${16-22}
done
endl done

ecb_gradient_base:
f "ang=pi*$2/180;G=x*cos(ang)+y*sin(ang);G%($1)" n 0,255
if {$3==1} mul -1 abs fi

pseudo_ecb_generate:
-m "MergeChoice : $""=_mode" -MergeChoice "add","alpha","and","average","blue","burn","darken","difference","divide","dodge","exclusion","freeze","grainextract","grainmerge","green","hardlight","hardmix","hue","interpolation","lighten","lightness","linearburn","linearlight","luminance","multiply","negation","or","overlay","pinlight","red","reflect","saturation","screen","shapeaverage","softburn","softdodge","softlight","stamp","subtract","value","vividlight","xor","edges","error"
+ac "ecb_gradient_base[0] ${2-4}",rgb
if $20 _pseudo_c[1] fi
local[1]
if {$1==1} +ac "ecb_gradient_base[0] ${5-7}",rgb
if $20 _pseudo_c[1] fi
blend ${_mode{$8+1}},$9 equalize fi
endlocal
local[0]
sharpen $10
if $20 +pseudo_c[0] fi
+fx_blend_bomb[0] 0,1,$11,$11,0,2,$12,0,0,0,1,0
blend ${_mode{$15+1}},$16
endlocal
fx_blend_bomb[1] 0,1,$13,$13,0,2,$14,0,0,0,0,0
equalize[1]
blend ${_mode{$17+1}},$18
+equalize
blend ${_mode{$19+1}},$20

_pseudo_ecb_preview :
gui_split_preview "pseudo_ecb $*",${-3--1}

The filter is now able to make trippy patterns like this with ‘pseudocolouring’ off and longer pattern lengths:

As for the QAM filter, here’s the only result I can find (from the PDN forum thread). Ignoring the scanlines, much of the effect is possible with a sinusoidal carrier and a modulo operation in a single channel.

image

Here’s to_rgb ac "f "(2*i*sin(y/20))%255"",rgb_g:

image

…and then to_rgb ac "f "(5*i*sin(y/20)+255/2)%255"",rgb:

image


#98

And here, I was thinking of being able to turn off equalize and interpolation final to make users be able to have more control over how the final image will look. Equalize and interpolation works better with double, but worse with one gradient. But sometimes, users may want the opposite of that.

#@gui Pseudo-ECB (Electronic Code Book Algorithm): pseudo_ecb, _pseudo_ecb_preview(0)
#@gui : note = note("This filter is inspired by one of the glitch plugin for Paint.NET This doesn't actually emulate how the codebook encryption algorithm actually work, but it is inspired from it.  This filter uses bomb blending mode which involves RGBA Transfer Function Mesh. See Mesh Blend filter for a link. \n\n <u>Note that the filter works best on images with large patches of single colors.</u> ")
#@gui : sep = separator()
#@gui : note = note("<b>ECB Pattern Key Generator</b>")
#@gui : sep = separator()
#@gui : note = note("<b>Final Color Processing</b> \n\n <i>This refers to the how the colors are going to be processed. If you find that there's too little difference in hues or chroma or luminosity in local areas, this should be on. Sometimes, the result are better without the final processing.</i>")
#@gui : Lighting Balance Final ECB Processing = bool(1)
#@gui : sep = separator()
#@gui : Double Gradient? = bool(1)
#@gui : Length of Gradient#1 = int(3,0,32)
#@gui : ECB Angle#1 = float(135,0,360)
#@gui : ECB Inversion#1 = bool(0)
#@gui : Length of Gradient#2 = int(3,0,32)
#@gui : ECB Angle#2 = float(135,0,360)
#@gui : ECB Inversion#2 = bool(0)
#@gui : Gradient Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : Gradient Blend Opacity = float(1,0,1)
#@gui : sep = separator()
#@gui : note = note("<b>Sharpen Filtering</b>")
#@gui : Sharpening Noise Processing = float(5,0,200)
#@gui : sep = separator()
#@gui : note = note("<b>ECB Image Processing</b>")
#@gui : Transfer Mesh Size for Image (Squared) = int(256,2,256)
#@gui : Image Mesh Contrast = int(75,25,100)
#@gui : Transfer Mesh Size for Gradient (Squared) = int(16,2,256)
#@gui : Gradient Mesh Contrast = int(100,25,100)
#@gui : Double Encryption Effect = bool(1)
#@gui : Inner Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : Inner Blend Opacity = float(1,0,1)
#@gui : Outer Blend = choice(41,"add","alpha","and","average","blue","burn","darken",
#@gui : "difference","divide","dodge","exclusion","freeze",
#@gui : "grainextract","grainmerge","green","hardlight","hardmix",
#@gui : "hue","interpolation","lighten","lightness","linearburn",
#@gui : "linearlight","luminance","multiply","negation","or",
#@gui : "overlay","pinlight","red","reflect","saturation","screen",
#@gui : "shapeaverage","softburn","softdodge","softlight","stamp",
#@gui : "subtract","value","vividlight","xor")
#@gui : Outer Blend Opacity = float(1,0,1)
#@gui : sep = separator(), Preview type = choice("Full","Forward horizontal","Forward vertical","Backward horizontal","Backward vertical","Duplicate top","Duplicate left","Duplicate bottom","Duplicate right","Duplicate horizontal","Duplicate vertical","Checkered","Checkered inverse"), Preview split = point(50,50,0,0,200,200,200,0,10,0)
#@gui : sep = separator(), note = note("<small>Author : <i>Reptorian</i>      Latest update: <i>2018/12/28</i>.</small>")

pseudo_ecb:
repeat $! l[$>]
repeat {$16+1}
pseudo_ecb_generate $1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13,$14,$15,$17,$18,$19,$20
done
endl done

pseudo_ecb_generate:
-m "MergeChoice : $""=_mode" -MergeChoice "add","alpha","and","average","blue","burn","darken","difference","divide","dodge","exclusion","freeze","grainextract","grainmerge","green","hardlight","hardmix","hue","interpolation","lighten","lightness","linearburn","linearlight","luminance","multiply","negation","or","overlay","pinlight","red","reflect","saturation","screen","shapeaverage","softburn","softdodge","softlight","stamp","subtract","value","vividlight","xor","edges","error"
+ac "ecb_gradient_base[0] $3,$4,$5",rgb
pseudo_c[1]
local[1]
if {$2==1} +ac "ecb_gradient_base[0] $6,$7,$8",rgb
pseudo_c[1]
blend ${_mode{$9+1}},$10 if {$1==1} equalize fi fi
endlocal
local[0]
sharpen $11
+pseudo_c[0]
+fx_blend_bomb[0] 0,1,$12,$12,0,0,$13,0,0,0,1,0
blend ${_mode{$16+1}},$17
endlocal
fx_blend_bomb[1] 0,1,$14,$14,0,0,$15,0,0,0,0,0
if {$1==1} equalize[1] fi
blend ${_mode{$18+1}},$19
if {$1==1} +equalize blend interpolation fi

ecb_gradient_base:
f "ang=pi*$2/180;G=x*cos(ang)+y*sin(ang);G%$1" n 0,255
if {$3==1} mul -1 abs fi

_pseudo_ecb_preview :
gui_split_preview "pseudo_ecb $*",${-3--1}

(dumb) #99

Included that now. https://pastebin.com/49S6GvBp


#100

I’m getting a window that pops up every once in a while if I refresh the filter.