2

This is similar to a question asked by someone else, re OS tiles. However, there is a difference!

I have a large number (over 10k) of georeferenced png files which I have mosaicked in ArcMap, but also want to be able to access them in other programs such as QGIS over the web and within a private network using GeoServer. I have tried creating VRT's with them, and sometimes it works, but sometimes it doesn't. It seems that on selecting over 200-odd png's, the vrt stops being created.

Is there a limit on the amount of rasters for a VRT?

The error message is:

The process failed to start. Either the invoked program is missing, or you may have insufficient permissions to invoke the program.

and the code is:

gdalbuildvrt -allow_projection_difference 
"F:/Historic Buildings/GIS/Data/Mapping/Landranger/Raster/15k/Data/SX/SX.vrt" 
"F:/Historic Buildings/GIS/Data/Mapping/Landranger/Raster/15k/Data/SX/1.png" 
"F:/Historic Buildings/GIS/Data/Mapping/Landranger/Raster/15k/Data/SX/2.png" 
"F:/Historic Buildings/GIS/Data/Mapping/Landranger/Raster/15k/Data/SX/3.png" 
"F:/Historic Buildings/GIS/Data/Mapping/Landranger/Raster/15k/Data/SX/4.png" 
"F:/Historic Buildings/GIS/Data/Mapping/Landranger/Raster/15k/Data/SX/5.png" 
"F:/Historic Buildings/GIS/Data/Mapping/Landranger/Raster/15k/Data/SX/6.png" 
"F:/Historic Buildings/GIS/Data/Mapping/Landranger/Raster/15k/Data/SX/7.png"

with an additional +200 similarly addressed png's

I am using QGIS 1.8.0 Lisboa, on Windows 7 64bit.

2 Answers 2

4

See if you can do it sucessfully with a handful of files.

For me, it worked with 300 files. At first, I had to build individual vrts for each image to expand the colour information to rgba:

for %%N in (D:\Karten\gdal\gdal2tiles\NL25\*.tif) DO gdal_translate -of vrt -expand rgba %%N D:\Karten\gdal\gdal2tiles\NL25\%%~nN.vrt

Second run, I merged all those vrts to a single one:

gdalbuildvrt -allow_projection_difference index25.vrt NL25\*.vrt

Maybe the command line arguments are limited in character size, which I got around by using the wildcards.

0
2

@AndreJ had the correct answer in their last statement.

It is a character limit. If you use the wildcard it runs fine. I just tried on 28000 tiffs and it ran no problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.