Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Your code only assigns the first pixel, you need to iterate to assign all pixels. Don't forget to call syncPixels() to push the updates to the pixel cache.