fix problem about image coordinates