Opened 15 years ago
Closed 15 years ago
#227 closed task (fixed)
[wktraster] Add out-db support in gdal2wktraster.py script
Reported by: | jorgearevalo | Owned by: | jorgearevalo |
---|---|---|---|
Priority: | high | Milestone: | WKTRaster 0.1.6 |
Component: | raster | Version: | master |
Keywords: | Cc: |
Description
Attached is a patch adding support for creating out-db rasters in gdal2wktraster.py script. Please review and correct it where needed.
Attachments (1)
Change History (16)
follow-up: 2 comment:1 by , 15 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
by , 15 years ago
Attachment: | gdal2wktraster_outdb_support.patch added |
---|
comment:2 by , 15 years ago
comment:3 by , 15 years ago
Jorge, that's great, thanks! So, I'm deferring review until the new version is attached. No rush!
comment:4 by , 15 years ago
Summary: | Add out-db support in gdal2wktraster.py script → [wktraster] Add out-db support in gdal2wktraster.py script |
---|
comment:5 by , 15 years ago
Milestone: | → WKTRaster 0.1.6 |
---|
comment:6 by , 15 years ago
Priority: | medium → high |
---|
comment:7 by , 15 years ago
Owner: | changed from | to
---|---|
Status: | assigned → new |
Now that Jorge has access to SVN he can apply the patch himself. If it's already done, please close the ticket.
comment:8 by , 15 years ago
I've implemented this (function wkblify_band):
- bandidx (band number) comes from caller method: wkblify_raster_level. 1-based index
- the path to the external file is the same provided with the option "-r <raster_name>" when calling the loader
After this, I've commented these lines in rtpostgis.sql.in.c:
-- Verify out_db
-- TODO: Waiting for out-db rasters
--IF ( p_out_db = true ) THEN
-- RAISE EXCEPTION 'TODO: Outside database rasters not implemented yet';
-- RETURN 'fail';
--END IF;
Once re-compiled, I've correctly loaded a raster with outdb support doing this. Do you think the approximation is correct? If yes, I'll finish the out-db raster reading support in GDAL, and I'll test it (this is one of my GDAL tickets: http://trac.osgeo.org/gdal/ticket/3234
comment:9 by , 15 years ago
Status: | new → assigned |
---|
comment:10 by , 15 years ago
I've just committed this change (r5102). I'm testing it by WKT Raster GDAL driver (working on it). Waiting for comments to resolve the case.
follow-up: 13 comment:11 by , 15 years ago
I forgot: I think this storage method only has sense if the raster table has 1 file, of size RasterXSize, RasterYSize. What do you think?
comment:12 by , 15 years ago
This storage method makes sence mostly when a big raster dataset is cut into (JPEG) tiles for a web server. The web application first grab the path to the file list and then forward the tiles directly from the file system without reading the whole tiles from the database. This is supposed to be faster...
comment:13 by , 15 years ago
Replying to jorgearevalo:
I forgot: I think this storage method only has sense if the raster table has 1 file, of size RasterXSize, RasterYSize. What do you think?
Sorry, I meant 1 row. Each out-db raster has to have 1 row, of RasterXSize, RasterYSize.
comment:14 by , 15 years ago
Jorge, I haven't tested but the commit looks good to me.
Just one note, I'd suggest to remove TODO comments when a feature is completed, instead of commenting out such comment. I mean the comment in rtpostgis.sql.in.c:539
comment:15 by , 15 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Sure. I've deleted the commented code, TODO comment included (r5103). I close the ticket for now...
Replying to mloskot: I'm simplifying the patch. I'll post a new version ASAP