/// <summary>
/// 根据数据集获取容差
/// </summary>
/// <param name="dataset"></param>
/// <returns></returns>
private double GetTolerance(IDataset dataset)
{
ISpatialReference sr = (dataset as IGeoDataset).SpatialReference;
ISpatialReferenceTolerance spatialReferenceTolerance = sr as ISpatialReferenceTolerance;
return spatialReferenceTolerance.XYTolerance;
//double fx = 0, fy = 0, uxy = 0.001;
//try
//{
// if (sr != null)
// {
// sr.GetFalseOriginAndUnits(out fx, out fy, out uxy);
// }
//}
//catch (Exception ex)
//{
// MessageBox.Show(ex.ToString());
// return 0.0;
//}
//uxy = 1 / uxy;
//return uxy;
}

注释部分是获取分辨率

05-11 17:57