我们正在考虑通过60天试用版从MapX4.5/Vertical Mapper3升级到MapXtreme2008。我们无法使用MapXtreme导入Ascii/网格文件。我们已经尝试在MapXtreme论坛上发帖了,但到目前为止还没有回应。谢谢。
http://en.wikipedia.org/wiki/ESRI_grid
发布于 2010-07-01 14:56:28
但是,您可以指定插值器以及如何聚合点。
下面是一个代码示例:
//outTable and usaCapsTable is given
// Create the Interpolator
InverseDistanceWeightedInterpolator idw = new InverseDistanceWeightedInterpolator();
// Set the values
idw.SearchRadius = 100; // in pixels
idw.Exponent = 2;
idw.MinPoints = 1;
idw.MaxPoints = 1000;
// Create a GridCreator and pass in the table to use for input, the column holding the data, the interpolator.
MapInfo.Raster.GridCreatorFromFeatures cg = new GridCreatorFromFeatures(usaCapsTable, "Pop_1990", idw, outTable);
cg.CellWidth = new Distance(12.9, DistanceUnit.Mile);
Inflection[] infl = new Inflection[5];
infl[0] = new Inflection(8000, Color.Blue);
infl[1] = new Inflection(121000, Color.Aquamarine);
infl[2] = new Inflection(199000, Color.Green);
infl[3] = new Inflection(298000, Color.Yellow);
infl[4] = new Inflection(980000, Color.Red);
// Create a grid Style to use and pass in the onflection points.
cg.GridStyle = new GridStyle(infl, true, Color.White, true);
// Now check if there is a current selection. If yes then use the objects to clip the grid against.
if ((MapInfo.Engine.Session.Current.Selections.DefaultSelection.Count > 0) &&
MapInfo.Engine.Session.Current.Selections.DefaultSelection[0].Count > 0)
{
MapInfo.FeatureProcessing.FeatureProcessor fp = new MapInfo.FeatureProcessing.FeatureProcessor();
Feature clip = fp.Combine(MapInfo.Engine.Session.Current.Selections.DefaultSelection[0]);
cg.ClippingGeometry = clip.Geometry;
}
else
{
cg.ClippingGeometry = null;
}
// Create the grid file.
cg.CreateGrid();希望这能有所帮助
玛拉
https://stackoverflow.com/questions/2747143
复制相似问题