Change conversion to Bitmap ref
Use Reference<Bitmap> instead of Bitmap *