Toolkit: Pixel Bender
void evaluatePixel() float denominator = 0.0; pixel4 sum = pixel4(0.0); float radius = 2.0;
A blur involves sampling neighbor pixels and averaging them. Pixel Bender has a built-in function for sampling coordinates relative to the current pixel. pixel bender toolkit
dst = sum / denominator;