The documentation for imageSurfaceGetPixels :: Storable e => Surface -> IO (SurfaceData Int e)
"If modifying an image through Haskell's array interface is not fast
enough, it is possible to use unsafeRead and unsafeWrite which have
the same type signatures as readArray and writeArray. Note that these
are internal functions that might change with GHC."
I cannot find "unsafeRead" or "unsafeWrite" in the MArray interface.
My problem is that MArray.writeArray is indeed incredibly slow. Is there a way that a speed-up could be added? Perhaps a Data.Vector.Storable-like access?