Changeset 21372


Ignore:
Timestamp:
11/12/16 19:35:38 (8 years ago)
Author:
Eric.Larour
Message:

CHG: better identification of line vs polygon

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/branches/trunk-larour-NatGeoScience2016/src/m/exp/exp2shp.m

    r18213 r21372  
    2424                elseif length(shp(1).x) < 3
    2525                        geometry = 'Line';
    26                 else
    27                         geometry = 'Polygon';
     26                else
     27                        if (shp(1).x(end)==shp(1).x(1) && shp(1).y(end)==shp(1).y(1)),
     28                                geometry = 'Polygon'
     29                        else
     30                                geometry = 'Line'
     31                        end
    2832                end
    2933        end
Note: See TracChangeset for help on using the changeset viewer.