ï¼2014/3/17ãwindows7ã¨ææ°ã®GDALã§åããªããã°ããã£ãã®ã§ä¿®æ£ãã¾ãããï¼
é»åå°å½¢å³25000ï¼å®å½¢å³éçï¼ãgdalã使ã£ã¦geotiffã«ãã¦ãã£ã¤ããæ¹æ³ãç´¹ä»ãã¾ãããªã³ããã³ãçã使ãã°å¥½ããªå³éã§è³¼å ¥ã§ãã¾ãããåºãç¯å²ãå©ç¨ãããå ´åãªã©ã«ã©ããããã ãå¢çé¨åã®é»æ ç·ã¯è¥å¹²æ®ãã¾ãã
1.è³¼å ¥
http://dkgd.gsi.go.jp/dkgx/page1.htm
ããããè³¼å
¥ãå®å½¢å³éçã®TIFFãé¸æãã¾ããã¾ã¡ãããªãããã«ã
2.ãã¼ã¿æ´ç
ãã¦ã³ãã¼ãããç»åã1次ã¡ãã·ã¥ãã©ã«ããã¨ã«ã¾ã¨ãã¦ãKANRIãã¡ã¤ã«ã¨ã¹ã¯ãªãããã¡ã¤ã«ã1次ã¡ãã·ã¥ãã©ã«ãã¨åãé層ã«ããã¾ãããã¡ã¤ã«åã以ä¸ã®ããã«ãäºæ¬¡ã¡ãã·ã¥çªå·.tifããäºæ¬¡ã¡ãã·ã¥çªå·.tfwãã«å¤æ´ãã¾ãã
|-é»åå°å½¢å³å¤æ.vbs(ãã®ãã¨ä¿åããã¹ã¯ãªãã) |-KANRI2KN.CSV |-5539-553935.tif | -553935.tfw | -553925.tif | -553925.tfw |-5742-574242.tif | -574242.tfw | -574343.tif | -574243.tfw
KANRIãã¡ã¤ã«ã¯åã種é¡ã§ä¸èº«ãã¾ã¨ãã¾ããããã¹ãã¨ãã£ã¿ã§CSVãéãã¦ãä¸ã¤ã®ãã¡ã¤ã«ã«ã³ãããã¾ãã
ï¾ï½§ï½²ï¾å,æ¬å³ã»åå³ï¾ï¾ï½¸ï¾,対å¿ããå°å½¢å³ã®å³å,対å¿ããå°å½¢å³ã®å³åï¼èªã¿ï¼,å°å½¢å³ï½ºï½°ï¾ï¾,å·æ°,åºæ¬æ¸¬é,æ¹æ¸¬,ä¿®æ£,é¨åä¿®æ£,空ä¸åç,ç¾å°èª¿æ»,çºè¡å¹´ææ¥,å³éåé çµç·¯åº¦å·¦ä¸ç·¯åº¦,å,ç§,å·¦ä¸çµåº¦,å,ç§,å·¦ä¸ç·¯åº¦,å,ç§,å·¦ä¸çµåº¦,å,ç§,å³ä¸ç·¯åº¦,å,ç§,å³ä¸çµåº¦,å,ç§,å³ä¸ç·¯åº¦,å,ç§,å³ä¸çµåº¦,å,ç§,å³éåé UTM(Måä½)å·¦ä¸E,å·¦ä¸N,å·¦ä¸E,å·¦ä¸N,å³ä¸E,å³ä¸N,å³ä¸E,å³ä¸N,å³éåé ï¾ï½§ï½²ï¾åº§æ¨å·¦ä¸P,å·¦ä¸L,å·¦ä¸P,å·¦ä¸L,å³ä¸P,å³ä¸L,å³ä¸P,å³ä¸L,2次ï¾ï½¯ï½¼ï½ï½ºï½°ï¾ï¾,延伸ãã©ã°å·¦ä¸,ä¸,å³ä¸,å³,å³ä¸,ä¸,å·¦ä¸,å·¦,調製æ¥,ç£æ°åè§è¥¿åï¼åº¦ï¼,å 553935,1,äºåéæ¹,ãããã,,,,,,,,,,37,0,0,139,37,30,36,55,0,139,37,30,36,55,0,139,45,0,37,0,0,139,45,0,377655,4095756,377521,4086511,388656,4086358,388777,4095603,490,802,486,8198,9394,8198,9389,802,553935,0,0,0,0,0,0,0,0,20140109,7,20 553925,1,å·æ²»,ããã,,,,,,,,,,36,55,0,139,37,30,36,50,0,139,37,30,36,50,0,139,45,0,36,55,0,139,45,0,377521,4086511,377388,4077266,388535,4077113,388656,4086358,486,802,481,8198,9399,8198,9394,802,553925,0,0,0,0,0,0,0,0,20140109,7,20
3.ã¹ã¯ãªããã§å¤æ
以ä¸ã®ã¹ã¯ãªããããé»åå°å½¢å³å¤æ.vbsãã¨ããååã§ä¿åãã¦ãGDALãã¤ã³ã¹ãã¼ã«ããOSGeo4Wã®ã³ãã³ãããã³ããä¸ã§å®è¡ãã¾ãã
å¤æå
ã®å³éã®UTMã¾ã¼ã³ã«å¾ã£ã¦s_epsgã®é¨åãæ¸ãæãã¦ãã ããã
æå½±å¤æãããepsgã³ã¼ãã«å¾ã£ã¦ãt_epsgã®é¨åãæ¸ãæãã¦ãã ããã
epsgã³ã¼ãã«ã¤ãã¦ã¯ãã¡ããåè
http://d.hatena.ne.jp/tmizu23/20091215/1260868350
ï¼é»åå°å½¢å³å¤æ.vbs 0 (KANRI2KN.CSVã®å¤æ) ï¼é»åå°å½¢å³å¤æ.vbs 2 (tmpC*.vrtããã¼ã¸ï¼æå½±å¤æãã¦out.tifã«å¤æ)
'ã好ããªæå½±æ³ã§ 'UTM53ã3099 'UTM54ã3100 'xy9ã2451 'xy10ã2452 'ä¸ç測å°ç³»BLã4612 s_epsg = "epsg:3100" t_epsg = "epsg:2451" Set objWshShell = WScript.CreateObject("WScript.Shell") Set tempEnv = objWshShell.Environment("Process") tempEnv.Item("GDAL_DATA") = "data" tempEnv.Item("GDAL_FILENAME_IS_UTF8") = "NO" Set args = WScript.Arguments If args.count<1 Then WScript.Echo "使ãæ¹ é»åå°å½¢å³å¤æ.vbs 0 or 2 (0:KANRI2KN.CSV 2:ãã¼ã¸)" WScript.Quit End If If args.item(0) = 0 Then kanri = "KANRI2KN.CSV" ElseIf args.item(0) = 2 Then merge = 1 End If If merge <> 1 Then Set objFso = CreateObject("Scripting.FileSystemObject") Set objFile = objFso.OpenTextFile(kanri, 1, False) If Err.Number > 0 Then WScript.Echo "Open Error" Else objFile.ReadLine Do Until objFile.AtEndOfStream str = Split(objFile.ReadLine,",") mesh = str(0) If args.item(0) = 0 Then gcp0 = str(45) & " " & str(46) & " " & str(37) & " " & str(38) gcp1 = str(47) & " " & str(48) & " " & str(39) & " " & str(40) gcp2 = str(49) & " " & str(50) & " " & str(41) & " " & str(42) gcp3 = str(51) & " " & str(52) & " " & str(43) & " " & str(44) ulx = str(16)*1.0 + str(17)/60.0 + str(18)/3600.0 uly = str(13)*1.0 + str(14)/60.0 + str(15)/3600.0 lrx = str(28)*1.0 + str(29)/60.0 + str(30)/3600.0 lry = str(25)*1.0 + str(26)/60.0 + str(27)/3600.0 End If strCmdLine = "cmd /c gdalwarp -of VRT -r bilinear --config GDAL_CACHEMAX 2048 " & left(mesh,4) & "\" & mesh & ".tif" & " " & "tmpA" & mesh & ".vrt" flag = objWshShell.Run(strCmdLine,,True) strCmdLine = "cmd /c gdalwarp -of VRT -s_srs " & s_epsg & " -t_srs epsg:4612 -r bilinear --config GDAL_CACHEMAX 2048 " & "tmpA" & mesh & ".vrt" & " " & "tmpB" & mesh & ".vrt" flag = objWshShell.Run(strCmdLine,,True) strCmdLine = "cmd /c gdal_translate -of VRT --config GDAL_CACHEMAX 2048 -projwin " & ulx & " " & uly & " " & lrx & " " & lry & " " & "tmpB" & mesh & ".vrt" & " " & "tmpC" & mesh & ".vrt" flag = objWshShell.Run(strCmdLine,,True) Loop End If objFile.Close Set objFile = Nothing Set objFso = Nothing Else strCmdLine = "cmd /c gdalwarp -tr 2.15 2.15 -co PROFILE=GeoTIFF -co COMPRESS=LZW -multi --config GDAL_CACHEMAX 2048 -r bilinear -co TFW=YES -s_srs epsg:4612 -t_srs " & t_epsg & " tmpC*.vrt out.tif" flag = objWshShell.Run(strCmdLine,,True) End If
ææ³
ã»ãã¨ã¯æ´é£¾é¨åããªããã®ãè³¼å
¥ã§ããã¨ãããã§ããã¼ã
åè
å®å½¢å³éçã¨ãªã³ããã³ãçã®æ¯è¼
http://net.jmc.or.jp/digital_data_gsiol_denshiChizu25000_hikaku.html