[Qgis-developer] This had escaped me!

Etienne Tourigny etourigny.dev at gmail.com
Sat May 5 15:28:30 PDT 2012


Hi all

On Sat, May 5, 2012 at 6:03 PM, Giovanni Manghi
<giovanni.manghi at faunalia.pt> wrote:
> Hi Etienne,
>
>> Like it? It also opens other zip files, depending on the options you
>> choose in the Preferences (first tab, at the bottom)
>> Try it out in the browser, you can browse zips with various files.
>
>
> this is really super cool, thanks!

Nice that you like it!

I forgot to mention that gzipped files are supported also! (but not
for shapefiles as they are not a single file)

This is all possible due to GDAL/OGR /vsizip/ and /vsigzip/ mechanism
, more info at
http://trac.osgeo.org/gdal/wiki/UserDocs/ReadInZip

QuaZIP and zlib are used to get zip file listing (this is optional at
compilation, but supported by osgeo4w and linux builds).

>
> just noticed one thing, if the zip file contains >1 raster then is not
> shown in the browser, while if it contains just one it works ok (also
> from the add raster dialog).

You have to change the "Scan zip" settings (in the general options),
the possible values are

- No
- Passthru - this just sets the uri to /vsizip/file.zip (which is the
way gdal/ogr supports zip files) and does not support multiple files
- Basic Scan - this opens the zip file and presents the files which
extension is supported  (.tif, .shp, etc)
- Full Scan - this presents the files inside the zip which are valid
(takes longer)

Default value is Passthru, but perhaps "Basic Scan" would be a better default?
I had chosen Passthru as a default before using QuaZip, but it is
probably not the best default now.

Etienne

>
> cheers
>
> -- Giovanni --
>


More information about the Qgis-developer mailing list