diff --git a/src/c3nav/mapdata/render/svg.py b/src/c3nav/mapdata/render/svg.py index b611b3d6..6386a69c 100644 --- a/src/c3nav/mapdata/render/svg.py +++ b/src/c3nav/mapdata/render/svg.py @@ -86,7 +86,8 @@ class SVGRenderer: # shadows are directly calculated and added by the SVGImage class for altitudearea in geoms.altitudeareas: svg.add_geometry(bbox.intersection(altitudearea.geometry.difference(crop_areas)), - fill_color='#eeeeee', altitude=altitudearea.altitude) + fill_color='#eeeeee', altitude=altitudearea.altitude, + stroke_width=0.05, stroke_px=0.2, stroke_color='rgba(0, 0, 0, 0.15)') for color, areas in altitudearea.colors.items(): # only select ground colors if their access restriction is unlocked diff --git a/src/c3nav/mapdata/utils/svg.py b/src/c3nav/mapdata/utils/svg.py index eb3f92fa..6a879896 100644 --- a/src/c3nav/mapdata/utils/svg.py +++ b/src/c3nav/mapdata/utils/svg.py @@ -279,15 +279,20 @@ class SVGImage: if not geometry: return - if altitude is not None or elevation is not None: - if elevation is not None: - if elevation: - self.add_shadow(geometry, elevation) - else: - for other_altitude, other_geom in self.altitudes.items(): - self.add_shadow(geometry, altitude-other_altitude, clip_path=other_geom) + if False: + # old shadow rendering. currently needs too much resources + if altitude is not None or elevation is not None: + if elevation is not None: + if elevation: + self.add_shadow(geometry, elevation) + else: + for other_altitude, other_geom in self.altitudes.items(): + self.add_shadow(geometry, altitude-other_altitude, clip_path=other_geom) - self.clip_altitudes(geometry, altitude) + self.clip_altitudes(geometry, altitude) + else: + if elevation is not None: + self.add_shadow(geometry, elevation) element = self._create_geometry(geometry, attribs, cache_key=shape_cache_key)