Some algorithms for modifying images. Those implementations are only useful if you want to learn about the algorithms and see an actual working easy readable implementation. For real image manipulation I suggest to use ezcImageConversion from the eZ Components project.
I do not recommend to use the filters, because they are incredible slow. Another code snippet, which perhaps is usefull for educational purposes. Download: piclib.php (10.83 kB)