Skip to content

Commit

Permalink
Fixed TiffHandlerState to allow for single-tiled small images.
Browse files Browse the repository at this point in the history
  • Loading branch information
oscarkramer committed Mar 4, 2021
1 parent 890b601 commit ded32ec
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/support_data/TiffHandlerState.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,11 +184,12 @@ void ossim::TiffHandlerState::loadDefaults(std::shared_ptr<ossim::istream> &str,
nValues = prefixValues.size();
addValue("tiff.number_of_directories", ossimString::toString(nValues));
ossim_uint32 idx = 0;
ossim_int64 h = getImageLength(0);
ossim_int64 w = getImageWidth(0);
//ossim_int64 h = getImageLength(0);
//ossim_int64 w = getImageWidth(0);
ossim_int64 tw = getTileWidth(0);
ossim_int64 th = getTileLength(0);
bool isTiled = (th&&tw&& ((tw < w) && (th < h)));
//bool isTiled = (th&&tw&& ((tw < w) && (th < h)));
bool isTiled = (tw>0 && th>0); // Can be a single tile (no strip info)
for (auto key : prefixValues)
{
if(isTiled)
Expand Down

0 comments on commit ded32ec

Please sign in to comment.