Work with binary images