我的环境是cocos2dx 2.x的版本 【CCRenderTexture】 CCRenderTexture这个动态纹理类,顾名思义就是可以动态创建纹理图片。 屏幕截图主要步骤: > 开始截图:render->begin(); > 遍历场景:scene->visit(); > 结束截图:render ...
分类:
其他好文 时间:
2017-02-10 20:44:49
阅读次数:
182
题目 Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary representation. Note: The given i ...
分类:
其他好文 时间:
2017-01-31 14:27:56
阅读次数:
253
WPF的ImageBrush是一个比较常见也比较复杂的笔刷,它继承自图块笔刷(TileBrush)。使用图块画笔绘制区域涉及以下三个组成部分:内容、基本图块和输出区域。基本输出过程如下图所示: 其中,图块部分有Viewbox控制,输出区域有Viewport控制,它们默认情况下都是一个(0,0,1,1... ...
题目链接:hdu 3487 Play with Chain 题意: cut a b c: 将a到b区间剪切下来,放在第c位置的后面。 flip a b: 翻转a到b区间 题解: 第一个操作,选通过旋转,然后使a到b区间变成根的右儿子的左儿子,然后剪掉。 再找到c+1的位置,接上。 第二个操作,区间标 ...
分类:
其他好文 时间:
2017-01-24 13:34:01
阅读次数:
153
Java NIO中的Buffer用于和NIO通道进行交互。如你所知,数据是从通道读入缓冲区,从缓冲区写入到通道中的。 缓冲区本质上是一块可以写入数据,然后可以从中读取数据的内存。这块内存被包装成NIO Buffer对象,并提供了一组方法,用来方便的访问该块内存。 下面是NIO Buffer相关的话题 ...
分类:
编程语言 时间:
2017-01-22 15:06:01
阅读次数:
204
Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary representation. Note: Example 1: Exa ...
分类:
其他好文 时间:
2017-01-12 22:38:41
阅读次数:
245
Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary representation. Note: The given inte ...
分类:
其他好文 时间:
2017-01-12 13:04:36
阅读次数:
239
CSS代码: .box { width: 355px; height: 500px; padding-top: 30px; padding-bottom: 30px; margin-left: auto; margin-right: auto; position: relative; } .list ...
分类:
其他好文 时间:
2017-01-09 14:23:00
阅读次数:
235
1 // UIView.transition 2 3 // 1、可以设置从一个View到另一个View的转场动画 4 // UIView.transition(from: , to: , duration: , options: , completion: Void)?##((Bool) -> Vo... ...
分类:
其他好文 时间:
2017-01-03 20:46:53
阅读次数:
185
NIO的Buffer提供了一个可以不经过JVM内存直接访问系统物理内存的类——DirectBuffer。 DirectBuffer类继承自ByteBuffer,但和普通的ByteBuffer不同,普通的ByteBuffer仍在JVM堆上分配内存,其最大内存受到最大堆内存的限制;而DirectBuff ...
分类:
编程语言 时间:
2016-12-30 02:17:07
阅读次数:
171