阴影这块确实是难点。说到阴影就必须提到投影矩阵、模板值为1和2时分别渲染。说来话长,仅仅放上代码,供日后查阅。 1 /** 渲染墙面和阴影 */ 2 void CPlanarShadow::Render() 3 { 4 glClear(GL_STENCIL_BUFFER_BIT); ...
分类:
其他好文 时间:
2014-12-05 23:53:10
阅读次数:
227
Gray CodeThe gray code is a binary numeral system where two successive values differ in only one bit.Given a non-negative integernrepresenting the tot...
分类:
其他好文 时间:
2014-12-05 16:49:10
阅读次数:
180
ArrestTime Limit: 1000msMemory Limit: 32768KBThis problem will be judged onHDU. Original ID:441164-bit integer IO format:%I64d Java class name:MainThe...
分类:
其他好文 时间:
2014-12-05 16:48:25
阅读次数:
229
在Debian下安装完Vbox,结果创建虚拟机,发现只有32 bit的version。 如下图: 实际上,操作系统和Vbox 的安装包,装的都是64 bit。root@dave:/usr/bin# uname -aLinux dave 3.2.0-4-amd64 #1 SMP Debian3.2.63-2 x86_64 GNU/Linu...
分类:
其他好文 时间:
2014-12-05 15:34:35
阅读次数:
218
原资源链接为:Bitmark
其中各个模块代表的含义:
- Set S: 初始值s
- Set bit(j): s or 第j位
- Check bit(j):s and 第j位
- Toggle bit(j):s xor 第j位(相同的bit为0,不同则为1)
- Clear bit(j位不为1): and 运算
- Least ...
分类:
其他好文 时间:
2014-12-04 20:06:09
阅读次数:
789
Bloom filter 思路 用多个不同hash 来记录,比如遇到一个 love 有4个hash function 映射到4个bit位置,如果所有位置都是1 那么认为之前已经遇到love这个词(有一定错误概率),如果有任何一个位置是0,那么表明love这个词之前没有遇到(100%这样) Count...
分类:
其他好文 时间:
2014-12-04 17:30:57
阅读次数:
186
1. iOS APP Project or ?Mac APP Project编译错误提示: “The run destination My Mac 64-bit is not valid for Running the scheme ‘***‘. The scheme ‘***‘ contains no buildables that can be built for th...
分类:
移动开发 时间:
2014-12-04 14:08:35
阅读次数:
183
CRC32:CRC本身是“冗余校验码”的意思,CRC32则表示会产生一个32bit(8位十六进制数)的校验值。由于CRC32产生校验值时源数据块的每一个bit(位)都参与了计算,所以数据块中即使只有一位发生了变化,也会得到不同的CRC32值.CRC是一种数据错误检查技术,它可以确保最初写入镜像文件的...
分类:
其他好文 时间:
2014-12-04 13:44:55
阅读次数:
498
CRC32:CRC本身是“冗余校验码”的意思,CRC32则表示会产生一个32bit(8位十六进制数)的校验值。由于CRC32产生校验值时源数据块的每一个bit(位)都参与了计算,所以数据块中即使只有一位发生了变化,也会得到不同的CRC32值.CRC是一种数据错误检查技术,它可以确保最初写入镜像文件的...
分类:
其他好文 时间:
2014-12-04 13:32:17
阅读次数:
169
The gray code is a binary numeral system where two successive values differ in only one bit.
Given a non-negative integer n representing the total number of bits in the code, print the sequence of...
分类:
其他好文 时间:
2014-12-04 08:47:00
阅读次数:
168