Filter Descriptions
MultiScale - Given an input image, MultiScale generates several progressively smaller versions of it. This is useful for Multi-Resolution Analysis, but can be used for many other things, such as generating Mip Maps for 3D Textures.
No Parameters
Convolve - This takes an input image, and a matrix, then emits a new image which is the convolution of the input image and the matrix. The matrix can be any size.
matrix:matrix ... the matrix to use
Rescale - Performs a high-quality rescaling operation. You can set aspect to true, which will preserve aspect ratio. The size parameter is taken as a string, for example: "50%x70%", or "50%", or "640x480".
aspect:true | false ... preserve aspect ratio
size:W%xH% | WxH | Size% ... width/height percentage, width/height pixels, or overall size percentage
HSB - Modifies the Hue, Saturation, and Brightness of an image.
h:hue (mappable) ... the hue rotation, -1 to 1 degrees (default 0)
s:saturation (mappable) ... the saturation amount, 1.0 for no change (default 1.0)
b:brightness (mappable) ... the brightness amount, 1.0 for no change (default 1.0)
Copy - Simply emits a copy of the input image.
No Parameters
Resample - Using a matrix as the 'sample grid', Resample consolidates groups of many pixels into one. The process is similar to Convolve, except the convolution matrix is slid over the image in large steps, as wide as the matrix itself. Each step will generate one pixel in the output image. This is useful for image processing, such as doing a high-pass filter while reducing the number of pixels.
matrix:matrix or vector:matrix ... specifies the matrix to use for resampling, using 'matrix:' guarantees a square matrix.
min:value ... minimum expected value after performing the matrix op (default 0.0)
max:value ... maximum expected value after performing the matrix op (default 1.0)
rotate:0 or 90 ... rotation of matrix
Levels - Similar to Photoshop's levels, this function allows you to set the black, mid, and white points on an image. This is much more flexible than simply using a brightness/contrast adjustment.
black:black point (mappable) ... new black point of the image, 0.0 to 1.0 (default 0.0)
mid:mid point / gamma - mid bias/gamma ... default 1.0
white:white point (mappable) ... new white point of the image, 0.0 to 1.0 (default 1.0)
Normalize - Scans the input image, finds the minimum and maximum pixel values, and scales everything in between so that the minimum = 0.0 (black), and the maximum = 1.0 (full-bright).
No Parameters
BoxBlur - A 2D blur kernel which is able to be modified while it's convolving the image itself. Some very nice effects can be made by driving the kernel width and/or height with a grayscale mask. Examples range from faked Depth-of-Field to texture synthesis.
width:width in pixels (mappable) ... box width in pixels (default 3.0)
height:height in pixels (mappable) ... box height in pixels (default 3.0)
iterations:loop count ... number of times to repeat the blur (for gaussian approximation)
WritePixels - This function takes an input image, and three mappable parameters -- Red Green and Blue. While the function runs, it applies the color at the input parameters to a copy of the image. This allows you to map arbitrary coordinate systems or 2D functions to an image, which is useful for generating procedural images from scratch -- but not necessarily operating on existing images.
red:red value (mappable) ... red
green:green value (mappable) ... green
blue:blue value (mappable) ... blue
Combine - A very useful function for compositing two images. Combine actually takes two images as input. The first (base) image is referenced by the standard "source" image parameter common to all functions. The second image is referenced by the "input" parameter. The 'operation' parameter is an expression of the form f(a,b)=..., resulting in c. The 'a' variable is the base image, the 'b' variable is the secondary input image. This expression's job is to composite 'a' and 'b' together in some way, to get 'c', which is written to the output image. The 'bias' parameter controls exactly how 'c' is written out. When 'bias' is at 0.5, it is in the middle, so only 'c' is written out. But, you may fade towards 'a' or towards 'b', by going towards 0.0 (a) or 1.0 (b). This makes for some nice effects, especially since the 'bias' parameter is mappable.
input:image or mapped value ... input pixel data for combining with source
operation:expression ... expression used to combine the two images, a and b, into a new image. a is source="foo", b is input:bar
bias:result bias (mappable) ... shifts the output between a, b, and the output c. bias 0.5 is 100% c. 0.0 is 100% a, 1.0 is 100% b;
fit:true | false ... determines if the input image should be fit to the same size as the source image
pos:two comma-separated integers ... determines the offset of the input image relative to 0,0 on the source image.
FileReadImage - Simply loads a file from disk, and spits out an image. Supported file formats are too numerous to list, but include PSD, PDF, SVG, JPEG, JPEG2000, PNG, Targa, TIFF, GIF, XCF, BMP, SGI, DXT, and so on ...
file:String ... the filename relative to where Atom is running
FileWriteImage - Saves one or more images to files. If FileWriteImage's source is a function which has generated more than one image, FileWriteImage will write each one by incrementally numbering the filename. If you give 'picture.png' as the base name, and FileWriteImage is connected to a source with multiple images, it will write out 'picture0.png', 'picture1.png', 'picture2.png', etc. If FileWriteImage's source has only generated one image, then it will write out 'picture.png'.
file:String ... the base filename to save to.
HoughTransform - Performs a Forward Hough Transform on the input image. Only the first image from the source is used, currently. A Hough Transform is a type of image analysis technique which tries to find straight lines in sets of points or pixels. It essentially does this by shooting rays across the image, sampling pixel values along the ray, and accumulating these values in 'bins' of special attributes: the ray's rotation to get to that pixel, and the ray's distance from the origin of the image. If the majority of light or dark values (or red or puce) winds up in the same bin, then whatever rotation and distance that bin represents shows that those values are all resting on the same line. Useful applications are Artificial Intelligence (Machine Vision), Astronomy (searching thousands of huge images for faint comet trails), 2D and 3D optimization, and, well, more.
angles:Integer ... the number of slices to sample through the image to find collinear points. Default is 64.
InverseHoughTransform - Performs an Inverse Hough Transform on an input image. This is basically the exact opposie of the Forward Hough Transform. If you feed InverseHoughTransform and image generated by HoughTransform, then you will have the original image back ... sort-of. The Hough Transform is a lossy transform, so what you'll end up are lots of infinite lines approximating the original image.
width:Integer ... the width of the output image
height:Integer ... the height of the output image
size:Image (optional) ... if this attribute is defined, then width and height will be taken from the referenced Image
PixelOp - Applies an expression to every pixel in an image one channel at a time; the 'operation' parameter expects an expression in the form f(a)=..., where the variable 'a' is the incoming pixel value per channel. The result of this expression is written to the output image.
operation:expression ... expression used to modify each pixel, for example, the expression "f(a)={1.0 - a}" inverts the image..
PixelMatrixOp - Similar to PixelOp, but much more powerful. PixelMatrixOp is essentially a programmable convolution. The 'matrix' parameter is the matrix used for the convolution. However, you have full control over how each sample in the matrix is accumulated with the 'sigma' parameter. The 'sigma' parameter expects a function in the form f(a,b,n)=..., where the variable 'a' is fed back from the last 'sigma' expression evaluation, 'b' is the new sample created by multiplying the matrix and the image under it, and 'n' is the total number of elements in the current matrix, to make normalization simpler. After 'sigma' is run over an entire matrix, the other expression parameter, 'operation', is used to determine how to blend the final result of 'a', with the original pixel at the center of the matrix. After that expression evaluates, the matrix is moved one pixel over and the process repeats until all pixels have been touched. Example uses: finding local maxima and minima, programmable 'shading' operations, implementing more advanced image processing ops, etc.
sigma:expression ... this is in the form f(a,b,n)=..., where 'a' is a color which is continuously fed back over the span of the matrix, 'b' is the color of the image * the matrix, and 'n' is the number of elements in the matrix.
matrix:matrix ... specifies the matrix to use for defining the neighborhood & multiplying against the image for 'b' in sigma
operation:expression ... this expression, of the form f(a,b)=..., defines how to mix a and b back together to set the final image color at the current pixel.
Window - Generates multiple images from a single image. Each generated image only has a part of the original image, so we call it 'windowed' because certain parts of each resulting image aren't visible. Why would anyone do this? Well suppose you have a function that is telling you how bright an image is. The problem is, the function is telling you how bright the WHOLE image is, overall. It can't tell you how bright any one area is. Instead of changing the algorithm, you window the image into several more images. One image may have a small 128x128 square in the upper left, taken from the original image, while the rest is black. If you ran the brightness function on this particular image, the function would be telling you how bright that 128x128 square in the upper-left is. So, windowing simply takes a large chunk of data, and breaks it up into meaningful chunks, so that some other function can work with them.
No Parameters (Yet)
Filter Definitions
MultiScale Image source
Convolve Image source Matrix matrix
Rescale Image source Boolean aspect String size
HSB Image source Mapped Float h Mapped Float s Mapped Float b
Copy Image source
Resample Image source (Matrix matrix | Matrix vector) Float min Float max Float rotate
Levels Image source Mapped Float black Float mid Mapped Float white
Normalize Image source
BoxBlur Image source Mapped Float width Mapped Float height Integer iterations
WritePixels Image source Mapped Float red Mapped Float green Mapped Float blue
Combine Image source (Image input | Mapped Float input) Expression operation Mapped Float bias Boolean fit Boolean aspect String pos
FileReadImage String filename
FileWriteImage String filename
HoughTransform Image source Integer angles
InverseHoughTransform Image source (Integer width Integer height | Image reference_size)
PixelOp Image source Expression operation
PixelMatrixOp Image source Expression sigma Matrix matrix Expression operation
Window