09 2013 档案
摘要:1 public void CreateTxt(Vector3d[] Points) 2 { 3 if (Points.Length == 0) return; 4 string dirname = Path.Combine(WorldSettings.StartupDirectory, @"TempPoints"); 5 DirectoryInfo dir = new DirectoryInfo(dirname); 6 if (!dir.Exists) 7 ...
阅读全文
摘要:局部平面坐标 平移纠正到常用平面坐标系下的坐标 转换后的地理坐标采用两种方法实现局部平面坐标到地理坐标系的转换:1.直接进行配准纠正(需要多个控制点,即转换之后点对应的地理坐标);2.平移转换纠正方法(需要一个控制点);方法1具体步骤如下:1.选择控制点,准备配准txt文件; 选择多个控制点,并找到其原始坐标和对应的经纬度坐标。 2. 用ArcMap中的“空间校正”工具条进行配准; 矢量数据用“空间校正”,栅格数据用“地理配准” 首先,在“编辑器”中开始编辑, 然后,在“空间校正”中找到“连接线”——“打开连接线文件”, 打...
阅读全文
摘要:1 private void AddLineElement(IPolyline polyline) 2 { 3 try 4 { 5 IPolyline pPolyline = polyline; 6 IRgbColor pLineRgbColor = null; 7 ISimpleLineSymbol pSimpleLineSymbol = null; 8 ILineElement pFillShap...
阅读全文
摘要:1 private void AddPointElement(IPoint pPoint) 2 { 3 if (pPoint != null) 4 { 5 IElement pElement = null; 6 IRgbColor pColor = new RgbColorClass(); 7 pColor.Green = 255; 8 9 double pSize = Math.Round(7200...
阅读全文
摘要:在Program.cs中添加ESRI.ArcGIS.RuntimeManager.Bind(ESRI.ArcGIS.ProductCode.EngineOrDesktop);如下1 static void Main()2 {3 Application.EnableVisualStyles();4 Application.SetCompatibleTextRenderingDefault(false);5 6 ESRI.ArcGIS.RuntimeManager.Bind(ESRI.ArcGIS.Produc...
阅读全文
摘要:添加引用ESRI.ArcGIS.Carto1.获取图层1 IGeoFeatureLayer pFtrLayer = m_pLayer as IGeoFeatureLayer;View Code 2.初始化标注属性集合1 IAnnotateLayerPropertiesCollection pAnnoProps = pFtrLayer.AnnotationProperties;2 pAnnoProps.Clear();View Code 3.选择要标注的属性字段1 ILabelEngineLayerProperties item = new LabelEngineLayerPropertiesC
阅读全文
摘要:添加引用ESRI.ArcGIS.DataManagementTools1.获取要定义和要转换的投影1 IWorkspaceFactory wsf = new ShapefileWorkspaceFactoryClass();2 IWorkspace ws = wsf.OpenFromFile(strProjPath,0);3 IFeatureClass fc = (ws as IFeatureWorkspace).OpenFeatureClass("路中心线"); 4 ProSpaRef = (fc as IGeoDataset).SpatialReference;5 I.
阅读全文
摘要:第一步:根据鼠标点击处的点,找到被选中的要素 1 public IFeature Find2(IPoint pPoint) 2 { 3 ITopologicalOperator pTopoOpe = pPoint as ITopologicalOperator; 4 double dis = m_pMapControl.ActiveView.ScreenDisplay.DisplayTransformation.FromPoints(5); 5 if (dis < 0.01) 6 ...
阅读全文
浙公网安备 33010602011771号