小说网 找小说 无限小说 烟雨红尘 幻想小说 酷文学 深夜书屋

2014年3月24日

cocos2dx中的精灵CCSprite

摘要: 什么是精灵(CCSprite),在官网文档中是这么定义的SpritesA cocos2d CCSprite is similar to sprites you find in other game engines. It is a 2D image that can be moved, rotat... 阅读全文

posted @ 2014-03-24 10:13 牛栏山1 阅读(108) 评论(0) 推荐(0)

cocos2d-x中的尺寸之三

摘要: 通过上面两个文章的分析,我们在这个博文里做个总结:CCEGLView::getFrameSize()返回的是窗口相对于屏幕像素的尺寸,这个尺寸,只要窗口没变化,值就不会变化CCDirector::getWinSize()返回的是窗口自定义像素的尺寸CCDirector::getWinSizeInP... 阅读全文

posted @ 2014-03-24 09:09 牛栏山1 阅读(72) 评论(0) 推荐(0)

cocos2d-x中的尺寸之二

摘要: 接下来我们再做些坏事,比如给EGLView设置分辨率,代码如下: pEGLView->setDesignResolutionSize(240, 320, kResolutionExactFit); CCSize size; size = pDirector->getWinSize(); CCLOG... 阅读全文

posted @ 2014-03-24 08:52 牛栏山1 阅读(120) 评论(0) 推荐(0)

导航