public void mapCompute() { //声源离散 Layer sourceLayer = getSource(); PathSearch pathbean = new PathSearch(); //接收点离散 Queue <Geometry> receiveList = PolygonPartition.staticPartition(m_gridSize, m_computationalGrid, m_receiveHeight); //障碍物优化 DataSource barrierSource = Ogr.Open(m_barrierPath, 0); Layer barrierLayer = barrierSource.GetLayerByIndex(0); Geometry receivePoint = null; Geometry sourcePoint = null; Feature sourceFeature = null; Geometry[] pathList = null; List <float[]> sourceLineList = new List <float[]>(); //路径计算,循环接收点 while (receiveList.Count > 0) { //声源点和接收点 receivePoint = receiveList.Dequeue(); sourceLayer.SetSpatialFilter(receivePoint.Buffer(m_range, 30)); //循环声源点 while ((sourceFeature = sourceLayer.GetNextFeature()) != null) { sourcePoint = sourceFeature.GetGeometryRef(); //获取路径 pathList = pathbean.getPath(barrierLayer, sourcePoint, receivePoint, m_range); } } //衰减计算 }