Complete rewrite of the GraphicsMagick middleware

+ Added the process() method
+ Added test cases