File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed
Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -191,6 +191,8 @@ def main(
191191 lon_min_idx = 20 ,
192192 lon_max_idx = 70 ,
193193 resolution = resolution ,
194+ water_color = None ,
195+ land_color = None ,
194196 )
195197
196198 LOG .info ("Drawing Breakwater map" )
Original file line number Diff line number Diff line change @@ -143,6 +143,8 @@ def __init__(
143143 resolution : RESOLUTION = "h" ,
144144 draw_arrows_length : float = DEFAULT_ARROW_LENGTH ,
145145 draw_arrows_stride : int = 3 ,
146+ water_color : str | None = "lightcyan" ,
147+ land_color : str | None = "wheat" ,
146148 ) -> None :
147149 """
148150 Map plotting wave height as a colormap and wave direction with arrows.
@@ -165,6 +167,8 @@ def __init__(
165167 draw_arrows_length: Length of arrows.
166168 draw_arrows_stride: Create an arrow for every multiple of `stride`
167169 indicies.
170+ water_color: Color of water.
171+ land_color: Color of land.
168172 """
169173
170174 # NOTE: not sure why this offset is needed, but looks better with it
@@ -198,6 +202,11 @@ def __init__(
198202 )
199203 map .drawcoastlines ()
200204
205+ if water_color is not None :
206+ map .drawmapboundary (fill_color = water_color )
207+ if land_color is not None :
208+ map .fillcontinents (color = land_color )
209+
201210 if self .wave_height_ft is not None :
202211 self .img = map .imshow (
203212 self .wave_height_ft [0 ],
You can’t perform that action at this time.
0 commit comments