Custom G'MIC script not working

Yeah, I realised that {!$x} means a boolean NOT and the loop broke. Here’s the filter working as it should (with a new name), though I reckon I could add some salt-and-pepper noise to make it even more erratic:

I’ll also add a channel-locking feature in future though I eventually wish to include it as a community filter by making a pull request. That means I’ll need to save it as a named .gmic file, which didn’t work last time.

@Joan_Rake1 Looks interesting. What did you have in mind for this filter? Where are you using it?

It’s for general use, though I use it to generate extremely-distorted and ‘raw’ textures in a matter of seconds:



Those three are on the default settings (with the exception of the plasma texture rendering been turned on). When applied on other images the results are even messier:

I’m not done yet; I’d like to include blurring in addition to channel-locking.

Just save the content of your .gmic file as a new file your_name.gmic and I’ll add it to the gmic-community repository, and register it as a new external filter source. So it will appear for everyone after a filter update.

Will do; I’ve added the blurring and moved to using quadtree-based ‘pixelisation’. All I need now is to figure out how to lock channels. Can I use channel names instead of numbers when passing it to the warp command?

What does channel-locking means precisely ? You want to apply the filter only on some channels ?
If so, I’d suggest you add a parameter Channel(s) in your parameter list and use command -apply_channels (shortcut -ac), as it is already done for other filters.
Should be as simple as adding:

#@gui : sep = separator(), Channel(s) = choice("All","RGBA [all]","RGB [all]","RGB [red]","RGB [green]","RGB [blue]","RGBA [alpha]","Linear RGB [all]","Linear RGB [red]","Linear RGB [green]","Linear RGB [blue]","YCbCr [luminance]","YCbCr [blue-red chrominances]","YCbCr [blue chrominance]","YCbCr [red chrominance]","YCbCr [green chrominance]","Lab [lightness]","Lab [ab-chrominances]","Lab [a-chrominance]","Lab [b-chrominance]","Lch [ch-chrominances]","Lch [c-chrominance]","Lch [h-chrominance]","HSV [hue]","HSV [saturation]","HSV [value]","HSI [intensity]","HSL [lightness]","CMYK [cyan]","CMYK [magenta]","CMYK [yellow]","CMYK [key]","YIQ [luma]","YIQ [chromas]")
#@gui : Value action = choice("None","Cut","Normalize")

and add a new command like that:


fx_hyperwarpplus :
  -ac "-hyperwarpplus $*",$-2,$-1

(and put this new command as the command to execute for the filter).

That’s at the end of the filter; what I want is something that sets the channel option right at the -fx_warp_by_intensity command.

Here’s the command as it stands now.

All that from the almost default settings: that is pretty cool. The 3rd image is like a Chinese painting of misty mountains and the river that meanders between them.

Yeah, it’s pretty good for extreme abstraction; the blurring produces interesting artistic forms. It’s especially good with creating layer masks:

The blue/black boxed artifacts look like a tiling issue in algorithm…

That’s the work of a layer mask.

I had an error but I figured out that it was due to local variables not being transferred. I have no idea why I was talking about a pull request but here’s the script if you wish to add it.

Added in Degradations/

Thanks, I might add some more filters soon. I’ll PM you if I do. For now I’ve tried to fix and update UltraWarp++ but the filter broke again without me editing it:


This might be related to the presence of an alpha channel, I’ll check that asap.

I tested an image without an alpha channel and it still didn’t work. Strangely, after I rebuilt the script, it works again with the only exception being that whenever I use a specified channel in the warp loop with plasma texture generation turned on, the image turns into a wall of alpha.

Never mind, I fixed that too. The error persists.

Fully working; I fixed the business with the alpha channel.

(edited twice because ‘initial’ script had another defect and the ‘second’ one had yet another)

Updated.

Cool, though it would be nice to have an alpha channel for the quadtree filter. I have no idea how that filter works but I know that it doesn’t use alpha channels; even removing the -to_rgb option doesn’t add that.