| 1897 | } |
| 1898 | |
| 1899 | void UpdateStats(gdal::RasterStats<double> &stats, const GByte *pabyValues, |
| 1900 | const GByte *pabyMask, const double *padfWeights, |
| 1901 | const GByte *pabyWeightsMask, const GByte *pabyCoverage, |
| 1902 | const double *pdfX, const double *pdfY, size_t nX, |
| 1903 | size_t nY) const |
| 1904 | { |
| 1905 | if (m_coverageDataType == GDT_Float32) |
| 1906 | { |
| 1907 | stats.process(reinterpret_cast<const double *>(pabyValues), |
| 1908 | pabyMask, padfWeights, pabyWeightsMask, |
| 1909 | reinterpret_cast<const float *>(pabyCoverage), pdfX, |
| 1910 | pdfY, nX, nY); |
| 1911 | } |
| 1912 | else |
| 1913 | { |
| 1914 | stats.process(reinterpret_cast<const double *>(pabyValues), |
| 1915 | pabyMask, padfWeights, pabyWeightsMask, pabyCoverage, |
| 1916 | pdfX, pdfY, nX, nY); |
| 1917 | } |
| 1918 | } |
| 1919 | |
| 1920 | bool CalculateCoverage(const OGRGeometry *poGeom, |
| 1921 | const OGREnvelope &oSnappedGeomExtent, int nXSize, |
no test coverage detected