Changeset 19526


Ignore:
Timestamp:
Apr 26, 2010 8:01:33 AM (6 years ago)
Author:
gaopeng
Message:

No NBITS for pixel depth < 8.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sandbox/warmerdam/1.6-esri/gdal/frmts/jp2kak/jp2kakdataset.cpp

    r19420 r19526  
    410410    this->nRasterXSize = band_dims.size.x;
    411411    this->nRasterYSize = band_dims.size.y;
    412     if( oCodeStream.get_bit_depth(nBand-1) % 8 != 0 )
    413     {
    414        
     412
     413    int nBits = oCodeStream.get_bit_depth(nBand-1);
     414    if( nBits > 8 && nBits % 8 != 0 )
     415    {
    415416        SetMetadataItem( "NBITS",
    416                          CPLString().Printf("%d",oCodeStream.get_bit_depth(nBand-1)),
     417                         CPLString().Printf("%d",nBits),
    417418                         "IMAGE_STRUCTURE" );
    418419    }
Note: See TracChangeset for help on using the changeset viewer.