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

Unified Diff: src/effects/SkPerlinNoiseShader.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/effects/SkMorphologyImageFilter.cpp ('k') | src/effects/SkPictureImageFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/SkPerlinNoiseShader.cpp
diff --git a/src/effects/SkPerlinNoiseShader.cpp b/src/effects/SkPerlinNoiseShader.cpp
index b0ebb39342bc749e0cacf7e9d505f0c4250c1033..0247ed9e1b56487a9537cb612c73794117348cd9 100644
--- a/src/effects/SkPerlinNoiseShader.cpp
+++ b/src/effects/SkPerlinNoiseShader.cpp
@@ -966,7 +966,7 @@ void GrGLPerlinNoise::setData(const GrGLProgramDataManager& pdman, const GrDrawE
bool SkPerlinNoiseShader::asNewEffect(GrContext* context, const SkPaint& paint,
const SkMatrix* externalLocalMatrix, GrColor* paintColor,
GrEffect** effect) const {
- SkASSERT(NULL != context);
+ SkASSERT(context);
*paintColor = SkColor2GrColorJustAlpha(paint.getColor());
@@ -1001,7 +1001,7 @@ bool SkPerlinNoiseShader::asNewEffect(GrContext* context, const SkPaint& paint,
SkMatrix m = context->getMatrix();
m.setTranslateX(-localMatrix.getTranslateX() + SK_Scalar1);
m.setTranslateY(-localMatrix.getTranslateY() + SK_Scalar1);
- if ((NULL != permutationsTexture) && (NULL != noiseTexture)) {
+ if ((permutationsTexture) && (noiseTexture)) {
*effect = GrPerlinNoiseEffect::Create(fType,
fNumOctaves,
fStitchTiles,
@@ -1016,10 +1016,10 @@ bool SkPerlinNoiseShader::asNewEffect(GrContext* context, const SkPaint& paint,
// Unlock immediately, this is not great, but we don't have a way of
// knowing when else to unlock it currently. TODO: Remove this when
// unref becomes the unlock replacement for all types of textures.
- if (NULL != permutationsTexture) {
+ if (permutationsTexture) {
GrUnlockAndUnrefCachedBitmapTexture(permutationsTexture);
}
- if (NULL != noiseTexture) {
+ if (noiseTexture) {
GrUnlockAndUnrefCachedBitmapTexture(noiseTexture);
}
« no previous file with comments | « src/effects/SkMorphologyImageFilter.cpp ('k') | src/effects/SkPictureImageFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698