Possible fix for setPixel