Re: [gdal-dev] RE: Border slivers and JPEG2000 compression

2008-12-30 Thread Frank Warmerdam
Smith, Michael wrote: I never found a good solution to this - one thing I am doing is taking the TIFFs and mosaicking them with their neighbors to fill these slivers with data from the adjacent tile, so there are no slivers. That is a brute-force and inelegant solution though. Any suggestion

Re: [gdal-dev] RE: Border slivers and JPEG2000 compression

2008-12-30 Thread Even Rouault
Michael, As Jukka Rahkonen has already suggested, I think that there's no possibility of doing what you want, with GDAL or any other tool. It is the nature of the lossy compression to return something close to 0, but not 0 (or the other way round), when you decompress the data. You can observe

[gdal-dev] RE: Border slivers and JPEG2000 compression

2008-12-30 Thread Smith, Michael
I never found a good solution to this - one thing I am doing is taking the TIFFs and mosaicking them with their neighbors to fill these slivers with data from the adjacent tile, so there are no slivers. That is a brute-force and inelegant solution though. Any suggestions on how to keep border pix

[gdal-dev] Re: Border slivers and JPEG2000 compression

2008-12-19 Thread Jukka Rahkonen
Smith, Michael maine.gov> writes: > > I tried that but it doesn't seem to write to JP2KAK. If I do this: > > nearblack mosaic_jp2.jp2 > > I get this error: > 0...10..ERROR 6: WriteBlock() not supported for this dataset. > ERROR 1: GetBlockRef failed at X block offset 1, Y block offset 19 > ER

[gdal-dev] Re: Border slivers and JPEG2000 compression

2008-12-17 Thread Jukka Rahkonen
Matt Wilkie gov.yk.ca> writes: > > Hi Micheal, try the nearblack utility (which is a relatively new > addition): http://www.gdal.org/nearblack.html > > "This utility will scan an image and try to set all pixels that are > nearly black (or nearly white) around the collar to exactly black (or