Closed bbukovic closed 9 years ago
Hi, If you have a patch to suggest for which and files glob pattern on Windows I will integrate it. I work on Linux...
The second issue was the same as #3 and it was fixed, and it's similar to your fix.
I'm not sure what's going wrong with the rest of your description. gdal2cesium builds tiles for the regions where there is at least one pixel from one of the origin rasters. The rest of tile will be processed as NODATA, so it should be set to 0, to make Cesium treat it as flat. Cesium also considers flat every region not covered by your tiles.
Hi,
thank you for your quick response. I saw solution for issue #3 and already test it - works without error.
Regarding terrain generation: One picture tells more than 1000 words, so below is picture of my issue :) I have tiff files (90) for entire country. Below is a screenshot of mosaiced tiff files. After running gdal2cesium script only terrain for area in red square is generated (this is cca. 22 files) despite I ran script for all 90 tiff files. Below is also an output of the script.
And the script output (all tiff files were processed):
Processing: IDW_A23.tif Processing: IDW_A24.tif Processing: IDW_A25.tif Processing: IDW_A26.tif Processing: IDW_B19.tif Processing: IDW_B20.tif Processing: IDW_B21.tif Processing: IDW_B22.tif Processing: IDW_B23.tif Processing: IDW_B24.tif Processing: IDW_B25.tif Processing: IDW_B26.tif Processing: IDW_B27.tif Processing: IDW_C19.tif Processing: IDW_C20.tif Processing: IDW_C21.tif Processing: IDW_C22.tif Processing: IDW_C23.tif Processing: IDW_C24.tif Processing: IDW_C25.tif Processing: IDW_C26.tif Processing: IDW_C27.tif Processing: IDW_D19.tif Processing: IDW_D20.tif Processing: IDW_D21.tif Processing: IDW_D22.tif Processing: IDW_D23.tif Processing: IDW_D24.tif Processing: IDW_D25.tif Processing: IDW_D26.tif Processing: IDW_D27.tif Processing: IDW_E20.tif Processing: IDW_E21.tif Processing: IDW_E22.tif Processing: IDW_E23.tif Processing: IDW_E24.tif Processing: IDW_E25.tif Processing: IDW_E26.tif Processing: IDW_E27.tif Processing: IDW_F19.tif Processing: IDW_F20.tif Processing: IDW_F21.tif Processing: IDW_F22.tif Processing: IDW_F23.tif Processing: IDW_F24.tif Processing: IDW_F25.tif Processing: IDW_F26.tif Processing: IDW_F27.tif Processing: IDW_F28.tif Processing: IDW_G19.tif Processing: IDW_G20.tif Processing: IDW_G21.tif Processing: IDW_G22.tif Processing: IDW_G23.tif Processing: IDW_G24.tif Processing: IDW_G25.tif Processing: IDW_G26.tif Processing: IDW_G27.tif Processing: IDW_G28.tif Processing: IDW_H19.tif Processing: IDW_H20.tif Processing: IDW_H21.tif Processing: IDW_H22.tif Processing: IDW_H23.tif Processing: IDW_H24.tif Processing: IDW_H25.tif Processing: IDW_H26.tif Processing: IDW_H27.tif Processing: IDW_H28.tif Processing: IDW_I22.tif Processing: IDW_I23.tif Processing: IDW_I24.tif Processing: IDW_I25.tif Processing: IDW_I26.tif Processing: IDW_I27.tif Processing: IDW_I28.tif Processing: IDW_I29.tif Processing: IDW_J25.tif Processing: IDW_J26.tif Processing: IDW_J27.tif Processing: IDW_J28.tif Processing: IDW_J29.tif Processing: IDW_J30.tif Processing: IDW_K26.tif Processing: IDW_K27.tif Processing: IDW_K28.tif Processing: IDW_K29.tif Processing: IDW_K30.tif Processing: IDW_L27.tif Processing: IDW_L28.tif Generating Tiles (round 1 of 2): 0...10...20...30...40...50...60...70...80...90...100 - done. Generating Tiles (round 2 of 2): 0...10...20...30...40...50...60...70...80...90...100 - done. Processing finished. Tiles written to "tiles".
Regards
Please, use the -i option to build the index shapefile of the tile hierarchy. Let's see if all the tiles are correctly processed.
Below is a screenshot of the built shapefile and my tiff files. I think it looks ok. I've also checked some polylines in shapefile and corresponding terrain files actually exist. I also noticed that shapefile has 3406 features (polylines) - zoom levels 7 - 13. Features for zoom levels below 7 do not exist in shapefile, but terrain files were generated. This is probably how it works. After adding terrain tileset into terrain provider in Cesium I observe the same situation as before - only half (left half in screenshot) of the terrain is rendered and the other half (right half) is flattened. Terrain tiles for flattened area are not even requested in web browser as I can see from console.
I do not expect any detailed analysis from you, but if you are interested, I can drop my data in dropbox or somewhere.
If you could put your data for download it would be great.
2014-12-10 19:05 GMT+01:00 bbukovic notifications@github.com:
Below is a screenshot of the built shapefile and my tiff files. I think it looks ok. I've also checked some polylines in shapefile and corresponding terrain files actually exist. I also noticed that shapefile has 3406 features (polylines) - zoom levels 7 - 13. Features for zoom levels below 7 do not exist in shapefile, but terrain files were generated. This is probably how it works. After adding terrain tileset into terrain provider in Cesium I observe the same situation as before - only half (left half in screenshot) of the terrain is rendered and the other half (right half) is flattened. Terrain tiles for flattened area are not even requested in web browser as I can see from console.
I do not expect any detailed analysis from you, but if you are interested, I can drop my data in dropbox or somewhere.
[image: terrain_tiles] https://cloud.githubusercontent.com/assets/7601405/5381044/cdc940a6-809d-11e4-91fc-91104439994a.PNG
— Reply to this email directly or view it on GitHub https://github.com/giohappy/gdal2cesium/issues/4#issuecomment-66495143.
Giovanni Allegri http://about.me/giovanniallegri Twitter: https://twitter.com/_giohappy_ blog: http://blog.spaziogis.it GEO+ geomatica in Italia http://bit.ly/GEOplus
Here they are:
Please, just let me know after you download files, so I can remove them.
Hi, I'm sorry but the latest notification was trashed by my email system, and I didn't receive it. Could you reactivate the download links?
Hi,
Below are new links where you will find source tif files and output generated on my machine.
Thank you!
Thanks, I'm downloading them. I'll let you know as soon as I can give them a look.
@bbukovic I've spot the error. I will work on it as soon as possible. Thanks ;)
It should be fixed now. Can you try it?
That was fast :) And I am very glad I can confirm that it works like a charm. Thank you very much!
Hi,
I have observed two minor things:
This is simple to overcome, just list the filenames instead of using "*.tif", e.g.: gdal2cesium.py -o tiles file1.tif file2.tif file3.tif
And then I have two more issues:
Ok, I have not digged into the logic and I just added one more if clause to check whether script generates some output or not. Now this block of the code looks like this in my script: if res != tmp_res: if tz < self.tmaxz: if vrt_file is not None: self.vrts[vrt_file][1] = tz-1 tmp_res = res self.make_vrt(res,i) vrtfile = "cesium%s.vrt" % i self.vrts[vrt_file] = [tz,None] i += 1
After this change the script generated terrain tiles. Here comes the second issue that I do not know how to overcome and its source can be my source code change:
This is terrain loaded in cesium where the border between generated and not generated can be seen:
Regards