Index: src/core/SkMipMap.h |
diff --git a/src/core/SkMipMap.h b/src/core/SkMipMap.h |
index f8753cdc1b77cb1e59d5145bba1c4018ea579e29..ed912ba976956400f2e49daa89935808dd6f08db 100644 |
--- a/src/core/SkMipMap.h |
+++ b/src/core/SkMipMap.h |
@@ -21,23 +21,21 @@ public: |
void* fPixels; |
uint32_t fRowBytes; |
uint32_t fWidth, fHeight; |
+ float fScale; // < 1.0 |
}; |
bool extractLevel(SkScalar scale, Level*) const; |
+ size_t getSize() const { return fSize; } |
+ |
private: |
+ size_t fSize; |
Level* fLevels; |
int fCount; |
// we take ownership of levels, and will free it with sk_free() |
- SkMipMap(Level* levels, int count) : fLevels(levels), fCount(count) { |
- SkASSERT(levels); |
- SkASSERT(count > 0); |
- } |
- |
- virtual ~SkMipMap() { |
- sk_free(fLevels); |
- } |
+ SkMipMap(Level* levels, int count, size_t size); |
+ virtual ~SkMipMap(); |
static Level* AllocLevels(int levelCount, size_t pixelSize); |
}; |