I have already taken a look at this question: SO question and seem to have implemented a very similar technique for replacing a single color including the alpha values:
The Pythonware PIL online book chapter for the Image module stipulates that putpixel() is slow and suggests that it can be sped up by inlining. Or depending on PIL version, using load() instead.