Changeset 24744
- Timestamp:
- 04/27/20 12:10:28 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/m/coordsystems/gdalinfo.m
r22932 r24744 9 9 %first, get pixel size: 10 10 [s,r]=system(sprintf('gdalinfo %s | grep "Pixel Size"',imagename)); 11 if s, error('gdalinfo error message: could not run system command gdalinfo '); end11 if s, error('gdalinfo error message: could not run system command gdalinfo to find pixel size'); end 12 12 d=sscanf(r,'Pixel Size = (%g,%g)'); 13 13 info.dx=abs(d(1)); info.dy=abs(d(2)); … … 15 15 %get upper left: 16 16 [s,r]=system(sprintf('gdalinfo %s | grep "Upper Left"',imagename)); 17 if s, error('gdalinfo error message: could not run system command gdalinfo '); end17 if s, error('gdalinfo error message: could not run system command gdalinfo to find upper left'); end 18 18 d=sscanf(r,'Upper Left ( %g,%g) %s'); 19 19 info.xmin=d(1); … … 22 22 %get lower right: 23 23 [s,r]=system(sprintf('gdalinfo %s | grep "Lower Right"',imagename)); 24 if s, error('gdalinfo error message: could not run system command gdalinfo '); end24 if s, error('gdalinfo error message: could not run system command gdalinfo to find lower right'); end 25 25 d=sscanf(r,'Lower Right ( %g,%g) %s'); 26 26 info.xmax=d(1); … … 29 29 %Size: 30 30 [s,r]=system(sprintf('gdalinfo %s | grep "Size is"',imagename)); 31 if s, error('gdalinfo error message: could not run system command gdalinfo '); end31 if s, error('gdalinfo error message: could not run system command gdalinfo to find size'); end 32 32 d=sscanf(r,'Size is %g, %g'); 33 33 info.nx=d(1);
Note:
See TracChangeset
for help on using the changeset viewer.