WIP: pointer casting update in ReadWriteImage