зеркало из https://github.com/mozilla/moz-skia.git
fix trailing-ws
initialize fFlags in bitmapprocshader git-svn-id: http://skia.googlecode.com/svn/trunk@191 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
Родитель
25fc5b9f0a
Коммит
89bb83abb4
|
@ -379,7 +379,7 @@ public:
|
|||
@return true if the copy could be made.
|
||||
*/
|
||||
bool copyTo(SkBitmap* dst, Config c, Allocator* allocator = NULL) const;
|
||||
|
||||
|
||||
/** Returns true if this bitmap can be deep copied into the requested config
|
||||
by calling copyTo().
|
||||
*/
|
||||
|
|
|
@ -17,7 +17,7 @@ public:
|
|||
shape's matrix (if any).
|
||||
*/
|
||||
void drawXY(SkCanvas*, SkScalar dx, SkScalar dy);
|
||||
|
||||
|
||||
/** Draw the shape with the specified matrix, applied before the shape's
|
||||
matrix (if any).
|
||||
*/
|
||||
|
|
|
@ -246,7 +246,7 @@ void SkBitmap::setConfig(Config c, int width, int height, int rowBytes) {
|
|||
goto ERROR;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
fConfig = SkToU8(c);
|
||||
fWidth = width;
|
||||
fHeight = height;
|
||||
|
@ -927,7 +927,7 @@ void SkBitmap::buildMipMap(bool forceRebuild) {
|
|||
default:
|
||||
return; // don't build mipmaps for these configs
|
||||
}
|
||||
|
||||
|
||||
SkAutoLockPixels alp(*this);
|
||||
if (!this->readyToDraw()) {
|
||||
return;
|
||||
|
@ -949,7 +949,7 @@ void SkBitmap::buildMipMap(bool forceRebuild) {
|
|||
maxLevels += 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// nothing to build
|
||||
if (0 == maxLevels) {
|
||||
return;
|
||||
|
|
|
@ -21,6 +21,7 @@ SkBitmapProcShader::SkBitmapProcShader(const SkBitmap& src,
|
|||
fRawBitmap = src;
|
||||
fState.fTileModeX = (uint8_t)tmx;
|
||||
fState.fTileModeY = (uint8_t)tmy;
|
||||
fFlags = 0; // computed in setContext
|
||||
}
|
||||
|
||||
SkBitmapProcShader::SkBitmapProcShader(SkFlattenableReadBuffer& buffer)
|
||||
|
@ -28,6 +29,7 @@ SkBitmapProcShader::SkBitmapProcShader(SkFlattenableReadBuffer& buffer)
|
|||
fRawBitmap.unflatten(buffer);
|
||||
fState.fTileModeX = buffer.readU8();
|
||||
fState.fTileModeY = buffer.readU8();
|
||||
fFlags = 0; // computed in setContext
|
||||
}
|
||||
|
||||
void SkBitmapProcShader::beginSession() {
|
||||
|
@ -95,8 +97,7 @@ bool SkBitmapProcShader::setContext(const SkBitmap& device,
|
|||
}
|
||||
|
||||
// update fFlags
|
||||
fFlags = 0; // this should happen in SkShader.cpp
|
||||
|
||||
fFlags = 0;
|
||||
if (bitmapIsOpaque && (255 == this->getPaintAlpha())) {
|
||||
fFlags |= kOpaqueAlpha_Flag;
|
||||
}
|
||||
|
|
|
@ -35,7 +35,8 @@ SkColorTable::SkColorTable(int count)
|
|||
SkDEBUGCODE(f16BitCacheLockCount = 0;)
|
||||
}
|
||||
|
||||
SkColorTable::SkColorTable(const SkColorTable& src) {
|
||||
// call SkRefCnt's constructor explicitly, to avoid warning
|
||||
SkColorTable::SkColorTable(const SkColorTable& src) : SkRefCnt() {
|
||||
f16BitCache = NULL;
|
||||
fFlags = src.fFlags;
|
||||
int count = src.count();
|
||||
|
|
Загрузка…
Ссылка в новой задаче