From 126ec18a8968142ea4041452d61a6db4d92065e6 Mon Sep 17 00:00:00 2001 From: andyque Date: Mon, 15 Sep 2014 17:59:51 +0800 Subject: [PATCH] add video player debug draw config --- cocos/ui/GUIDefine.h | 1 + cocos/ui/UIVideoPlayer-ios.mm | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/cocos/ui/GUIDefine.h b/cocos/ui/GUIDefine.h index f12bde90de..4a3e0b73cb 100644 --- a/cocos/ui/GUIDefine.h +++ b/cocos/ui/GUIDefine.h @@ -67,5 +67,6 @@ #define CREATE_CLASS_WIDGET_READER_INFO(className) \ cocos2d::ObjectFactory::TInfo(#className, &className::createInstance) \ +#define CC_VIDEOPLAYER_DEBUG_DRAW 0 #endif /* defined(__TestCpp__GUIDefine__) */ diff --git a/cocos/ui/UIVideoPlayer-ios.mm b/cocos/ui/UIVideoPlayer-ios.mm index 064ee363a4..c5e599bfca 100644 --- a/cocos/ui/UIVideoPlayer-ios.mm +++ b/cocos/ui/UIVideoPlayer-ios.mm @@ -278,7 +278,7 @@ VideoPlayer::VideoPlayer() #if CC_VIDEOPLAYER_DEBUG_DRAW _debugDrawNode = DrawNode::create(); - addchild(_debugDrawNode); + addChild(_debugDrawNode); #endif } @@ -338,7 +338,7 @@ void VideoPlayer::draw(Renderer* renderer, const Mat4 &transform, uint32_t flags Point(size.width, size.height), Point(0, size.height) }; - _debugdrawNode->drawPoly(vertices, 4, true, Color4F(1.0, 1.0, 1.0, 1.0)); + _debugDrawNode->drawPoly(vertices, 4, true, Color4F(1.0, 1.0, 1.0, 1.0)); #endif }