add writeBitmap etc