//元座標値 IPoint[] pPointSource = new PointClass[4]; pPointSource[0] = new PointClass(); pPointSource[0].PutCoords(13411566.749205, 392094.84965); //補正座標値 IPoint[] pPointTarget = new PointClass[4]; pPointSource[0] = new PointClass(); pPointTarget[0].PutCoords(13411793.050983, 392030.191999); //元座標と補正座標でPointCollectionを作成 IPointCollection pPointCollectionSource = new MultipointClass(); pPointCollectionSource.AddPoint(pPointSource[0]); IPointCollection pPointCollectionTarget = new MultipointClass(); pPointCollectionTarget.AddPoint(pPointTarget[0]); object pResidual; double dblRMS; IPolynomialXform pPolynomialXform = new PolynomialXformClass(); pPolynomialXform.DefineFromControlPoints(pPointCollectionSource, pPointCollectio //第3引数で何次多項式変換かを指定(1-3) pPolynomialXform.CheckResidualRMS(pPointCollectionSource, pPointCollectionTargetormDirection.esriTransformForward,out pResidual,out dblRMS); double[,] dblArray = (double[,])pResidual; //二次元配列にキャスト //配列から残差を取得(1次元目の要素がレコード、2次元目の配列が順に 残差_x、残差_y, 残差) for(long i= 0;i == dblArray.GetLength(0);++i) { Console.WriteLine(dblArray[i, 0] +"," + dblArray[i, 1] + "," + dblArray[i, 2]); }
ラスターのジオリファレンス(多項式変換)残差・RMS エラーの取得
2016/9/1 (木)