Fixing encoding for coordinates