Mastering GLSL in TouchDesigner, Lesson 11: Convolution Kernels

In this lesson of Mastering GLSL in TouchDesigner, we explore convolution kernels, a powerful technique for image filtering that allows for effects like sharpening, edge detection, embossing, and Gaussian blur. You’ll learn how convolution matrices modify pixel neighborhoods and how to implement multi-pass filtering for dynamic effects.

๐Ÿ“Œ Key Topics Covered:
โœ… Understanding convolution kernels and how they alter images
โœ… Implementing sharpening, edge detection, and motion blur
โœ… Using mipmaps and textureLod() for efficient sampling
โœ… Applying multiple shader passes for more complex effects

๐ŸŽจ Exercises & Challenges:
๐Ÿ› ๏ธ Implement a custom convolution kernel from scratch
๐Ÿ› ๏ธ Build a CRT effect with vignette, scanlines, and chromatic aberration
๐Ÿ› ๏ธ Create a unique effect by combining multiple filtering techniques

Explanation of kernels with some good illustrations: https://medium.com/@timothy_terati/image-convolution-filtering-a54dce7c786b
Interactive convolution kernel explorer: https://setosa.io/ev/image-kernels/

Find me online:
๐Ÿ”น Project Files & Patreon: https://www.patreon.com/water__shed
๐Ÿ”น Portfolio: https://www.lakeheckaman.com
๐Ÿ”น Instagram: https://instagram.com/lake_heckaman

00:00 – Start
00:04 – Intro: Advanced Image Filters with GLSL
01:08 – Image Convolution Kernel
09:49 – Implementing kernels in GLSL
12:11 – Mipmaps
16:39 – Convolve TOP
17:56 – Begin TouchDesigner Examples
19:08 – TextureLOD
22:36 – Edge Detection (Sobel Filter) in GLSL
27:33 – Sharpen Filter
31:30 – Emboss
32:34 – Barrel Blur GLSL TouchDesigner
34:24 – Exercises

About The Author