Index: src/gpu/GrTexture.cpp |
diff --git a/src/gpu/GrTexture.cpp b/src/gpu/GrTexture.cpp |
index 9209dbd05353fa7fb77ec6cfba65e2358c0324e4..683458182eaef312f5067e839de9568eb47e6029 100644 |
--- a/src/gpu/GrTexture.cpp |
+++ b/src/gpu/GrTexture.cpp |
@@ -18,7 +18,7 @@ |
#include "SkMipMap.h" |
#include "SkTypes.h" |
-void GrTexture::dirtyMipMaps(bool mipMapsDirty, bool sRGBCorrect) { |
+void GrTexture::dirtyMipMaps(bool mipMapsDirty) { |
if (mipMapsDirty) { |
if (kValid_MipMapsStatus == fMipMapsStatus) { |
fMipMapsStatus = kAllocated_MipMapsStatus; |
@@ -26,7 +26,6 @@ void GrTexture::dirtyMipMaps(bool mipMapsDirty, bool sRGBCorrect) { |
} else { |
const bool sizeChanged = kNotAllocated_MipMapsStatus == fMipMapsStatus; |
fMipMapsStatus = kValid_MipMapsStatus; |
- fMipMapsAreSRGBCorrect = sRGBCorrect; |
if (sizeChanged) { |
// This must not be called until after changing fMipMapsStatus. |
this->didChangeGpuMemorySize(); |
@@ -90,16 +89,15 @@ GrSurfaceOrigin resolve_origin(const GrSurfaceDesc& desc) { |
GrTexture::GrTexture(GrGpu* gpu, const GrSurfaceDesc& desc, GrSLType samplerType, |
bool wasMipMapDataProvided) |
: INHERITED(gpu, desc) |
- , fSamplerType(samplerType) { |
+ , fSamplerType(samplerType) |
+ // Gamma treatment is explicitly set after creation via GrTexturePriv |
+ , fGammaTreatment(SkSourceGammaTreatment::kIgnore) { |
if (wasMipMapDataProvided) { |
fMipMapsStatus = kValid_MipMapsStatus; |
fMaxMipMapLevel = SkMipMap::ComputeLevelCount(fDesc.fWidth, fDesc.fHeight); |
- // At the moment, the CPU code for generating mipmaps doesn't account for sRGB: |
- fMipMapsAreSRGBCorrect = false; |
} else { |
fMipMapsStatus = kNotAllocated_MipMapsStatus; |
fMaxMipMapLevel = 0; |
- fMipMapsAreSRGBCorrect = false; |
} |
} |