diff options
author | 2015-08-27 07:41:13 -0700 | |
---|---|---|
committer | 2015-08-27 07:41:16 -0700 | |
commit | 96fcdcc219d2a0d3579719b84b28bede76efba64 (patch) | |
tree | 0ec5ea0193d8292df8bf5ed9dd8498a5eb5763dd /src/codec/SkBmpStandardCodec.cpp | |
parent | 435af2f736c85c3274a0c6760a3523810750d237 (diff) |
Style Change: NULL->nullptr
DOCS_PREVIEW= https://skia.org/?cl=1316233002
Review URL: https://codereview.chromium.org/1316233002
Diffstat (limited to 'src/codec/SkBmpStandardCodec.cpp')
-rw-r--r-- | src/codec/SkBmpStandardCodec.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/codec/SkBmpStandardCodec.cpp b/src/codec/SkBmpStandardCodec.cpp index 8404aa616b..210498eb00 100644 --- a/src/codec/SkBmpStandardCodec.cpp +++ b/src/codec/SkBmpStandardCodec.cpp @@ -20,12 +20,12 @@ SkBmpStandardCodec::SkBmpStandardCodec(const SkImageInfo& info, SkStream* stream uint32_t bytesPerColor, uint32_t offset, SkBmpCodec::RowOrder rowOrder, bool inIco) : INHERITED(info, stream, bitsPerPixel, rowOrder) - , fColorTable(NULL) + , fColorTable(nullptr) , fNumColors(this->computeNumColors(numColors)) , fBytesPerColor(bytesPerColor) , fOffset(offset) - , fSwizzler(NULL) - , fSrcBuffer(NULL) + , fSwizzler(nullptr) + , fSrcBuffer(nullptr) , fInIco(inIco) {} @@ -54,7 +54,7 @@ SkCodec::Result SkBmpStandardCodec::onGetPixels(const SkImageInfo& dstInfo, } // Create the color table if necessary and prepare the stream for decode - // Note that if it is non-NULL, inputColorCount will be modified + // Note that if it is non-nullptr, inputColorCount will be modified if (!this->createColorTable(dstInfo.alphaType(), inputColorCount)) { SkCodecPrintf("Error: could not create color table.\n"); return kInvalidInput; @@ -82,7 +82,7 @@ SkCodec::Result SkBmpStandardCodec::onGetPixels(const SkImageInfo& dstInfo, if (this->bitsPerPixel() <= 8) { // Inform the caller of the number of colors uint32_t maxColors = 1 << this->bitsPerPixel(); - if (NULL != numColors) { + if (nullptr != numColors) { // We set the number of colors to maxColors in order to ensure // safe memory accesses. Otherwise, an invalid pixel could // access memory outside of our color table array. @@ -112,7 +112,7 @@ SkCodec::Result SkBmpStandardCodec::onGetPixels(const SkImageInfo& dstInfo, // should fail if the alpha type is not one of the above // values. SkASSERT(false); - packARGB = NULL; + packARGB = nullptr; break; } @@ -210,7 +210,7 @@ bool SkBmpStandardCodec::initializeSwizzler(const SkImageInfo& dstInfo, fSwizzler.reset(SkSwizzler::CreateSwizzler(config, colorPtr, dstInfo, opts.fZeroInitialized, this->getInfo())); - if (NULL == fSwizzler.get()) { + if (nullptr == fSwizzler.get()) { return false; } return true; |