From 9bbc707379525264bc0d85d71a6fc54c4b917bdb Mon Sep 17 00:00:00 2001 From: Pavel Krajcevski Date: Thu, 10 Oct 2013 10:49:49 -0400 Subject: [PATCH] Fix average downscale method signature. --- PVRTCEncoder/src/Image.cpp | 4 ++-- PVRTCEncoder/src/Image.h | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/PVRTCEncoder/src/Image.cpp b/PVRTCEncoder/src/Image.cpp index da90839..1abb325 100644 --- a/PVRTCEncoder/src/Image.cpp +++ b/PVRTCEncoder/src/Image.cpp @@ -246,7 +246,7 @@ static Pixel AveragePixels(const ::std::vector &pixels) { return result; } -void Image::AverageDownscale(uint32 xtimes, uint32 ytimes, EWrapMode wrapMode) { +void Image::AverageDownscale(uint32 xtimes, uint32 ytimes) { const uint32 w = GetWidth(); const uint32 h = GetHeight(); @@ -271,7 +271,7 @@ void Image::AverageDownscale(uint32 xtimes, uint32 ytimes, EWrapMode wrapMode) { toAvg.clear(); for(uint32 y = j * pixelsY; y < (j+1) * pixelsY; y++) { for(uint32 x = i * pixelsX; x < (i+1) * pixelsX; x++) { - toAvg.push_back(GetPixel(x, y, wrapMode)); + toAvg.push_back((*this)(x, y)); } } diff --git a/PVRTCEncoder/src/Image.h b/PVRTCEncoder/src/Image.h index 7f63f57..32d2786 100644 --- a/PVRTCEncoder/src/Image.h +++ b/PVRTCEncoder/src/Image.h @@ -83,8 +83,7 @@ class Image { bool bOffsetNewPixels = false); // Downscales the image by using a simple averaging of the neighboring pixel values - void AverageDownscale(uint32 xtimes, uint32 ytimes, - EWrapMode wrapMode = eWrapMode_Wrap); + void AverageDownscale(uint32 xtimes, uint32 ytimes); void ComputeHessianEigenvalues(::std::vector &eigOne, ::std::vector &eigTwo,