Remove SkBitmap::[setH/h]asHardwareMipMap

These are no longer used by Android.

Change-Id: Ie3b9aa60af681f9e076a0d0680fc716ae51f9cd8
Reviewed-on: https://skia-review.googlesource.com/c/168486
Reviewed-by: Cary Clark <caryclark@google.com>
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Auto-Submit: Leon Scroggins <scroggo@google.com>
Commit-Queue: Leon Scroggins <scroggo@google.com>
This commit is contained in:
Leon Scroggins III 2018-11-06 09:34:08 -05:00 committed by Skia Commit-Bot
parent 775ee901d3
commit e5eb1a5904
3 changed files with 0 additions and 60 deletions

View File

@ -2512,34 +2512,6 @@ false if pixel conversion is not possible.
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
#Method bool hasHardwareMipMap() const
#In Property
#Line # returns Mip_Map support present; Android only ##
#Populate
#NoExample
##
#SeeAlso setHasHardwareMipMap
##
# ------------------------------------------------------------------------------
#Method void setHasHardwareMipMap(bool hasHardwareMipMap)
#In Set
#Line # sets Mip_Map support present; Android only ##
#Populate
#NoExample
##
#SeeAlso hasHardwareMipMap
##
# ------------------------------------------------------------------------------
#Method bool extractAlpha(SkBitmap* dst) const #Method bool extractAlpha(SkBitmap* dst) const
#In Constructors #In Constructors
#Line # creates Bitmap containing Alpha of pixels ## #Line # creates Bitmap containing Alpha of pixels ##

View File

@ -1063,28 +1063,6 @@ public:
return this->writePixels(src, 0, 0); return this->writePixels(src, 0, 0);
} }
#ifdef SK_BUILD_FOR_ANDROID_FRAMEWORK
/** For use by Android framework only.
@return true if setHasHardwareMipMap() has been called with true
*/
bool hasHardwareMipMap() const {
return (fFlags & kHasHardwareMipMap_Flag) != 0;
}
/** For use by Android framework only.
@param hasHardwareMipMap sets state
*/
void setHasHardwareMipMap(bool hasHardwareMipMap) {
if (hasHardwareMipMap) {
fFlags |= kHasHardwareMipMap_Flag;
} else {
fFlags &= ~kHasHardwareMipMap_Flag;
}
}
#endif
/** Sets dst to alpha described by pixels. Returns false if dst cannot be written to /** Sets dst to alpha described by pixels. Returns false if dst cannot be written to
or dst pixels cannot be allocated. or dst pixels cannot be allocated.
@ -1188,13 +1166,6 @@ public:
private: private:
enum Flags { enum Flags {
kImageIsVolatile_Flag = 0x02, kImageIsVolatile_Flag = 0x02,
#ifdef SK_BUILD_FOR_ANDROID
/* A hint for the renderer responsible for drawing this bitmap
* indicating that it should attempt to use mipmaps when this bitmap
* is drawn scaled down.
*/
kHasHardwareMipMap_Flag = 0x08,
#endif
}; };
sk_sp<SkPixelRef> fPixelRef; sk_sp<SkPixelRef> fPixelRef;

View File

@ -579,9 +579,6 @@ void SkBitmap::validate() const {
SkASSERT(this->info().validRowBytes(this->rowBytes())); SkASSERT(this->info().validRowBytes(this->rowBytes()));
uint8_t allFlags = kImageIsVolatile_Flag; uint8_t allFlags = kImageIsVolatile_Flag;
#ifdef SK_BUILD_FOR_ANDROID
allFlags |= kHasHardwareMipMap_Flag;
#endif
SkASSERT((~allFlags & fFlags) == 0); SkASSERT((~allFlags & fFlags) == 0);
if (fPixelRef && fPixelRef->pixels()) { if (fPixelRef && fPixelRef->pixels()) {