@scottyp
From this page: Krita Scripting School
I took time to search configurations for filters (Krita 4.3.0)
You can use it and provide it on the documentation page if you want, it could be useful for other to already have parameters list with domain values for each filter (and, list of filter that doesn’t work from scripting, because if you know which filters doesn’t work from scripting, you won’t loose time to understand what’s currently happening with your code
…)
Note
- Provided range values are from user interface; some filters can accept values outside range provided by interface
Working filters
Filter autocontrast (Adjust > Auto Contrast)
No parameters
Filter blur (Blur > Blur…)
'halfWidth' 0+
'halfHeight' 0+
'rotate' [0 to 360]
'strength' [0 to 100]
'shape' [0 (Circle),
1 (Rectangle)]
Filter burn (Adjust > Burn…)
'type' [0 (Shadows),
1 (Midtone),
2 (Highlights)]
'exposure' [0 to 1]
Filter colorbalance (Adjust > Color Balance…)
'cyan_red_midtones' [-100 to 100]
'yellow_green_midtones' [-100 to 100]
'magenta_blue_midtones' [-100 to 100]
'cyan_red_shadows' [-100 to 100]
'yellow_green_shadows' [-100 to 100]
'magenta_blue_shadows' [-100 to 100]
'cyan_red_highlights' [-100 to 100]
'yellow_green_highlights' [-100 to 100]
'magenta_blue_highlights' [-100 to 100]
'preserve_luminosity' [true, false]
Filter colortoalpha (Colors > Color to Alpha…)
'targetcolor' QColor() or '#rrggbb'
'threshold' [1 to 255]
Filter desaturate (Adjust > Desaturate…)
'type' [0 (Lightness),
1 (Luminosity: ITU-R BT.709),
2 (Luminosity: ITU-R BT.601),
3 (Average),
4 (Min),
5 (Max)]
Filter dodge (Adjust > Dodge…)
'type' [0 (Shadows),
1 (Midtone),
2 (Highlights)]
'exposure' [0 to 1]
Filter edge detection (Edge detection > Edge detection…)
'type' ['prewitt', 'sobol', 'simple']
'horizRadius' 0+
'vertRadius' 0+
'output' ['pythagorean' (All sides),
'xGrowth' (Top Edge),
'xFall' (Bottom Edge),
'yGrowth' (Right Edge),
'yFall' (Left Edge),
'radian' (Direction in Radians)]
'lockAspect' [true, false]
'transparency' [true, false]
Filter emboss all directions (Emboss > Emboss all direction)
No parameters
Filter emboss horizontal and vertical (Emboss > Emboss horizontal & vertical)
No parameters
Filter emboss horizontal only (Emboss > Emboss horizontal only)
No parameters
Filter emboss laplascian (Emboss > Emboss laplacian)
No parameters
Filter emboss vertical only (Emboss > Emboss vertical only)
No parameters
Filter gaussian blur (Blur > Gaussian blur…)
'horizRadius' 0.0+
'vertRadius' 0.0+
'lockAspect' [true, false]
Filter gaussianhighpass (Edge detection > Gaussian high pass…)
'blurAmount' 0.0+
Filter gaussiannoisereducer (Enhance > Gaussian noise reduction…)
'threshold' [0 to 255]
'windowsize' [0 to 10]
Filter height to normal (Edge detection > Height to normal map…)
'type' ['prewitt', 'sobol', 'simple']
'horizRadius' 0+
'vertRadius' 0+
'channelToConvert' [0 (Blue),
1 (Green),
2 (Red),
3 (Alpha)]
'lockAspect' [true, false]
'redSwizzle' [0 (X+),
1 (X-),
2 (Y+),
3 (Y-),
4 (Z+),
5 (Z-)]
'greenSwizzle' [0 (X+),
1 (X-),
2 (Y+),
3 (Y-),
4 (Z+),
5 (Z-)]
'blueSwizzle' [0 (X+),
1 (X-),
2 (Y+),
3 (Y-),
4 (Z+),
5 (Z-)]
Filter hsvadjustment (Adjust > HSV Adjustment…)
'type' [0 (Hue/Saturation/Value),
1 (Hue/Saturation/Lightness),
2 (Hue/Saturation/Intensity),
3 (Hue/Saturation/Luma),
4 (Blue Chroma/Red Chroma/Luma)]
'colorize' [true, false]
'compatibilityMode' [true, false]
'h' Type(0,1,2,3): Hue [-180 to 180]
Type(4): Yellow-Blue [-100 to 100]
's' Type(0,1,2,3): Saturation [-100 to 100]
Type(4): Green-Red [-100 to 100]
'v' Type(0): Value [-100 to 100]
Type(1): Lightness [-100 to 100]
Type(2): Intensity [-100 to 100]
Type(3,4): Luma [-100 to 100]
Filter invert (Adjust > Invert)
No parameters
Filter lens blur (Blur > Lens blur…)
'irisShape' ['Triangle', 'Quadrilateral (4)', 'Pentagon (5)', 'Hexagon (6)', 'Heptagon (7)', 'Octagon (8)']
'irisRadius' 0+
'irisRotation' [0 to 360]
Filter levels (Adjust > Levels…)
'blackvalue' [0 to 255]
'whitevalue' [0 to 255]
'gammavalue' [0.1 to 10.0]
'outblackvalue' [0 to 255]
'outwhitevalue' [0 to 255]
Filter maximize (Colors > Maximize Channel)
No parameters
Filter minimize (Colors > Maximize Channel)
No parameters
Filter motion blur (Blur > Motion blur…)
'blurAngle' [-360 to 360]
'blurLength' 0+
Filter noise (Other > Random noise…)
'level' [0 to 99]
'opacity' [0 to 99]
'seedThreshold' [0.0 to 1.0]
'seedRed' [0.0 to 1.0]
'seedGreen' [0.0 to 1.0]
'seedBlue' [0.0 to 1.0]
Filter normalize (Map > Normalize)
No parameters
Filter oilpaint (Artistic > Oilpaint…)
'brushSize' [1 to 5]
'smooth' [10 to 255]
Filter palettize (Map > Paletize…)
'palette' (string)
'colorspace' [0 (Lab),
1 (RGB)]
'ditherEnabled' [true, false]
'alphaEnabled' [true, false]
'alphaMode' [0 (Clip),
1 (Index),
2 (Dither)]
'alphaClip' [0.0 to 1.0]
'alphaIndex' [0 to n] (n = number of colors in selected palette)
'alphaDither/noiseSeed' 0+
'alphaDither/pattern' (string)
'alphaDither/patternValueMode' [0 (Auto),
1 (Lightness),
2 (Alpha)]
'alphaDither/spread' [0.0 to 1.0]
'alphaDither/thresholdMode' [0 (Pattern),
1 (Noise)]
'dither/colorMode' [0 (Per Channel Offset),
1 (Nearest Color)]
'dither/noiseSeed' 0+
'dither/offsetScale' [0.0 to 1.0]
'dither/pattern' (string)
'dither/patternValueMode' [0 (Auto),
1 (Lightness),
2 (Alpha)]
'dither/spread' [0.0 to 1.0]
'dither/thresholdMode' [0 (Pattern),
1 (Noise)]
Filter phongbumpmap (Map > Phong Bumpmap…)
'Azimuth0' [0 to 360] // Light Source 1
'Azimuth1' [0 to 360] // Light Source 2
'Azimuth2' [0 to 360] // Light Source 3
'Azimuth3' [0 to 360] // Light Source 4
'Inclination0' [0 to 90] // Light Source 1
'Inclination1' [0 to 90] // Light Source 2
'Inclination2' [0 to 90] // Light Source 3
'Inclination3' [0 to 90] // Light Source 4
'illuminantColor0' QColor // Light Source 1
'illuminantColor1' QColor // Light Source 2
'illuminantColor2' QColor // Light Source 3
'illuminantColor3' QColor // Light Source 4
'illuminantIsEnabled0' [true,false] // Light Source 1
'illuminantIsEnabled1' [true,false] // Light Source 2
'illuminantIsEnabled2' [true,false] // Light Source 3
'illuminantIsEnabled3' [true,false] // Light Source 4
'heightChannel' ['Blue', 'Green', 'Red']
'useNormalMapIsEnabled' [true,false]
'ambientReflectivity' [0.0 to 1.0]
'diffuseReflectivity' [0.0 to 1.0]
'diffuseReflectivityIsEnabled' [true,false]
'specularReflectivity' [0.0 to 1.0]
'specularReflectivityIsEnabled' [true,false]
'shinynessExponent' [1 to 200]
Filter pixelize (Artistic > Pixelize…)
'pixelWidth' [2 to 512]
'pixelHeight' [2 to 512]
Filter posterize (Artistic > Posterize…)
'pixelWidth' [2 to 512]
Filter raindrops (Artistic > Raindrops…)
'dropsize' [1 to 200]
'number' [1 to 500]
'fishEyes' [1 to 100]
'seed' 0+
Filter randompick (Other > Random pick…)
'level' [0 to 99]
'opacity' [1 to 500]
'windowsize' [1 to 100]
'seedH' 0+
'seedV' 0+
'seedThreshold' 0+
Filter roundcorners (Map > Round corners…)
note: works on (0,0,width,height) area only
'radius' [2 to 100]
Filter sharpen (Enhance > Sharpen)
No parameters
Filter smalltiles (Map > Small tiles…)
note: strange result if area is not image full area
'numberOfTiles' [2 to 5]
Filter threshold (Adjust > Threshold…)
'threshold' [0 to 255]
Filter waveletnoisereducer (Enhance > Wavelet Noise Reduced…)
'threshold' [0 to 255]
Not working filters
Filter emboss (Emboss > Emboss…)
FILTER DO NOT WORK PROPERLY FROM SCRIPT
Result do not match result obtained from Krita user interface
'depth' 0+
Filter halftone (Emboss > Emboss…)
FILTER DO NOT WORK PROPERLY FROM SCRIPT
Result do not match result obtained from Krita user interface (corrupted result)
Filter colortransfer (Colors > Color Transfer…)
FILTER DO NOT WORK PROPERLY FROM SCRIPT
'filename' (String) ==> not taken in account? or invalid property name?
Filter mean removal (Enhance > Mean removal)
FILTER DO NOT WORK PROPERLY FROM SCRIPT
Result do not match result obtained from Krita user interface (corrupted result)
Filter unsharp (Enhance > UNsharp mask)
FILTER DO NOT WORK PROPERLY FROM SCRIPT
Result do not match result obtained from Krita user interface
'amount' [0.0 to 99.99]
'halfSize' [0.0 to 99.99]
'threshold' [0 to 99]
'lightnessOnly' [true, false]
Filter wave (Other > Waves…)
FILTER DO NOT WORK PROPERLY FROM SCRIPT
Result do not match result obtained from Krita user interface
'horizontalshape' [0 (Sinusoidal),
1 (Triangle)]
'horizontalamplitude' [0 to 100]
'horizontalshift' [0 to 99]
'horizontalwavelength' [1 to 100]
'verticalshape' [0 (Sinusoidal),
1 (Triangle)]
'verticalamplitude' [0 to 100]
'verticalshift' [0 to 99]
'verticalwavelength' [1 to 100]
Not yet analyzed filters
Filter asc-cdl (Adjust > Slope, Offset, Power…)
FILTER NOT YET ANALYZED
Need to analyze code (and currently not able to understand user interface and results
)
Filter crosschannel (Adjust > Cross Channel adjustment curves…)
FILTER NOT YET ANALYZED
Filter gradientmap (Map > Gradient map…)
FILTER NOT YET ANALYZED
Need to analyze code (seems to use a XML content as parameter property?)
Filter indexcolors (Artistic > Index colors…)
FILTER NOT YET ANALYZED
'LFactor' ?
'aFactor' ?
'bFactor' ?
'reduceColorsEnabled' [true, false]
'colorLimit' [3 to 256]
'alphaSteps' [0 to 32]
'paletteGen' Array of Bytes
Ramps & Gradient steps (need to analyse how to build the byte array)
Filter perchannel
FILTER NOT YET ANALYZED
From which menu?
Grum999