ImageMagick extension for PHP.
Almost all of the functions in the library have an example at www.phpimagick.com, where you can see the example code to call the function, as well as the generated image or output.
Documentation needs a lot of work. There is an online editor here: https://edit.php.net/ Contributions are more than welcome.