protected override bool BeforeDraw(GraphicsDisplay disp, RawPoint[] geoline, System.Windows.Point[] line) { Path p = new Path(geoline); Geometry geo = p.GeodesicBuffer(100000, GeoStar.Core.BufferCapType.eBufferFlatCap, 0.001); m_Sym.StartDrawing(disp); m_Sym.Draw(geo); m_Sym.EndDrawing(); disp.IncrementCanvasAction(); return(false); }
protected override void InnerDraw(GeoStarCore.geoDrawPhase drawPhase, GeoStarCore.IDisplay pDisplay, GeoStarCore.ITrackCancel pTrack) { if (m_TileList.Count == 0) { return; } List <QuadTile> vList = new List <QuadTile>(); lock (this) { vList.AddRange(m_TileList); } GeoStar.Core.SimpleFillSymbol sym = new GeoStar.Core.SimpleFillSymbol( System.Drawing.Color.Transparent, System.Drawing.Color.Red, 0.1f); sym.StartDrawing(pDisplay as GeoStar.Core.Display); GeoStar.Core.Envelope env = new GeoStar.Core.Envelope(); double xmin = 0, ymin = 0, xmax = 0, ymax = 0; GeoStar.Core.TextSymbol txt = new GeoStar.Core.TextSymbol(); GeoStar.Core.Point pt = new GeoStar.Core.Point(); txt.Width = 5; txt.Height = 5; txt.StartDrawing(pDisplay as GeoStar.Core.Display); foreach (var item in vList) { m_Pyramid.TileExtent(item.Level, item.Row, item.Col, ref xmin, ref ymin, ref xmax, ref ymax); env.put_Coords(xmin, ymin, xmax, ymax); sym.Draw(env); pt.put_Coords(xmin, (ymin + ymax) / 2); txt.Text = item.ToString(); txt.Draw(pt); } txt.EndDrawing(); sym.EndDrawing(); }