tips

1.首先setMidpoint()函数是设置进度条的起始点,(0,y)表示最左边,(1,,y)表示最右边,(x,1)表示最上面,(x,0)表示最下面。

然后setBarChangeRate()函数是用来设置进度条动画方向的,(1,0)表示横方向,(0,1)表示纵方向。

2.CCRenderTexture类可以用来截图和存储图片,貌似很强大,下面是cocos2d源码关于CCRenderTexture类的介绍

 CCRenderTexture is a generic rendering target. To render things into it,

 simply construct a render target, call begin on it, call visit on any cocos2d

 scenes or objects to render them, and call end. For convenience, render texture

 adds a sprite as its display child with the results, so you can simply add

 the render texture to your scene and treat it like any other CCNode.

 There are also functions for saving the render texture to disk in PNG or JPG format.

恩, 这个class是个好class
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值