Skip to content

gdal raster clip: add options from vector clip #12181

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 3 commits into from

Conversation

rouault
Copy link
Member

@rouault rouault commented Apr 19, 2025

Factor out code common to gdal raster clip and gdal vector clip in a common class, and import the following existiong options of vector clip to raster clip: geometry, geometry-crs, like-sql, like-layer, like-where.
Allow like dataset to be a vector one
When the clipping geometry is not a rectangle, use gdalwarp -cutline underneath.
Add only-bbox and addalpha option

@rouault rouault added enhancement funded through GSP Work funded through the GDAL Sponsorship Program gdal_cli Anything related to the new 3.11 "gdal" CLI frontend labels Apr 19, 2025
@rouault rouault added this to the 3.11.0 milestone Apr 19, 2025
@rouault rouault force-pushed the gdal_raster_clip_enhancements branch 4 times, most recently from fb9557c to b43d967 Compare April 20, 2025 13:36
@coveralls
Copy link
Collaborator

coveralls commented Apr 20, 2025

Coverage Status

coverage: 70.724% (+0.005%) from 70.719%
when pulling cc4eb70 on rouault:gdal_raster_clip_enhancements
into 19671ee on OSGeo:master.

@rouault rouault force-pushed the gdal_raster_clip_enhancements branch 2 times, most recently from 6343260 to cc4eb70 Compare April 20, 2025 16:05
@rouault rouault force-pushed the gdal_raster_clip_enhancements branch 2 times, most recently from 35516e8 to 5a68d51 Compare April 27, 2025 14:57
@rouault rouault force-pushed the gdal_raster_clip_enhancements branch from 5a68d51 to 2d82bb6 Compare April 27, 2025 16:09
rouault added 2 commits April 27, 2025 22:01
Factor out code common to gdal raster clip and gdal vector clip in a
common class, and import the following existiong options of vector clip
to raster clip: geometry, geometry-crs, like-sql, like-layer,
like-where.
Allow like dataset to be a vector one
When the clipping geometry is not a rectangle, use gdalwarp -cutline
underneath.
Add only-bbox and addalpha option
@rouault rouault force-pushed the gdal_raster_clip_enhancements branch from 2d82bb6 to 3beb975 Compare April 27, 2025 20:01
@rouault rouault closed this Apr 28, 2025
dhdeangelis pushed a commit to dhdeangelis/gdal that referenced this pull request Apr 28, 2025
…ents

gdal raster clip: add options from vector clip
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement funded through GSP Work funded through the GDAL Sponsorship Program gdal_cli Anything related to the new 3.11 "gdal" CLI frontend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants