Fix warnings on VS2015 x86_64 build

TBR=bungeman@google.com

Review URL: https://codereview.chromium.org/1276133002
This commit is contained in:
bsalomon 2015-08-06 17:33:16 -07:00 committed by Commit bot
parent 4ab9d5f1bc
commit ebc1c10fe1
4 changed files with 8 additions and 4 deletions

View File

@ -38,7 +38,7 @@ static SkBitmap make_hemi_normalmap(int texSize) {
locY = 0.0f;
locZ = 0.0f;
}
locZ = sqrt(1.0f - locZ);
locZ = sqrtf(1.0f - locZ);
unsigned char r = static_cast<unsigned char>((0.5f * locX + 0.5f) * 255);
unsigned char g = static_cast<unsigned char>((-0.5f * locY + 0.5f) * 255);
unsigned char b = static_cast<unsigned char>((0.5f * locZ + 0.5f) * 255);

View File

@ -4,6 +4,9 @@
# found in the LICENSE file.
{
'variables': {
'skia_warnings_as_errors': 0,
},
'targets': [
{
# Only used by win, down below.

View File

@ -256,7 +256,8 @@ void GrDrawTarget::drawPaths(const GrPipelineBuilder& pipelineBuilder,
SkASSERT(this->caps()->shaderCaps()->pathRenderingSupport());
SkASSERT(pathRange);
SkASSERT(indices);
SkASSERT(0 == reinterpret_cast<long>(indices) % GrPathRange::PathIndexSizeInBytes(indexType));
SkASSERT(0 == reinterpret_cast<intptr_t>(indices) %
GrPathRange::PathIndexSizeInBytes(indexType));
SkASSERT(transformValues);
// Setup clip

View File

@ -106,12 +106,12 @@ public:
fB = new B();
}
virtual void setValues(int v) {
fVoidStar = reinterpret_cast<void*>(v);
fVoidStar = reinterpret_cast<void*>(static_cast<intptr_t>(v));
this->INHERITED::setValues(v);
fB->setValues(v);
}
virtual bool checkValues(int v) {
return fVoidStar == reinterpret_cast<void*>(v) &&
return fVoidStar == reinterpret_cast<void*>(static_cast<intptr_t>(v)) &&
fB->checkValues(v) &&
this->INHERITED::checkValues(v);
}