Quantcast
Channel: Question and Answer » gdal
Viewing all articles
Browse latest Browse all 397

ERROR 6: The PNG driver does not support update access to existing datasets

$
0
0

I was trying to overlay a shapefile to some raster images from a directory using gdal_rasterize. But then encountered this error ERROR 6: The PNG driver does not support update access to existing datasets. Input_path has the raster images and the shp_path has the shape file. Any idea?

code:

@echo off

set "inpath=C:pathtoinput"
set "shppath=C:pathtoshapefile"


cd /d "%inpath%"

for %%a in (*.png) do (
   set "fileName=%%a"
   echo Overlaying the shape file . . .
   FORFILES /m %%a /C "cmd /c gdal_rasterize -b 1 -b 2 -b 3 -burn 0 -burn 0 -burn 0 %shppath%shpfile.shp %in_path%@fname.png"

)

Viewing all articles
Browse latest Browse all 397

Trending Articles