// 'add the risk vector layer
sharpmap. layers. vectorlayer windarrowlayer = new sharpmap. layers. vectorlayer ("Wind arrow");
windarrowlayer. datasource = (map. layers [3] As sharpmap. layers. vectorlayer ). datasource;
windarrowlayer. style. symbolscale = 0.8f;
windarrowlayer. SRID = 4326;
windarrowlayer. maxvisible = 15;
sharpmap. rendering. thematics. customtheme itheme = new sharpmap. rendering. thematics. customtheme (getwindarrowstyle);
windarrowlayer. theme = itheme;
map. layers. add (windarrowlayer);
Private Static sharpmap. Styles. vectorstyle getwindarrowstyle (sharpmap. Data. featuredatarow row)
{
Sharpmap. Styles. vectorstyle S = new sharpmap. Styles. vectorstyle ();
S. Fill = new solidbrush (color. Green );
S. symbol = getwindarrow (ROW );
Return S;
}
Private Static bitmap getwindarrow (sharpmap. Data. featuredatarow row)
{
// replace polygon with a center point (this is where we place the symbol
row. geometry = geometryfactory. createpoint (
row. geometry. envelopeinternal. centre. x,
row. geometry. envelopeinternal. centre. y);
Random Rand = new random ();
Int size = 50;
Bitmap B = new Bitmap (size, size );
Graphics G = graphics. fromimage (B );
Wmplot. clswindarrow. chyawsview (G, new point (25, 25), 10, 90 );
G. Dispose ();
Return B;
}