Refactor images for inonly/inout