Commit ea630c824a55405573fcd20f1aea0668113a1d0c

Authored by Daniel Bourgault
1 parent 47ace827
Exists in master

Small change in g_proj_GCP to make sure that the longitude go from -180 t0 180.

Showing 1 changed file with 3 additions and 1 deletions   Show diff stats
src/g_rect/g_proj_GCP.m
... ... @@ -41,7 +41,9 @@ for i = 1:n_gcp
41 41 proj_factor = H/(H-h_gcp(i));
42 42 new_range = range*proj_factor;
43 43 [lon_gcp(i),lat_gcp(i),a21] = m_fdist(LON0,LAT0,a12,new_range);
44   - lon_gcp(i) = lon_gcp(i) - 360;
  44 + if lon_gcp(i) > 180
  45 + lon_gcp(i) = lon_gcp(i) - 360;
  46 + end
45 47 else
46 48 % If there's no elevation, then there's nothing to do.
47 49 lon_gcp(i) = lon_gcp0(i);
... ...