Opened 11 years ago
Closed 5 years ago
#5251 closed enhancement (wontfix)
Nearblack as a method storing external 1bit mask band
Reported by: | klokan | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | closed_because_of_github_migration |
Component: | default | Version: | unspecified |
Severity: | normal | Keywords: | nearblack |
Cc: |
Description (last modified by )
We are opening GDAL datasets in our software and users can choose a color which becomes NODATA. This runs great for files with lossless compression, but if it is applied on lossy compressed files it produces visual artifacts.
Workaround is to preprocess the input files with the nearblack utility (http://www.gdal.org/nearblack.html), but it quite complicated step for the users.
It would be great if our C/C++ software could call a method that creates a small possibly compressed 1bit band into a temporary file with specified name. This temporary file should be then usable as the external mask band for the original input file which can be opened even in read-only mode.
The mask band should reuse the algorithms applied in the nearblack command line utility.
An example use case: open a Wavelet or JPEG compressed raster in read-only mode and create and store the external mask band into a temporary file or memory. Assign the created band as the mask band to the original read-only dataset, so if the gdal I/O methods utilize the nearblack mask as the alpha channel correctly.
The various colors (values per band) should be supported as well, as in #4085
Related may be GDAL RFC15: http://trac.osgeo.org/gdal/wiki/rfc15_nodatabitmask
Change History (2)
comment:1 by , 11 years ago
Description: | modified (diff) |
---|
comment:2 by , 5 years ago
Milestone: | → closed_because_of_github_migration |
---|---|
Resolution: | → wontfix |
Status: | new → closed |
This ticket has been automatically closed because Trac is no longer used for GDAL bug tracking, since the project has migrated to GitHub. If you believe this ticket is still valid, you may file it to https://github.com/OSGeo/gdal/issues if it is not already reported there.