XDL TIP

XDL Tip 게시판입니다.  

*** XDL을 다운 받으신 후 테스트가 가능합니다. 

*** Tutorial을 이용해 다양한 기능을 구현해보시기 바랍니다.

[NCC] Static 함수를 이용한 다양한 좌표계 변환

작성자
pixoneer
작성일
2016-11-19 18:51
조회
993
          // Geographic->UTM 변환
            {
                XAngle angLon = new XAngle();
                XAngle angLat = new XAngle();
                angLon.deg = 127.1234;
                angLat.deg = 36.1234;
                int nZone = 0;
                XVertex2d pos = new XVertex2d();
                Xcc.WGP2UTM(angLon, angLat, ref pos, ref nZone);
            }

            // UTM->Geographic 변환
            {
                XVertex2d pos = new XVertex2d(434565, 4458652);
                XAngle angLon = new XAngle();
                XAngle angLat = new XAngle();
                int nZone = 52;
                Xcc.UTM2WGP(pos, nZone, ref angLon, ref angLat);
            }

            // UTM->MGRS 변환
            {
                XVertex2d pos = new XVertex2d(434565, 4458652);
                XAngle angLon = new XAngle();
                XAngle angLat = new XAngle();
                int nZone = 52;
                string strMGRS = "";
                Xcc.UTM2MGRS(pos, nZone, ref strMGRS);
            }

            // WGP->MGRS 변환
            {
                XAngle angLon = new XAngle();
                XAngle angLat = new XAngle();
                angLon.deg = 127.1234;
                angLat.deg = 36.1234;
                string strMGRS = "";
                Xcc.WGP2MGRS(angLon, angLat, ref strMGRS);
            }
            // MGRS->UTM 변환
            {
                XVertex2d pos = new XVertex2d();
                int nZone = 0;
                Xcc.MGRS2UTM("52SCE3112199266", ref pos, ref nZone);
            }

            // MGRS->WGP 변환
            {
                XVertex2d pos = new XVertex2d();
                XAngle lon = new XAngle();
                XAngle lat = new XAngle();
                Xcc.MGRS2WGP("52SCE3112199266", ref lon, ref lat);
            }

            // WGP->GEOREF(World Geographic Reference) 변환
            {
                XAngle angLon = new XAngle();
                XAngle angLat = new XAngle();
                angLon.deg = 127.1234;
                angLat.deg = 36.1234;

                int numDigit = 8;
                string strGEOREF = "";
                Xcc.WGP2GEOREF(angLon, angLat, ref numDigit, ref strGEOREF);
            }

            // GEOREF->WGP 변환
            {
                XAngle angLon = new XAngle();
                XAngle angLat = new XAngle();

                string strGEOREF = "WJHG07400740";
                Xcc.GEOREF2WGP(strGEOREF, ref angLon, ref angLat);
            }
전체 0