Skip to content

Commit

Permalink
Merge branch 'trunk' into enhance-complex-datasets-with-pf
Browse files Browse the repository at this point in the history
  • Loading branch information
jmichel-otb committed Jul 12, 2016
2 parents 84afb22 + d9ba836 commit 5d922d9
Show file tree
Hide file tree
Showing 32 changed files with 33 additions and 16 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
30 changes: 15 additions & 15 deletions gdal/alg/internal_qhull_headers.h
Original file line number Diff line number Diff line change
Expand Up @@ -974,22 +974,22 @@ static gdal_realT qh_stddev();
#pragma warning( disable : 4306 ) /* e.g 'type cast' : conversion from 'long' to 'facetT *' of greater size */
#endif

#include "libqhull/libqhull.h"
#include "libqhull/libqhull.c"
#include "libqhull/poly.c"
#include "libqhull/poly2.c"
#include "libqhull/mem.c"
#include "libqhull/user.c"
#include "libqhull/global.c"
#include "internal_libqhull/libqhull.h"
#include "internal_libqhull/libqhull.c"
#include "internal_libqhull/poly.c"
#include "internal_libqhull/poly2.c"
#include "internal_libqhull/mem.c"
#include "internal_libqhull/user.c"
#include "internal_libqhull/global.c"
/*#include "userprintf.c"*/
#include "libqhull/random.c"
#include "libqhull/qset.c"
#include "libqhull/io.c"
#include "libqhull/usermem.c"
#include "libqhull/geom.c"
#include "libqhull/geom2.c"
#include "libqhull/stat.c"
#include "libqhull/merge.c"
#include "internal_libqhull/random.c"
#include "internal_libqhull/qset.c"
#include "internal_libqhull/io.c"
#include "internal_libqhull/usermem.c"
#include "internal_libqhull/geom.c"
#include "internal_libqhull/geom2.c"
#include "internal_libqhull/stat.c"
#include "internal_libqhull/merge.c"

#ifdef _MSC_VER
#pragma warning( pop )
Expand Down
19 changes: 18 additions & 1 deletion gdal/frmts/raw/roipacdataset.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -354,8 +354,25 @@ GDALDataset *ROIPACDataset::Open( GDALOpenInfo *poOpenInfo )
}
else { /* PIXEL */
nPixelOffset = GDALGetDataTypeSizeBytes(eDataType) * nBands;
nLineOffset = nPixelOffset * nWidth * nBands;
nLineOffset = nPixelOffset * nWidth;
nBandOffset = GDALGetDataTypeSizeBytes(eDataType);

if( nBands > 1 )
{
// GDAL 2.0.[0-3] and 2.1.0 had a value of nLineOffset that was
// equal to the theoretical nLineOffset multiplied by nBands...
VSIFSeekL( poDS->fpImage, 0, SEEK_END );
const GUIntBig nWrongFileSize = GDALGetDataTypeSizeBytes(eDataType) *
nWidth * (static_cast<GUIntBig>(nFileLength - 1) * nBands * nBands + nBands);
if( VSIFTellL( poDS->fpImage ) == nWrongFileSize )
{
CPLError(CE_Warning, CPLE_AppDefined,
"This file has been incorrectly generated by an older "
"GDAL version whose line offset computation was erroneous. "
"Taking that into account, but the file should be re-encoded ideally");
nLineOffset = nLineOffset * nBands;
}
}
}
poDS->nBands = nBands;
for( int b = 0; b < nBands; b++ )
Expand Down

0 comments on commit 5d922d9

Please sign in to comment.