示例#1
0
 private float getStreetWidth(int zoom, EdgeProperties p) {
   float width;
   if (p.getType() != HighwayType.Tertiary
       && p.getType() != HighwayType.Unclassified
       && p.getType() != HighwayType.Residential) {
     width = (HighwayType.values().length - p.getType().ordinal()) * 6 / (20f - zoom) + 2;
   } else {
     width = Math.max(28 - (20 - zoom) * 5, 1);
   }
   return width;
 }