Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(230)

Unified Diff: src/gpu/GrSWMaskHelper.cpp

Issue 544233002: "NULL !=" = NULL (Closed) Base URL: https://skia.googlesource.com/skia.git@are
Patch Set: rebase Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/GrResourceCache2.cpp ('k') | src/gpu/GrStencilAndCoverPathRenderer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrSWMaskHelper.cpp
diff --git a/src/gpu/GrSWMaskHelper.cpp b/src/gpu/GrSWMaskHelper.cpp
index b51bae437036944be13f7b1774fd629e4ec46f80..d3d464883811becffcb768d68ebe4d1edc899ec7 100644
--- a/src/gpu/GrSWMaskHelper.cpp
+++ b/src/gpu/GrSWMaskHelper.cpp
@@ -142,7 +142,7 @@ void GrSWMaskHelper::draw(const SkPath& path, const SkStrokeRec& stroke, SkRegio
SkTBlitterAllocator allocator;
SkBlitter* blitter = NULL;
if (kBlitter_CompressionMode == fCompressionMode) {
- SkASSERT(NULL != fCompressedBuffer.get());
+ SkASSERT(fCompressedBuffer.get());
blitter = SkTextureCompressor::CreateBlitterForFormat(
fBM.width(), fBM.height(), fCompressedBuffer.get(), &allocator, fCompressedFormat);
}
@@ -160,7 +160,7 @@ void GrSWMaskHelper::draw(const SkPath& path, const SkStrokeRec& stroke, SkRegio
bool GrSWMaskHelper::init(const SkIRect& resultBounds,
const SkMatrix* matrix,
bool allowCompression) {
- if (NULL != matrix) {
+ if (matrix) {
fMatrix = *matrix;
} else {
fMatrix.setIdentity();
@@ -249,7 +249,7 @@ bool GrSWMaskHelper::getTexture(GrAutoScratchTexture* texture) {
}
texture->set(fContext, desc);
- return NULL != texture->texture();
+ return SkToBool(texture->texture());
}
void GrSWMaskHelper::sendTextureData(GrTexture *texture, const GrTextureDesc& desc,
@@ -273,7 +273,7 @@ void GrSWMaskHelper::compressTextureData(GrTexture *texture, const GrTextureDesc
SkASSERT(fmt_to_config(fCompressedFormat) == desc.fConfig);
SkAutoDataUnref cmpData(SkTextureCompressor::CompressBitmapToFormat(fBM, fCompressedFormat));
- SkASSERT(NULL != cmpData);
+ SkASSERT(cmpData);
this->sendTextureData(texture, desc, cmpData->data(), 0);
}
@@ -300,7 +300,7 @@ void GrSWMaskHelper::toTexture(GrTexture *texture) {
break;
case kBlitter_CompressionMode:
- SkASSERT(NULL != fCompressedBuffer.get());
+ SkASSERT(fCompressedBuffer.get());
this->sendTextureData(texture, desc, fCompressedBuffer.get(), 0);
break;
}
« no previous file with comments | « src/gpu/GrResourceCache2.cpp ('k') | src/gpu/GrStencilAndCoverPathRenderer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698