Permalink
Browse files

fix compile error for ios/mac c++11

  • Loading branch information...
1 parent 2e79bd5 commit baeb89794a784bd70b7f11ea8b502740a96cd804 @dualface dualface committed Dec 10, 2012
Showing with 5 additions and 5 deletions.
  1. +1 −1 cocos2dx/CCDirector.cpp
  2. +4 −4 cocos2dx/textures/CCTexturePVR.cpp
View
@@ -458,7 +458,7 @@ CCPoint CCDirector::convertToGL(const CCPoint& uiPoint)
kmScalar zClip = transform.mat[14]/transform.mat[15];
CCSize glSize = m_pobOpenGLView->getDesignResolutionSize();
- kmVec3 clipCoord = {2.0*uiPoint.x/glSize.width - 1.0, 1.0 - 2.0*uiPoint.y/glSize.height, zClip};
+ kmVec3 clipCoord = {2.0f*uiPoint.x/glSize.width - 1.0f, 1.0f - 2.0f*uiPoint.y/glSize.height, zClip};
kmVec3 glCoord;
kmVec3TransformCoord(&glCoord, &clipCoord, &transformInv);
@@ -66,13 +66,13 @@ static const ccPVRTexturePixelFormatInfo PVRTableFormats[] = {
#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS)
// 9: PVRTC 2BPP RGB
- {GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG, -1, -1, 2, true, false, kCCTexture2DPixelFormat_PVRTC2},
+ {GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG, 0xFFFFFFFF, 0xFFFFFFFF, 2, true, false, kCCTexture2DPixelFormat_PVRTC2},
// 10: PVRTC 2BPP RGBA
- {GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG, -1, -1, 2, true, true, kCCTexture2DPixelFormat_PVRTC2},
+ {GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG, 0xFFFFFFFF, 0xFFFFFFFF, 2, true, true, kCCTexture2DPixelFormat_PVRTC2},
// 11: PVRTC 4BPP RGB
- {GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG, -1, -1, 4, true, false, kCCTexture2DPixelFormat_PVRTC4},
+ {GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG, 0xFFFFFFFF, 0xFFFFFFFF, 4, true, false, kCCTexture2DPixelFormat_PVRTC4},
// 12: PVRTC 4BPP RGBA
- {GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG, -1, -1, 4, true, true, kCCTexture2DPixelFormat_PVRTC4},
+ {GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG, 0xFFFFFFFF, 0xFFFFFFFF, 4, true, true, kCCTexture2DPixelFormat_PVRTC4},
#endif // (CC_TARGET_PLATFORM == CC_PLATFORM_IOS)
};

0 comments on commit baeb897

Please sign in to comment.