scanned img processing fixed. Still need to solve crop problem