removed image encoding