`
阿尔萨斯
  • 浏览: 4165846 次
社区版块
存档分类
最新评论

SharpGIS博客翻译2005年6月:使用.NET来渲染地图

 
阅读更多

Rendering maps using .NET

【原文】: http://www.sharpgis.net/2005/06/10/RenderingMapsUsingNET.aspx

【翻译】:小粟 日期:<chsdate year="2007" month="2" day="11" islunardate="False" isrocdate="False" w:st="on"><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: Verdana">2007</span><span style="FONT-SIZE: 10.5pt; mso-ascii-font-family: Verdana; mso-hansi-font-family: Verdana"><font face="宋体">年</font></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: Verdana">2</span><span style="FONT-SIZE: 10.5pt; mso-ascii-font-family: Verdana; mso-hansi-font-family: Verdana"><font face="宋体">月</font></span><span lang="EN-US" style="FONT-SIZE: 10.5pt; FONT-FAMILY: Verdana">23</span><span style="FONT-SIZE: 10.5pt; mso-ascii-font-family: Verdana; mso-hansi-font-family: Verdana"><font face="宋体">日</font></span></chsdate>

Last night I was, just for fun, fooling around with creating my own mapserver engine using native .NET and GDI+ methods, combined with a PostGreSQL/PostGIS database. Until now I got Points, Labels and Line layertypes implemented.
I didn’t expect much of the speed, but it turned out that GDI+’s drawing methods and anti-aliasing rendering combined with .NETs automatic connection pooling provided me with an ultra fast map render engine. And just by exposing LineStyles as System.Drawing.Pen you get a vast amount of options for customizing the look of the rendered output. And it even looks great! I’m all ecstatic about the result, and will probably follow this further with more geometry types and additional data-providers (shapefile, Oracle etc). I’ll post some results here later.

使用.NET来渲染地图

昨天晚上,纯粹是为了好玩,我使用本地.NETGDI+方法来创建自己的地图服务引擎,使用的数据库是PostGreSQL/PostGIS。现在,我实现了点、注记和线图层的绘制。

当时我并没有怎么考虑速度的问题,不过实践表明,GDI+的绘制方法和基于.NET自动连接池反走样绘制技术给我提供了一个足够快的地图绘制引擎。并且,通过基于System.Drawing.Pen的线条样式定义,可以得到很多对绘制进行定制的选项,而它们的显示效果也很不错。我对它完全着迷了,所以有可能将对此例子增加更多的几何类型和数据类型(shapefile, Oracle等等),并发布到这里。

Rendering maps using .NET - Part II

I promised some screendumps from my PostGIS/.NET based MapEngine, so here it is. Nicely packed into a small workspace manager:

这是我的基于PostGIS/.NET的地图引擎的一些屏幕输出,它们很好地包裹在一个小的工作区管理器中:

<shapetype id="_x0000_t75" coordsize="21600,21600" o:spt="75" o:preferrelative="t" path="m@4@5l@4@11@9@11@9@5xe" filled="f" stroked="f"><stroke joinstyle="miter"></stroke><formulas><f eqn="if lineDrawn pixelLineWidth 0"></f><f eqn="sum @0 1 0"></f><f eqn="sum 0 0 @1"></f><f eqn="prod @2 1 2"></f><f eqn="prod @3 21600 pixelWidth"></f><f eqn="prod @3 21600 pixelHeight"></f><f eqn="sum @0 0 1"></f><f eqn="prod @6 1 2"></f><f eqn="prod @7 21600 pixelWidth"></f><f eqn="sum @8 21600 0"></f><f eqn="prod @7 21600 pixelHeight"></f><f eqn="sum @10 21600 0"></f></formulas><path o:extrusionok="f" gradientshapeok="t" o:connecttype="rect"></path><lock v:ext="edit" aspectratio="t"></lock></shapetype><shape id="_x0000_i1025" style="WIDTH: 370.5pt; HEIGHT: 270pt" o:button="t" alt="" type="#_x0000_t75"><imagedata o:href="http://www.sharpgis.net/content/binary/SharpMap20050612.gif" src="file:///C:/DOCUME~1/ADMINI~1/LOCALS~1/Temp/msohtml1/01/clip_image001.png"></imagedata></shape>




<iframe align="center" marginwidth="0" marginheight="0" src="http://www.zealware.com/csdnblog.html" frameborder="0" width="728" scrolling="no" height="90"></iframe>
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics