Opened 8 years ago

Closed 8 years ago

#6648 closed defect (invalid)

GDAL 2.1.1: gdalwarp to VRT produces large output file if cropping to cutline

Reported by: cxcandid Owned by: warmerdam
Priority: normal Milestone:
Component: default Version: 2.1.1
Severity: normal Keywords:
Cc:

Description

During some tests with gdalwarp, i recognized a change between GDAL 1.11.4 and GDAL 2.1.1 regarding the creation of VRT files.

When cropping to a rectangular cutline, the output VRT file is much larger in GDAL 2.1.1 than in GDAL 1.11.4. The larger size results from an automatic segmentation of the cutline, which produces a lot of additional vertex points. Using GDAL 1.11.4 the resulting VRT files are much smaller, because there is no cutline segmentation.

Is this behavior intended?

Are there any settings or flags to disable the automatic segmentation?

Best regards and my thanks for your efforts!

Christoph

Attachments (1)

Austria.zip (139.7 KB ) - added by cxcandid 8 years ago.

Download all attachments as: .zip

Change History (2)

by cxcandid, 8 years ago

Attachment: Austria.zip added

comment:1 by Even Rouault, 8 years ago

Resolution: invalid
Status: newclosed

Yes, the densification is intended behaviour otherwise the specified cutline may not be exactly followed (particularly with some RPC warping that involve some strong non linearities). You may decide to opt out for densification by adding "--config GDALWARP_DENSIFY_CUTLINE NO" on the gdalwarp command line.

I've also committed r35373 "gdalwarp: avoid cutline densification when no transform at all is involved (related to #6648, but doesn't address the precise use case of this ticket)"

Note: See TracTickets for help on using tickets.