换了蓝牙模块后板砖变Wii!
痛苦的是后来PDA又板砖了……

posted @
2008-08-25 14:04 eygneph 阅读(36) |
评论 (1) |
编辑
没有瞎升级,没有XXOO,放在丈母娘家很长时间,昨天开机时发现一直是红灯,开不了机了。。。
隐约觉得有张盘在里面,不知道是不是哪位小朋友把dvd扔了进去。。。
总之,电源问题还是主机问题,都还没定论,下周拿回家彻底清查!
posted @
2008-08-11 15:36 eygneph 阅读(43) |
评论 (0) |
编辑
这两天没有条件写代码,只能看点闲书,不料除了获得了丰富的历史人文知识之外,还发现了科学技术的一些共通性。
说起来非常早期的火铳,通过火药爆炸来弹射铅石。但早期火铳装填火药和弹射物的过程又特别耗时,加上战场形势瞬息万变,骑兵快速冲击下使得火铳神机无法发挥应有的战力。于是明朝沐英和后来的普鲁士腓特列二世,分别发明了一种战术:三线战法。即火铳队分三排,一排率先射击,随后立即退到后列装填弹药,由第二排火铳继续射击,之后也退下,然后第三排上……循环往复,以此解决装填弹药的时间差问题。
搞图形的、搞多核的你,难道对这个战法会不熟悉么?这就素那double/triple buffer啊!!!
posted @
2008-08-10 20:35 eygneph 阅读(27) |
评论 (0) |
编辑
目前在gameplay中应用物理特性的游戏还很少,一方面是技术原因,很多实时模拟的方法存在稳定性和震荡的问题,造成的众多bug使得设计师不愿意在使用物理特性驱动gameplay;另一方面也是技术和应用分离的原因,很多设计师没有花很多时间考虑物理特性和gameplay之间的关系,或者很多程序员也根本不了解目前物理特性可以实现的效果、可以辅助gameplay的地方。退一步来讲,即使程序员们了解,他们和设计师之间也未必有良好的沟通交流。
对此我有以下一些建议,设计和程序都可以看看。
这里有一个网站,专门对拥有物理特性(或主推物理特性)的游戏发表试玩评论:
http://www.fun-motion.com/ 对物理特性不了解的设计师和程序员可以从中发现不少优秀的游戏idea。其中我最看好的是Armadillo Run。
目前物理特性应用最普遍的刚体物理模拟,已经有不少优秀的开源项目可以参考、甚至使用。Bullet和ODE都是可以考虑的选择。也有很多游戏应用了刚体物理特性(虽然很少是影响gameplay的),如half-life 2。
还有一类是柔体模拟,这方面应用还很少,而且即使有应用也是基于简单的质点-弹簧模型。我相信乐克乐克是使用了这一类的模型。除此之外,PS Network上的鸭子游戏,虽然我没机会玩过,但从各方面收集的信息看来,应该也是应用了一定的柔体模拟。这方面我认为绝对缺乏深度的gameplay挖掘,值得关注。
再有是衣物(布料)模拟。这方面大多数游戏是将其作为eye candy来对待的,很多日本3D格斗游戏都是这种应用的代表作。技术方面我不太了解,但我想对于avatar,衣物模拟也有必要进行研究和挖掘。
最后是流体模拟。流体很多人会想到液体,其实很多气体和烟雾都是流体模拟的范畴。其中又分为基于grid的和基于粒子的做法,但无论哪种做法,目前将其应用到gameplay的游戏也还是很少。这方面我觉得至少是2D的流体模拟,或者以2D流体模拟伪装进行3D流体模拟,已经在技术上非常可行了。再一此提到鸭子游戏,是我所知不多的,把流体模拟作为主要gameplay的一款游戏。
以上说了这么几种技术,都是我认为目前gameplay还很缺乏的应用。而且相信会在今后多核的趋势下,越来越适合实时游戏应用。
posted @
2008-08-01 23:22 eygneph 阅读(47) |
评论 (0) |
编辑
流体计算的主要问题就是解NS方程,至于怎么解就是各家之长了。Alias的大牛Stam在上世纪末提出了的稳定解算流体的做法,10年之后来瞅瞅……
把流体解算过程看作一个积分过程,但积分一不小心就会整成不稳定的,原因很多,如步长大于某种方法的稳定步长啦,没把质量守恒、能量守恒考虑进去啦,等等。
Stam用了个隐式积分的方法解决稳定积分的问题,以前是直接显式积分(加dt),现在是倒退回dt的时间,拿t-dt时刻的量,但这额外需要计算一个线性方程组。由于这个线性系统非常稀疏,可以使用Gauss-Seidel迭代法解这个系统(试下来性能令人满意)。
好,稳定的积分方法解决了,现在看质量守恒。通常根据NS方程几个项(平流、扩散、外力作用)积分下来,通常不会是质量守恒的。如果把符合质量守恒的状态可视化成所有一个平面的点集,那么每次积分的结果都可能把一个点(状态)带离这个平面,也就是破坏了质量守恒的条件。那么我们要在积分末尾进行一个projection的动作,把状态投影到这个平面上,也算满足了质量守恒的先决条件。可能这个投影的动作不那么科学,但至少满足了“稳定”的需求。投影的依据是Helmholtz-Hodge分解法,这个方法指出:任何向量场(我们所积的速度场)都可以唯一分解为一个收敛的向量场(即不发散)和一个标量的梯度场。
w = u + del(q) ==> u = w - del(q)
(del是del operator,向量微分算子,是一个记号,和向量一起使用才有微分的意义)
那么我们只要取这个收敛的向量场作为速度场即可,这个操作就是投影。至于求这个q,又需要解一个线性系统,
del(w) = del^2(q)
这是个泊松方程,也存在一些数值方法可以解它。总之得出q后也得到了最后的投影操作,也完成了整个解算的过程。
下面是在PS3上试验的结果,二维、用CPU更新的纹理,还没捣腾出截屏功能,凑合看……



posted @
2008-07-27 17:21 eygneph 阅读(35) |
评论 (1) |
编辑
托几个大黑客的福,firmware 2.0及以下的PS3可以使用“部分”GPU(Nvidia RSX)的功能。最近花不少时间在这上面,也让自己对GPU底层和工具链有个大概了解。
在PS3里,在最底层有个提供硬件功能接口的操作系统,姑且称之为Level 1。其上的任何操作系统都使用需要通过Level 1的API和硬件接口进行交互,姑且称之为Level 2。以这个概念,目前PS3上运行的默认操作系统(GameOS)和其他第三方可提供的操作系统(OtherOS)都是Level 2 OS。SONY出于很复杂的目的,在一定程度上开发了第三方操作系统的可能性,称之为OpenPlatform。具体来说它是安排了一个自己的职员,专门为PS3维护linux内核。由于内核必须是开放的,尽管其中只有很少对于Level 1 OS的系统调用且没有注释,还是给了黑客们机会,这里有一个收集并描述Level 1 API的wiki:http://wiki.ps2dev.org/ps3:hypervisor
一切的hacking都从这些API开始。通过摸索、试验、逆向工程分析dump,并利用nouveau开源驱动项目,最终黑客们找到了一些解决办法来驾驭GPU。
Nvidia系列GPU都有一个FIFO的环形队列(command buffer)供存放GPU指令。这块存在于系统内存的区域大约是64KB(还是2MB记不清?)。有一个类似于程序指针PC的指针(寄存器),指向FIFO。而另一个指针(寄存器)则标注着目前GPU的队列尾。一旦这两个指针不匹配,前者就会一个个将队列中的指令DMA到GPU,直到和后者重合。所以我们要做的就是把正确的指令填入这个FIFO,以期待最后GPU会把我们的指令一一执行。
由于实现一套driver和图形API的代价太大,几乎很难以个人力量完成。所以没有driver,没有图形API,没有任何资源管理,所有的一切都只有FIFO和指令。这有点类似官方SDK中的libgcm库,可以绕过PSGL的下层,对command buffer进行一些操作,如传入预编译的指令队列等。
其实最令人感到不适的还不是图形API的缺失。由于硬件指令是不公开的,所以这里需要通过nouveau的项目资源,以及一些dump来分析NV40系列的指令。有些可以正常使用,另一些则不然(如vp中的ADD和fp中的MOVR,总是无法正确输出float4的色彩)。还没完,即使完全掌握了这些硬件指令,没有一个assembler或高级语言编译器的话,写shader会变得无比痛苦。所以目前的工具链是这样的:在PC上写完Cg,使用Cg编译器输出vp20和fp30的汇编代码。在PS3 Linux上已经有写好的assembler,可以将汇编代码翻译成硬件指令。所以写一个shader会在两个平台上来回切换,忙的不亦乐乎。
我想以后的工作可以包括一些简单的资源管理和队列管理的工作,包括显存分配、资源缓存和换出,这样一个简单的"driver"可以大大增强目前的创造能力,以及今后对于Cell的开发的可视化能力。
最后放一张screenshot,利用SDL可以近乎完美使用SIXAXIS进行操纵。

posted @
2008-07-24 00:34 eygneph 阅读(57) |
评论 (0) |
编辑
如果你的firmware在2.10以上,可以不用看了。因为2.10之后索尼把RSX的访问彻底封死了。
首先,下载FC7 powerpc的DVD版本,烧录成盘片。跟在ps3上安装任何linux一样,先分区和安装otheros。启动otheros。把光盘放入光驱,重启机器。
随anaconda安装,把必要的东西勾上,开始安装。大约需要几个小时。
安装完毕后,系统重启。但这时系统无法重启,需要长按电源按钮5秒强制关闭机器。这个问题在稍后新安装的kernel中会解决。
启动后,root登入。从yum install几个必要的软件,如wget rsync等。然后从网上找geoffery的一个CELL-Linux addon iso。版本应该要20071023的。他本人(ps3版kernel的维护者)的网站上已经没有了,需要找个镜像。因为据试验下来,只有这里面带的2.6.23 kernel source是可以编译出可以在2.10以下firmware跑而且重启和关机正常的内核。
把iso mount起来,里面的src/linux-2.6.23-20071023.tar.bz2就是内核源码。tar jxvf一把把bz2文件解压到/usr/src中。然后到解压后的/usr/src/linux-2.6.23中,从./arch/ps3/中拷贝.config文件出来(路径可能有误),到内核源码的根目录。这包含了ps3内核所需的基本配置。但是有一个内核选项是安装rsx支持所必须要选择的,所以make menuconfig一把,菜单中在'enable loadable module support',勾上'module versioning'。然后存盘退出。
接着就是标准的编译内核。
make
make modules
make modules install
这个大约需要半个多小时吧,之后把/boot中的几个boot config和内核备份一下。然后懒人就make install以下,安装到/boot目录。把/boot/etc/yaboot.conf配置一下,依样画葫芦。
好吧,祈祷内核可以正常boot。如果无法启动,用原来的内核启动,再重新搞一下。其中的debug步骤就不说了。
启动成功?恭喜。接着从ps2dev.org的svn服务器上把IronsPeter的libps3rsx代码抓下来。当然你可能需要先yum install svn。svn地址是svn://svn.ps2dev.org/ps3ware
sync完以后,找到libps3rsx目录,在./src/init中有个startup.sh脚本,执行一下,会自动编译内核模块,并自动insmod进去。如果你没有做前面的内核重编译,dmesg |tail你将会得到一个magic version not match的错误。所以不能偷懒。
好了,如果上述都没有问题的话,libps3rsx已经安装在内核中了。这时候到./src/example/simple_dxt1中,make一把,运行./ps3gpu看看,有没有一个兽人?

如果需要X window也能受益于RSX,可以按照boxbuilder的教程来。下面简述:
首先yum install X11-server-sdk。然后:
git clone http://mandos.homelinux.org/~glaurung/git/xf86-video-ps3.git ./xf86-video-ps3.(todaysdate)
如果由于众所周知的问题git不能访问这个网站,那么可以把域名拿ip地址91.121.147.47代替。
抓下来的xf86-video-ps3代码,
./configure -prefix=/usr
make
make install
然后将kernel启动option中的rhgb删除(我没有遇到这个问题,只是boxbuilder教程上有这么写)。
再修改/etc/X11/xorg.conf,记得做好备份:
将Driver "fbdev"改为Driver "ps3",并可以加以下extension:
Section "Extensions"
Option "Composite" "Enable"
EndSection
存盘重启。再次登录后,先确保ps3rsx.ko模块已经insmod且已初始化rsx(libps3rsx/src/init/init运行一下)的情况下:
startx &
即可启动利用RSX渲染的X Window了。如果没有初始化RSX或内核模块都没加载的话,X Window会hang在那里。这时候可以重启换回原来的fbdev版本,也可以重启后先加载内核模块、初始化RSX后,再进入X Window。
posted @
2008-06-18 23:21 eygneph 阅读(61) |
评论 (0) |
编辑
详情请查询官网。
http://www.spore.com/
果不出所料,看上去应是隐式表面甚至是metaball做的建模。但有一些parts只是多边形attach在一起。应该是种混合的方式。不过总体来看效果不错。
贴几张做的生物,够帅吧。
posted @
2008-06-18 21:44 eygneph 阅读(142) |
评论 (1) |
编辑
Spore.com, .... will essentially serve as a social networking site where users can share their creatures (which, in true Web 2.0 fashion, are tagged and can then be sorted by users) and interact with one another.
--comment: Highlighting "social networking"
And in a clever move, much of the user-generated data from Spore.com is output in RSS or as embeddable HTML, and can be easily integrated into blogs and other social networking sites such as Facebook.
--comment: Highlighting Facebook
As a side note, the procedural nature of Spore's creatures mean that data is enormously compressible; creatures are exported directly to PNG image files, which can be viewed in regular image software but which also contain all the information needed to load the creature up in the game. They are only a few dozen kilobytes in size.
--comment: 10k bytes per creature, benefits from implicit surface modeling(or some other neat techniques?)
EA has also signed partnerships with services such as YouTube and an online comic-creating website. With a couple clicks, Spore will upload a demonstration video of your creature directly to a YouTube account. There is even a button that automatically creates an animated GIF avatar of your creature.
-- comment: Highlighting YouTube
Most impressive, however, is the range of automatically-generated animations that is instantly compiled.
-- comment: Good work, Chris!
http://www.gamasutra.com/php-bin/news_index.php?story=18992
posted @
2008-06-12 15:21 eygneph 阅读(31) |
评论 (0) |
编辑
预定于今年9月份发售的Spore已经吸引媒体的眼球超过4年了。自从GDC2004 Will Wright关于Spore的一部带demo的演讲[1],有关它的实现细节已经陆续暴露出来了,尤其是GDC2007 Chris Hecker关于带语义的动画编辑[2]。
我想讨论的是关于它procedural modeling的部分。其实建模部分由于演示视频,可以很直觉地知道是基于隐式表面的。由于隐式表面几个特殊的性质,如混合简单、CSG操作简单、杜绝mesh常有的defects。而且一些玩家网站也报道了Spore的编辑器使用了"metaball"[3]。
既然如此,根据视频中的细节操作,我想Spore的建模实现应:
1、不会直接使用metaball进行建模,由效率和建模效果来看也不应该;
2、通过一些预定义的,由隐式表面描述的part,来组装生物;
3、躯干通过match point的隐式表面生成算法生成,但考虑到效率可能只有有限的点可以控制,但这些点的位置可以在表面上的任意位置[4] [5];
4、躯干和肢体的混合,可能会采用convolution的方式进行混合,但也可能不,因为膨胀的效果可能不明显[7];
5、使用一些带阶跃的隐式函数,来方便对隐函数求值时culling(或性能优化);
6、用户结束任一编辑操作,就把定义好的隐式表面多边形化以供实时渲染器渲染[6]。
[1] [SPORE] Demonstration by Will・Wright (Part1)
[2] Chris Hecker, How To Animate A Character You've Never Seen Before
http://www.chrishecker.com/How_To_Animate_a_Character_You%27ve_Never_Seen_Before
[3]http://www.next-gen.biz/index.php?option=com_content&task=view&id=3454&Itemid=2
[4]Greg Turk, James F. O'Brien, Shape Transformation Using Variational Implicit Functions
[5]Yutaka Ohtake et al, A Multi-scale Approach to 3D Scattered Data Interpolation with Compactly Supported Basis Functions
[6]Jules Bloomenthal, Polygonization of Implicit Surfaces
[7]Jules Bloomenthal, Convolution Surfaces
posted @
2008-06-07 14:59 eygneph 阅读(40) |
评论 (1) |
编辑
很久没有关注NPR了。去年年底时,Lee Markosian把很久以前承诺要公开的jot代码,放到了google code上了。有需要的同学可以……
http://code.google.com/p/jot-lib/
虽然过了很长时间但终于兑现承诺啦~~
posted @
2008-06-02 16:17 eygneph 阅读(41) |
评论 (0) |
编辑
nVidia和NaturalMotion建立伙伴关系...一个非常好的animation synthesis authoring tool/middleware制造商,产品是endorphin和europhin。如果对这两个产品不那么了解的话,那么这么说...GTA4用的就是他们的技术。收购了Ageia之后nVidia果然气势如虹...
http://www.gamasutra.com/php-bin/news_index.php?story=18780
posted @
2008-05-28 10:48 eygneph 阅读(31) |
评论 (0) |
编辑
posted @
2008-05-13 09:54 eygneph 阅读(38) |
评论 (0) |
编辑
当然软阴影对于游戏来说早就不是什么新鲜事了。不过,软阴影的全部不只是把shadowmap怎样灵活投影一下+PCF就搞定,物理正确的实时软阴影却仍然具有挑战意义。尽管大多数玩家区分不了HDR和Bloom,但人活着毕竟要做点有意义的事,有点追求不是吗?
Ahem,早在2002年, P.P Sloan的一篇"Precomputed radiance transfer for real-time rendering in dynamic, low-frequency lighting environment"(真够长的,后面还有更长的)被siggraph收录,是为大家耳熟能详的PRT。PRT可以很好的处理静态场景下,一般化的distant light对场景的光照和阴影。它需要额外的预处理过程以计算transfer function,处理量较大而且根据你对最终效果的需要你可能要一个GI solver来帮你解决计算transfer function的问题。PRT效果是很好但由于上述的限制,MSR的研究员们继续地搞……
时光飞逝,让我们跃过LDPRT直接来到Shadow Field……2005年, 周昆、胡耀华他们的一篇siggraph "Precomputed shadow field for dynamic scenes"利用先前解决的SH Product,以及光源和遮挡物预先计算所谓的source radiance field(SRF)和object occlusion field(OOF),可以解决一定数量下动态物体和动态local光源的光照和阴影问题。由于数据量问题,还是使用SH作为压缩(也有wavelet的选择,但由于基的数量太多,wavelet的版本更慢限制更多如光源的旋转),所以也是更适合低频的环境。相比PRT,这个做法已经减少了很多预处理的工作,并能解决动态光源和动态物件。一大飞跃不是么?
马不停蹄,稍后的2006年里,siggraph "Real-time soft shadows in dynamic scenes using spherical harmonic exponentiation"中,认知到先前shadow field的很大部分计算消耗在SH product上,场景中物件或光源越多越复杂,SH product也会发生越多次。基于这点,把SH的计算转换到log space,这样一来多次的SH product就变成无比简单的SH add。然后把log space中的计算结果累加到结束为止,再经过一次exponentiation pass,就还原了原先在shadow field中昂贵的多次SH product。此外还有简化模型为球集,并为在CPU上为接收面选择一个hierarchy tree cut以简化计算且可避免错误地多次累加shadow。事已至此,已经有一个相当不错的动态(物件、光照)低频光照环境下的软阴影解决方案了。
之后2007年,P.P Sloan在上面的基础上又有一篇"Image-based Proxy Accumulation for Real-time Soft Global Illumination"。这篇的贡献主要把上面一篇SHEXP的CPU计算都纳入了GPU中,并可以模拟一把低频的GI效果,当然这GI很粗略啦,权当一看。
呼……soft shadow的科技树造到底了?且看今年的siggraph吧!
posted @
2008-04-16 23:27 eygneph 阅读(84) |
评论 (0) |
编辑
跟前次的Nvidia的David Kirk,id的John Carmack一起,Crytek的Cevat Yerli也被拉去聊ray tracing,得到的答复差不多,hybrid可以,全ray tracing?你开玩笑吧……
这里列个三部曲:
David Kirk的
http://www.pcper.com/article.php?aid=530
老卡的
http://www.pcper.com/article.php?aid=532
Cevat Yerli的
http://www.pcper.com/article.php?aid=546&type=expert
posted @
2008-04-16 11:21 eygneph 阅读(52) |
评论 (0) |
编辑
posted @
2008-04-10 15:01 eygneph 阅读(28) |
评论 (0) |
编辑
今年在GDC展台看到的一个demo,2D的引擎给我的印象胜过3D的那个版本。拿质点模拟所有的物质,包括刚体,流体,柔体等,还有假“火”这种带属性传递的质点。
现在已经有demo可以下载运行,想法非常好也非常有趣。事后收到一封信才知道GDC展台上聊了一会的韩国哥们Shin Hyojong也是siggraph作者,有一篇跟Takeo Igarashi是联合作者。世界之小无奇不有……
http://www.octaveengine.com/casual/index.html
posted @
2008-04-09 17:53 eygneph 阅读(34) |
评论 (0) |
编辑
听说全体绝版。混这碗饭人人都要看的书,书商却不再版了——你以为GPG是Maya教材啊,出了8.5扔掉7.0。
还有一事,Graphics Gems从来就不曾引进过,彰显游戏产业技术书籍匮乏且不受重视的尴尬局面。
posted @
2008-04-03 15:22 eygneph 阅读(135) |
评论 (2) |
编辑
posted @
2008-03-31 17:18 eygneph 阅读(39) |
评论 (0) |
编辑
posted @
2008-03-31 15:05 eygneph 阅读(18) |
评论 (0) |
编辑
卡马克大神发话了。
原文出处。
总结如下:
1、指望ray tracing在次时代中替代rasterization不太现实,除非Intel用处理器效能堆出来(Larrabee,我不指望,处理器设计不说,但就开发者培训的工作就没做好)。
2、不做“有道理”的效果,做“好看”的效果才是游戏的正道(博文论据:Halo3 vs Bioshock 或 Halo3 vs Crysis)。
3、Ray tracing和rasterization的混合方式还是有前景的,提到了mega texture(sparse virtual texture)的几何体版本:sparse voxel octree。在合理的数据结构下,使用一定限度的ray tracing会带来很多有趣的结果。
4、多GPU的做法,但受到业界以console为主的限制
5、又拿ageia说事。
6、NV、Intel、AMD你们掐吧,谁有能力听谁的
posted @
2008-03-27 11:40 eygneph 阅读(93) |
评论 (0) |
编辑
为把业余生活搞得专业一点,遂把家里那台PS3用作了svn服务器,折腾了半天,原来很简单的东西被网上文章误导了很长时间,现留笔存证。
Fedora Core 6安装好服务器组件,应该就有SVN了,如果不确定:
$ rpm -q subversion
这时你最好先增加一个svn专用的用户:
$ useradd svnroot
$ passwd svnroot
然后切换到svnroot用户,在用户目录下
$ svnadmin create ./repo
切换为root,将目录的访问权限给改了
$ chown –R svnroot:daemon /your/repo/path
这会建立一个数据库,多了不少文件,ls以确认:
$ ls repo
conf/ dav/ db/ format hooks/ locks/ README.txt
我们不用apache,所以对于conf/svnserve.conf文件,需要进一步的配置,主要需要把权限和权限文件设置一把。这个可以参考手册这里就不详述了。
然后要编写authz权限文件和passwd密码文件,也是参考手册的做法即可。千万不要信一些网上文档,只会让你越搞越复杂。
当然你的服务默认是不会开启的。官方文档说可以用inetd的方式开启,但我没成功,于是用地球人都用的daemon方式启动
svnserve -d -r /home/svnroot/repo
要确认是否成功了,你可以在你的client端telnet yourserverip 3690,如果出现
( success ( 1 2 ( ANONYMOUS ) ( edit-pipeline ) ) )
就说明成功启动了svn服务。
这时候你可以装windows的tortoiseSVN客户端了,装完了重启,然后在浏览器里直接打svn://yourserverip,输入用户名和密码,应该能看到你的svn目录结构了。把你的东西先import进去,然后checkout出来,事成矣。
如果想每次启动时自动启动svn服务,那么编辑/etc/init.d/svn
#!/bin/sh
# subversion initialization routine
svnserve -d -r /your/repo/path
然后
$ chmod 755 /etc/init.d/svn
$ ln -s /etc/init.d/svn /etc/rc.3/S60svn
$ ln -s /etc/init.d/svn /etc/rc.5/S60svn
最后重启即可。
posted @
2007-10-05 15:22 eygneph 阅读(65) |
评论 (0) |
编辑
这么大的个儿,大部分是散热装置。真不知道是显卡插在主板上,还是主板安在显卡上。
posted @
2007-08-27 13:06 eygneph 阅读(48) |
评论 (0) |
编辑
posted @
2007-08-27 13:02 eygneph 阅读(34) |
评论 (0) |
编辑
趁着早上比较清醒时快速浏览了一下JPEG的压缩步骤:
1. 色彩空间转换。RGB->YCrCb,地球人好像都知道
2. 裁剪成8x8像素的小块
3. 离散余弦变换。跟傅立叶变换类似,是空间域到频率域的变换,得到一堆系数
4. 量化。鉴于人眼对低频信号敏感,对高频信号迟钝的特性,这些系数会被除以一个分母,一些高频信号(好像是拥有较小的系数)会被取整成0,所以有些高频信号被丢弃了,或者被走样了
5. 系数矩阵扫描为系数向量
6. 计算8x8块之间的平均差(DPCM)
7. 用RLE压缩各个块的系数向量,可以压缩很多系数向量中由于除法带来的高频的零
8. 哈夫曼编码以方便解压时快速检索
除了第6步的必要性不是很明白,其他我想应该知道是怎么回事了。第3,4步需要一点信号处理的基本知识。果然如老大说,信号的学问真是精深啊。
从上面还可以看出来,信息丢失主要在第4步量化阶段。以后JPEG不要用作中间格式,每次存即使是最高质量,都会造成信号损失!
posted @
2007-08-24 10:25 eygneph 阅读(96) |
评论 (0) |
编辑
请在不确定dest和src是否有重叠时使用memmove,谢谢。
posted @
2007-08-20 11:11 eygneph 阅读(32) |
评论 (0) |
编辑
说的不对请拍砖!Orz
SH是一种特殊的函数,高阶的SH可以还原非常复杂的函数,而低阶的SH比较适合还原低频函数。现代GPU硬件通常支持4个channel的texture,或者支持大顶点格式,这也为4阶以内的SH(需要4^2=16个系数)在GPU上的实现奠定了基础。
很多函数可以近似分解为多个不同相位、不同频率的正弦波,也是傅立叶变换所解决的问题。SH也类似的,由多个基函数叠加合成,对于不同的基函数有不同的系数,使得SH可以模拟很多函数,当然它的特性在图形学的范畴内是比较适合模拟diffuse光照中各向同性的特点。
SH有几个牛逼的特性,一个是rotation invariant,对于旋转,存在一个旋转函数可以把SH旋转过来。还有一个就是dot product,由于正交性,可以把SH函数相乘的积分化解为几个dot product!在我看来这是使用SH的最主要目的了。
在PRT及其变种中,SH对原函数的压缩和还原是作为核心思想直接使用的。而PRT也受到了SH带来的限制,即球谐的特性导致了各向同性,在diffuse情况下工作得很好,而完全不能用在specular的情况下。所以specular的东西还是需要其他的模型去实现。
实现PRT的话,我们这样做:
1)预计算,通过raytracer获得顶点或纹素上的辐射度传递信息,如果你懒得实现一个raytracer的话,你可能只能得到无阴影,无相互反射的N dot L的效果。当然这辐射度信息的部分如果用GPU来加速应该也是可行的。将辐射度信息投影到SH空间,存储辐射度的SH系数。
2)运行时,把球面上的光照向量投影到SH空间,存储为光照SH系数。在shader中通过madd也就是一系列点乘运算将辐射度SH系数和光照SH系数乘起来,就可以得到最终辐射度的效果,将其作为参数加入光照模型即可得到一幅低频的,有软阴影甚至是interreflection的diffuse画面。
当然实际情况远没那么简单,尤其是SH系数的旋转,很烦。目前D3DX中的D3DXSHRotate也只支持最高6阶的SH。
参考资料:
Evaluation of the rotation matrices in the basis of real spherical harmonics
http://www1.elsevier.com/homepage/saa/eccc3/paper48/eccc3.html
Spherical Harmonic Lighting: The Gritty Details
http://www.research.scea.com/gdc2003/spherical-harmonic-lighting.pdf
posted @
2007-08-17 15:19 eygneph 阅读(275) |
评论 (0) |
编辑
http://www.youtube.com/watch?v=Vx4jBzHmcM4
posted @
2007-08-13 10:05 eygneph 阅读(58) |
评论 (0) |
编辑
可能在1-2年内,随着多核和GPU的发展,游戏业就能用上realtime radiosity了。当然不是物理精确的,甚至不是per-pixel精确的,但是撇开PRT,搞个dynamic light + dynamic scene + color bleeding没什么问题。当然我不是说PRT过时了,如果需要精确一点的结果,那么realtime radiosity可以用作offline编辑的工具中,用于快速preview,而最终compile PRT后送入realtime app。一些idea确实比较直观的。
这里有捷克人收集的一堆demo:
http://realtimeradiosity.com/demos/
posted @
2007-08-10 15:18 eygneph 阅读(56) |
评论 (0) |
编辑
posted @
2007-08-08 14:47 eygneph 阅读(60) |
评论 (0) |
编辑
posted @
2007-08-08 12:29 eygneph 阅读(76) |
评论 (0) |
编辑
posted @
2007-08-07 22:45 eygneph 阅读(26) |
评论 (0) |
编辑
Finally!
http://developer.nvidia.com/object/fx_composer_home.html
Key Features of FX Composer 2
- Cross-API Support
- DirectX 9 and OpenGL
- HLSL, COLLADA FX Cg, CgFX shading languages
- User-Friendly Shader Authoring
- Shader Creation Wizard with templates
- Full-featured Code Editor
- Code folding for functions, techniques and passes
- Tab stop display
- Line number display
- External file modification monitoring
- Jump-to-include files
- Properties panel for tweaking shader parameters
- High dynamic range color picker
- Material panel for managing materials
- Display of per-material textures
- Tone mapping for per-material textures
- Easy material creation and management interface
- Hundreds of sample shaders
- NVIDIA Shader Library integration
- Sample projects ranging from simple to complex
- Advanced scene manipulation
- Create and manipulate basic geometric shapes, lights, and cameras
- Import .3ds, .fbx, .dae, .x, .obj files
- Drag-and-drop light binding
- Drag-and-drop texture binding
- Skinning and animation
- Texture Viewer
- Support for .dds, .jpg, .bmp, .png, .tif
- Drag-and-drop textures onto object materials
- mental mill™ Artist Edition
- Artist-friendly visual shader authoring
- Ability to export to FX Composer via CgFX and HLSL
- Convenient Start Page
- Recent projects
- Quick Start Tutorial
- Quick links to User Guide and other useful documentation
- Single-click access to open effects and create new ones
- Single-click access to open COLLADA documents
- Integrated Shader Performance Tuning via NVIDIA ShaderPerf 2.0
- Support for CgFX, COLLADA FX, and HLSL shaders
- Compare shader techniques across multiple GPUs
- View data in tables or graphs
- See shader throughput, register usage, instruction counts, and branching performance
- Convenient Pipeline Integration Features
- Semantic and Annotation remapping
- Advanced Scripting Support
- Full Python scripting
- Custom toolbar for scripting support
- Extensible plug-in Architecture with SDK
- Complete COLLADA support
- Project and Asset Management (Project Explorer and Library Viewer)
- Author COLLADA assets
- Create and remove COLLADA documents
- Move, delete, and copy COLLADA assets across COLLADA documents
- View COLLADA assets by category
- COLLADA format support
- Material Instance Scene Binding
- Material Instance Vertex Binding
- Skinning
- Triangulation with holes
- Support for rendering COMMON Profiles
- Vertex Stream Remapper
- Conversion of CgFX to COLLADA FX Cg
- Comprehensive Undo/Redo support
- Comprehensive Documentation
- User Guide
- Quick Tutorial
posted @
2007-08-06 16:38 eygneph 阅读(107) |
评论 (0) |
编辑
今天开幕,赛事直喷……
posted @
2007-08-06 16:37 eygneph 阅读(20) |
评论 (0) |
编辑
posted @
2007-08-03 10:32 eygneph 阅读(25) |
评论 (0) |
编辑
(\__/)
(='.'=)
(")_(")
posted @
2007-08-02 21:53 eygneph 阅读(13) |
评论 (0) |
编辑
看到首发盛况空前,看到某树和总监(的照片),心里还是很为这游戏高兴的,只希望这次SF事件不要影响太大,毕竟自己还要玩一把呢。
没玩,看过视频,程序上2点意见:
1、Skeleton blending以前不是有的么?到了发布变没了,请知情人告知
2、光照,Lightmap也去掉了,动态光也基本上看不出来,人都是亮的,阴影倒也算了,光照太重要了,不可不察
posted @
2007-08-02 14:40 eygneph 阅读(25) |
评论 (0) |
编辑
|
正常游戏体验 |
作弊游戏体验 |
| 特权用户(道具付费) |
不愿意 |
倾向 |
| 普通用户(免费) |
强制 |
不可用 |
而正常游戏体验又是游戏乐趣最大的所在,所以设计时如何平衡特权用户在这方面的缺憾:
正常游戏体验包括:枯燥乏味的操作和精华部分
作弊游戏体验包括:使用道具和精华部分
即,2种用户在精华部分的体验必须是重合的,这也是游戏统一性的保证。
但要保证精华体验和一些枯燥乏味的操作(如练级)之间的耦合度降到最低,这样才能保证在精华部分特权用户和普通用户的体验是一致的,甚至特权用户的体验更强烈。
posted @
2007-08-01 14:39 eygneph 阅读(17) |
评论 (0) |
编辑
Posts - 61, Comments - 10
兄弟们,不管写的多烂,看贴要回贴啊
posted @
2007-07-31 17:58 eygneph 阅读(42) |
评论 (2) |
编辑
smbmount被改没了,现在用cifs作为文件系统加载Windows共享文件夹:
mount -t cifs //winhost/sharedfolder /mnt/winfs
mount -t cifs -o username=xxx,password=yyy //winhost/sharedfolder /mnt/winfs
posted @
2007-07-29 14:07 eygneph 阅读(43) |
评论 (0) |
编辑
As usual, assume you're installed with fc6. Make sure your yum works well, repository is set to the official url and mirrorlist.
1) yum install mplayer
2) yum install mplayer-gui
3) vi /etc/mplayer/mplayer.conf
vo = sdl
ao = sdl
4) In control panel, set sound system to OSS(Open Sound System) and click apply.
And you're finished!
Tips: Never use GUI preference to save your options, it will overwrite your video and audio settings.
If you happened to do so, never mind, edit ~.mplayer/gui.conf, change vo and ao option to sdl and restart MPlayer.
posted @
2007-07-29 13:58 eygneph 阅读(53) |
评论 (0) |
编辑
有幸参加了IBM的这个training,不过由于IBM自己管理的失误,很多人没能知道培训地点,在此特别鄙视一把。为期2天的training我参加了1天半,由2个IBM北京的讲师轮番上阵,嗯,分别是龚大和潘大。废话少说,切入正题。
首先是Cell的架构,应该已经很熟悉了,即使你不鸟IBM,PS3的硬件spec上也写着:PPE+8SPE,9个核,10个硬件thread。PPE是legacy Power5的架构,把它当Power5使没问题,完全兼容,有L1,L2两个cache。8个SPE,包含SPU向量处理器,为了向量处理和SIMD设计的,128个128bit通用寄存器(真多),dual issue channel,非常快,没有硬件cache设计。SPE还包含LS(256K),用于SPU的本地存储器,latency也非常小、MFC用于DMA控制。EIB作为PPE和SPE之间的高速总线。
然后是开发环境。Cell SDK目前是2.1版本,跑在linux上。龚大说9月份会release 3.0,里面xlc的一些超强优化特性以及FDPR-Pro的SPE版本都会出现。好,不管以后的版本多么fancy,先来看手头有的东西: toolchain和compiler,当然是C/C++的,分别对应PPU的和SPU的有2份,所以会编译出两种executable格式。编译器可以用gcc或者IBM自己的xlc,据说xlc稍后的版本会有auto vectorization之类的功能粉墨登场,敬请期待。其他的工具链的东西可以参考普通x86上linux的那一套,基本用法当然是一模一样的。除此之外,IBM的工程师们还提供了很多profiling工具,比如静态的SPU timing工具,可以生成汇编代码和时序图、还有FDPR-Pro,对二进制代码进行无人工参与的优化,不过目前只对应PPU。为了方便大家发挥Cell的实力,IBM中国的lab也搞了一个叫ALF(Accelerated Library Framework)的东西,据说可以大大简化程序员拆分workload的工作,可以以脚本(还是GUI?忘记了)的方式定义workload,然后可以让程序自动优化处理时机,这个东西在培训中没有讲到,看来要好好关注一把。 最后么,还有些Eclipse插件,以及Cell的官方模拟器,这玩意儿将在运行时profiling中起到非常重大的作用,可以在里面看到每个cycle、SPU执行状态以及CPI(Cycle Per Instruction,据说普通程序可以优化到1.0左右,变态计算可以到0.6-0.7)和miss branching、dural issue rate等重要profiling数据,但缺点就是太慢,我在IBM的教室里,P4的老机器,跑win2k,再跑vmware上的fc6,再在fc6里跑simulator,又起来一个linux,即使是fast mode,模拟器工作的都很慢,如果是cycle mode,据说5秒钟的程序可以跑上4个小时。
以上就是IBM目前能提供给Cell开发者的一些东西,当然也可以去alphaworks多逛逛,看看有什么新货。
接下来说说如何使Cell变得更强。基本上,PPE会作为一个程序协调者的身份,用来调度所有SPE的工作、准备SPE的数据等等。而大量的数据密集的计算将落在这8个SPU的身上。SPU不要看它小,小也是小强,前面说了,是个高速向量机,所有的指令都是向量指令,即使是标量的计算也要转换到向量指令做。想起什么来了?GPU是吧。我个人感觉Cell的位置是在传统CPU和GPU之间,对pipelining的要求没那么变态,也不会有什么shader标准来让你束手束脚的做GP,但是又拥有general processor不具备的变态的向量处理能力,比较灵活,但效率可能没有GPU这么高,毕竟人家太专业了(PS3上folding at home还是比不过GPU的版本,但是比PC CPU版本要强多了)。哦,说远了。话说要让SPU发挥能力,主要看2方面。一是PPE能不能对SPE进行有效通信,二是SPE如何利用向量指令并优化自己的算法。那么基本上这俩都是巨大的命题。以下简要谈谈:
PPE和SPE之间通信主要3种方式:mailbox,signal,DMA。感觉mailbox和singal有点类似,都像是信号量一类的同步对象,不过是硬件级的。那么既然分这2个东西,那么一定是有不同的用途,这点需要稍后再作了解。DMA就很直观了,有了mailbox和signal做同步,那么DMA就可以放心的进行数据传输了,由于SPU只能对LS进行操作,所以会有大量的代码涉及到同步和DMA。
至于代码向量化,IBM的best practice是,如果对Cell和待实现的算法不熟悉的话,建议先在PPE上做scalar的版本,然后可以一步步移植到SPE上,比如先做内存对齐,再将scalar操作变为向量操作,最后审查算法的数据无关性,是否可以并行操作,以及可否分开到其他SPE上去完成。当然如果是Cell大师的话,直接写就可以了,不过貌似大师还没有生出来。Rapidmind也提供了很high level的解决方案,号称不用考虑硬件架构来写多核程序,不过貌似IBM的人不鸟之,还是觉得自家的ALF爽。不过IBM也承认这是个很大的问题,也不是一朝一夕可以解决的(Free lunch is over)。
那么以上基本就是第一天的内容,第二天就去了个上午,不过software programming model确实值得一听。这里就列举了几个有用的、常用的编程模型。比如streaming,几个SPU并行处理无关的数据,这在单个SPU处理能力足够的情况下较多采用、pipelining,几个SPU串行处理相关数据,但是难以作load balancing,在数据相关性大,以及单个SPU处理能力不足的情况下可以考虑。还有executable或者data超出LS的256K限制范围后,是用手动DMA,还是overlay程序段,或者采用software cache library来透明化LS和MM之间的隔阂。手动控制的DMA较适合data coherency较强的情况,若程序员知道一块大的block数据,那么最好使用这种方法。而software cache适合程序员需要random access大量MM数据的时候,而他对于数据coherency一无所知时,software cache可以提供较好的cache支持,因为SPE是没有硬件cache设计的。而一旦你的code size超出了LS的范围,就必须使用overlay来解决难题了,通过linker script来定义overlay的区域,但无须该动源码,而且不用担心会意外覆盖了程序空间。还有一些其他的model,比如kernel管理的SPU线程,离地球太远了(但好像VxWorks在做),不过自己管理SPU做cooperative multitask还是有实际应用价值的。
其他的还讲了SPU static timing的用法,生成的文件可以清楚的知道静态时序。以及通过模拟器动态运行,获得实际运行数据,除了太慢,都很好用。
最后回公司了,错过了他们一个mpeg2->H.264的实时转码的流媒体系统优化实例,可惜啊。买个PS3爽之。
几天后发现Wenle和潘大是同学……汗一个。
posted @
2007-07-20 17:08 eygneph 阅读(129) |
评论 (0) |
编辑
变形金刚!去看吧,如果你是80前后出生的人,绝对不会让你失望的~
posted @
2007-07-16 10:16 eygneph 阅读(34) |
评论 (0) |
编辑
I assume your PS3 is installed with Fedora Core 6 or YDL, and X Window/KDE/Gnome(optional)
Download http://rpm.livna.org/livna-release-6.rpm and type
$ rpm -Uvh livna-release-6.rpm<Enter>
This will install VLC repository to your yum database.
Goto /etc/yum.repo.d, make sure in fedora-extra.expo, [extra] section, enable = 1. If not, change it to enable = 1.
$ yum install videolan-client<Enter>
Then wait a couple of minutes after answering "Yes". After installation is completed, you can find VLC player in Multimedia menu.
Then open Control Center, navigate to Sound, choose Open Sound System as your sound device. And click apply to enable it.
And that's all! Avi, mpeg, mp3, even mkv files will do!
Tips: if you find sound is weird, close VLC and restart it often fix the problem.
Tips2: if you want to play streaming media from network, a general http server will be sufficient. Of course if you want to use it via a Windows file service(smb), VLC also supports it.
posted @
2007-07-11 22:21 eygneph 阅读(42) |
评论 (0) |
编辑
Download FC6 for PS3(ppc64), burn it into disc, BUT RETAIN THE ISO IMAGE FOR LATER USE!
Download PS3 Linux Additional Disc(kernel), burn it into disc
Download otheros.bld and otheros.self, put it into "/PS3/otheros/"(capital sensitive) directory of the SD/MS card [Note] otheros.bld for Fedora 7, which is recommended by Cell SDK 3.0 is here. Otheros.self is no longer exists from SONY since firmware 1.60.
Plug the network cable on your PS3
Connect a usb keyboard on your PS3
PS3->Format HDD, 10 GB for OtherOS, 50 GB for GameOS
Install OtherOS
DefaultSystem -> OtherOS
Reboot PS3
FOR FC6:
Type "install-fc sda" in kboot prompt
When prompt, insert FC6 disc and hit 'y'
Select "1. Fedora Core 6 minimal install", NEVER select option 2, which may take you more than 4 hours to install, and with NO component option!
Just do the yes/no to proceed with the install
After less than 5 minutes, the FC6 disc automatically eject, insert Additional Disc, and hit 'y'
After less than 2 minutes, type in root password and the Additional Disc automatically eject. Type 'reboot' to reboot your machine
FOR FC7:
Type "linux video=720p" in kboot prompt
If prompted "Unable to find device", scroll down to find ps3_storage and hit ok.
Just do the yes/no to proceed with the install
After rebooting, insert FC6 disc again, and mount it onto /mnt/cdrom
In /mnt/cdrom/Fedora/RPMS/, type 'rpm -Uvh dhclient*', this will install dhclient to help you bring up the ethernet interface
Type 'dhclient' to obtain IP address. This should gives you dynamic IP address(well, of course, prepare your network cable and set your router to DHCP enabled).
Type 'yum install openssh-server'. This will install ssh server(sshd) on your PS3, later on you can remote your PS3 on a PC terminal.
Type 'service sshd start' to bring up ssh server
[Optional]
Open your PC and ssh to login your PS3 using putty or something similar
On your PC, setup an http server to expose all the FC6 iso image contents. Note: using tools to extract iso image files is a bad idea(I got missing files!). I just take Daemon Tools to load the image and redirect my http server to the virtual drive.
On your PS3, edit /etc/yum.repos.d/*, to redirect all baseurl to http://yourpc/fc6 and comment out all mirrorlist.
After that, do the following script:
yum groupinstall "KDE (K Desktop Environment)"
yum install pirut k3b mikmod
yum groupinstall "Server Configuration Tools"
yum groupinstall "Sound and Video"
#yum groupinstall "GNOME Desktop Environment"
yum groupinstall "Legacy Software Support"
yum groupinstall "Development Libraries"
yum groupinstall "Development Tools"
#yum groupinstall "Windows File Server"
yum groupinstall "System Tools"
yum groupinstall "X Window System"
yum install switchdesk lslk logwatch dump lftp bind-utils sendmail nss_ldap device-mapper-multipath ypbind yp-tools
yum install parted.ppc64 rdist.ppc man-pages.noarch talk.ppc pam_ccreds.ppc nc.ppc traceroute.ppc unix2dos.ppc setarch.ppc pam_passwdqc.ppc words.noarch cpuspeed.ppc netdump.ppc crontabs.noarch fbset.ppc acl.ppc dosfstools.ppc usbutils.ppc redhat-lsb.ppc rsync.ppc mgetty.ppc time.ppc man.ppc pam_passwdqc.ppc64 pam_smb.ppc wget.ppc
yum install diskdumputils.ppc ftp.ppc pinfo.ppc ksh.ppc jwhois.ppc psacct.ppc ipsec-tools.ppc dhcpv6_client.ppc lsof.ppc readahead.ppc pcmciautils.ppc sudo.ppc yum-updatesd.noarch pam_smb.ppc64 cyrus-sasl-plain.ppc sysreport.noarch pam_pkcs11.ppc64 rdate.ppc finger.ppc anacron.ppc nano.ppc pam_ccreds.ppc64 parted.ppc attr.ppc tcsh.ppc specspo.noarch stunnel.ppc mlocate.ppc tcpdump.ppc dos2unix.ppc rsh.ppc irda-utils.ppc numactl.ppc tree.ppc
yum install pam_pkcs11.ppc tmpwatch.ppc gnupg.ppc vconfig.ppc iptstate.ppc pax.ppc mtr.ppc nss_db.ppc rp-pppoe.ppc krb5-workstation.ppc pam_krb5.ppc64 mdadm.ppc quota.ppc pam_krb5.ppc symlinks.ppc smartmontools.ppc tcp_wrappers.ppc64 mtools.ppc setuptool.ppc telnet.ppc rng-utils.ppc irqbalance.ppc
#yum groupinstall "Office/Productivity"
yum install netpbm netpbm-devel tk-8.4.*
yum install --enablerepo=extras freeglut freeglut-devel mesa-libGLU-devel mesa-libGL-devel libX11-devel libXmu-devel libXext-devel
yum groupinstall "Chinese Support"
If you get 'No match' error for freeglut or freeglut-extra, just open /etc/yum.repo.d/fedora-extra.repo, and change "enable=0" to "enable=1" in [extra] section. Save and restart yum install.
This will grab rpm packages on your local pc http server, rather than the remote mirror, which can be painful when downloading. When all is finished, we can proceed with the CellSDK.
Reminder: if you want to use X window for normal users other than root, you should do
$ chmod 1777 /tmp
Otherwise you will not be able to bring up X window for normal users.
So, wget CellSDK21.iso from your http server. Mount it onto, for example, /mnt/iso.
$ cd /mnt/iso/software
$ ./cellsdk install
Then the script will automatically download some missing components(about 300M), and you should wait it unitl all installation is done. If you have problem downloading some fils, maybe the network sucks, you can download it via your PC and wget it into /tmp/cellsdk-2.1, and install it.
After cell sdk is installed. We can now build the sample code:
$ cd /opt/ibm/cell-sdk/prototype
$ ./cellsdk build --gcc #or
$ ./cellsdk build --xlc
Reference:
http://www.ps3coderz.com/index.php?option=com_content&task=view&id=73&Itemid=31
http://forums.qj.net/f-ps3-linux-283/t-how-to-install-fedora-core-6-linux-for-ps3-88431.html
http://docs.fedoraproject.org/yum/en/
posted @
2007-07-08 14:14 eygneph 阅读(108) |
评论 (0) |
编辑
https://www-304.ibm.com/jct09002c/isv/spc/events/cbea.html
上海有几天,7月19日,20日;9月6日,7日;11月27日28日
Cell Broadband Engine Architecture workshop
Need multicore performance? Want to learn a new and emerging technology and be an early evaluator? Join us for two days of technical training and explore the details of Cell Broadband Engine (CBE) programming with hands-on exercises. This workshop is for developers with advanced C and C++ skills who would like to experiment with the new CBE technology. It provides a comprehensive technical overview of the cell architecture, programming models, software development environment, cell-based blade server architecture and IBM offerings.
The Cell Broadband Engine Architecture has been designed to support a wide range of applications including digital media, entertainment, communications, medical imaging, security and surveillance, and HPC workloads. The first implementation, the CBE processor, is a single-chip multiprocessor with nine processor elements operating on a shared, coherent memory. Each CBE comprises a power processor element (PPE) and eight synergistic processor elements (SPEs).
The PPE contains a 64-bit Power Architecture core called PPU or PX, and it can run 32-bit and 64-bit operating systems and applications. It also manages system resources and SPE threads. It supports both the PowerPC instruction set and the Vector/SIMD Multimedia Extension instruction set.
The SPEs are independent processor elements which are optimized for running SIMD applications. To an application programmer, the CBE processor looks like a 9-way coherent multicore.
The PPE is used for control-intensive tasks and task switching while the SPEs are more adept at compute-intensive tasks and slower than the PPE at task switching. This specialization and the ability to join strength to work harmoniously yield a significant peak computational performance and chip-area-and-power efficiency that the CBE processor achieves over conventional PC processors.
- Cell multicore architecture
- Cell programming models
- Cell-based blade server
- Cell standards like the application binary interface specifications, language extensions (SPE C, C++) and SPE assembly language specification
- Cell software development environment
- How to develop and build cell programs
- How to apply various programming techniques to exploit cell features
- Cell microprocessor architecture including the PPE, SPE, memory flow controller, element interconnect bus, resource allocation management, I/O and memory interfaces
- Cell programming models and software design methodology including the PPE programming models, SPE programming models, parallel programming models, and multitasking SPEs
- Cell software development environment, development tools and system simulator
- Installing and using the cell software development kit
- Writing, compiling and executing cell programs
- Using the cell full system simulator, systemsim, to examine cell internals and your program execution statistics
- Cell sample workloads and application affinity
- Good technical understanding of computer architecture and programming practices
- Familiarity with Power Architecture is helpful, but not required
- Familiarity with C
posted @
2007-07-07 11:07 eygneph 阅读(51) |
评论 (0) |
编辑
可靠消息来源,虽然我没实际用过:
Halo 2 for Windows Vista was originally scheduled for release on May 8, 2007, but was pushed back to May 29th. This delay was apparently due to the insertion of nudity into the game via a "content error".[65] Microsoft will be offering patches to remove the nude content and is revising the boxes to reflect this. Many retailers were not given the notification in time and have sold copies to consumers since as early as May 20th in a few United States Circuit City stores. The offending nudity was a photograph of a male's bare bottom (presumably of a Microsoft or Bungie employee) which appeared as a ".ass" error when using the map editor in Halo 2 for Windows Vista.[66]
posted @
2007-07-06 14:50 eygneph 阅读(35) |
评论 (0) |
编辑
|
Multiple Device |
Multiple Swap Chain |
Multiple Viewport |
Multiple Surface Blit |
| Resource Consumption |
Very Large |
Large |
Nearly free |
Medium |
| Resource Sharing |
No |
Yes |
Yes |
Yes |
| Multi-adapter |
Yes |
No |
No |
No |
| Multi-head |
No |
Yes |
No |
No |
| Resizing |
Slow |
Slow |
Fast |
Depends |
| Can Be In Different Window |
Yes |
Yes |
No |
No |
最近因为工作关系看了一些这方面的东西,自己整的表,不对请指出。
posted @
2007-07-05 10:43 eygneph 阅读(35) |
评论 (0) |
编辑
想试试刚买的锅,于是把冰箱里的小圆子下锅了,一会儿小圆子浮出水面,我窃喜:不错嘛,这次一个都没破,水平提高了。接着把圆子捞上来,结果发现圆子是没有馅的……
哭。
posted @
2007-07-03 22:57 eygneph 阅读(21) |
评论 (1) |
编辑
很好很强大,3.5 downgrader已放出,速度啊
http://www.noobz.eu/joomla/
posted @
2007-06-27 11:18 eygneph 阅读(17) |
评论 (0) |
编辑
销量增至第一,国内水货JS居奇货,卖出999元天价。。。
posted @
2007-06-26 19:14 eygneph 阅读(24) |
评论 (0) |
编辑
对应全版本PSP的exploit发现了!
http://www.noobz.eu/joomla/Lumines!的savedata再次给了fanjita机会,可以在任意fw版本上(up to 3.50)运行homebrew,期待放出HEN和降级程序。
fanjita也给了Lumines!从小众作品跃升至大作的机会~~目前在amazon销售排名从796跃升至6~~
posted @
2007-06-25 15:43 eygneph 阅读(27) |
评论 (0) |
编辑
posted @
2007-06-25 10:10 eygneph 阅读(20) |
评论 (0) |
编辑
这是我一直想写的东西,来这里没多久就发现同事们看问题的高度和以前接触的人不一样。而今天第一次在部门里讲talk,被深刻的教育了。
确实做东西做talk,理论需要自圆其说,说出来要有道理,最好有数学的表达,有理论的支持,推出来的东西才是最令人信服的,而不是“看上去差不多”就可以了。为什么15就够了,为什么30不够,别人会challenge你,如果这个时候有理论支持的话,显然对方无话可说。而没有的话呢——技术上扯皮的事情见太多了。。。这也许就是researcher和engineer的区别吧。在搞fancy的东西时只想到漂亮是不行di。。。
回头就去复习信号处理。
posted @
2007-06-15 14:46 eygneph 阅读(50) |
评论 (0) |
编辑
DX10 Tutorial中几句话还真是精辟啊……怎么看怎么像Edit Mesh Modifier啊
The benefit of the geometry shader that it allows manipulation of meshes on a per-primitive basis. Instead of running a computation on each vertex individually, there is the option to operate on a per-primitive basis. That is, vertices can be passed in as a single vertex, a line segment (two vertices), or as a triangle (three vertices).
In addition to allowing access to whole primitives, the geometry shader can create new primitives on the fly.
The geometry shader in Direct3D 10 can read in a single primitive (with optional edge-adjacent primitives) and emit zero, one, or multiple primitives based on that.
For instance, it is possible to read in individual vertices, and generate multiple triangles based on those. This allows a wide range of new ideas to be executed on the graphics pipeline without CPU intervention.
The geometry shader exists between the vertex and the pixel shaders in the graphics pipeline.
posted @
2007-06-08 15:14 eygneph 阅读(35) |
评论 (0) |
编辑
有关cross-platform gaming,有这么一段话:
A game that’s an RTS on the PC could be an FPS on the 360, where “I’m the RTS commander, and I’m moving units around and you’re the foot soldier going out and fighting the battles. And how you do effects how I do, and vice versa.”
“Certainly we’ve open up that possibility in that world.” Does this mean Microsoft is working on such a title? Wickham laughs, saying he won’t confirm it. Adding seriously, “I do know that there are developers thinking about the interesting concepts cross-platform play opens.”
这一刻,泪流满面。
posted @
2007-06-08 10:21 eygneph 阅读(14) |
评论 (0) |
编辑
posted @
2007-06-07 17:03 eygneph 阅读(28) |
评论 (0) |
编辑
posted @
2007-06-05 18:03 eygneph 阅读(27) |
评论 (0) |
编辑
明天就是六一儿童节了,在这喜庆祥和的气氛中,我代表XXOO向祖国的花朵们致以节日的问候!
posted @
2007-05-31 18:52 eygneph 阅读(13) |
评论 (0) |
编辑
花时间浏览了一下最新成果和新闻,总结如下:
1、很多人开始访问framebuffer了,至少一个横向卷轴的东西可以很快出现。
2、Phil Harrison仍然坚持rsx需要被保护
http://interviews.slashdot.org/article.pl?sid=07/04/20/06412093、Hypervisor API正被人从linux kernel中一步步解出来
http://wiki.ps2dev.org/ps3:hypervisor4、有人干脆写了boot loader并可以调用hypervisor API
http://forums.ps2dev.org/viewtopic.php?t=83335、通过编译kernel并加入新的MDT module,可以访问并使用252M的显存
http://forums.ps2dev.org/viewtopic.php?t=82676、TerraSoft(发布YDL的公司)可能正在着手制作基于SPU的mesa实现,看来离和谐不远了
http://forum.beyond3d.com/showthread.php?t=396067、unsolo已经有一个基于SPU的YUV2RGB色彩空间转换的实现,这为最优化的MediaPlayer提供了最基础的支持
http://forums.ps2dev.org/viewtopic.php?t=8194 8、ralferoo实现了一个Python-bind的,类似LuaPlayer的一个游戏库,可以方便的使用脚本操纵核心部件,写逻辑
http://python-ps3.sourceforge.net/
posted @
2007-05-31 18:45 eygneph 阅读(62) |
评论 (0) |
编辑
一个多月前看过的视频,3台PS3通过路由连接起来,已经可以实现实时(或交互)的ray tracing了。虽然对Cell之前有过了解,但是那么快就有成果还是比较震惊的。
看了一下paper,有所启发。一般有两种做法,SPE作为ray tracing的每个stage,拥有不同的kernel,以及SPE上运行相同的ray tracing kernel,处理屏幕上不同的像素。第一种方法问题在于难以平衡每个stage中的load balance,避免stall,设计方面将会无比复杂;第二种方法头疼的地方在于每个SPE都要任意存取整个场景的几何数据,这显然不是256KB LS能放的下的,所以需要设计一个software cache做法来掩盖讨厌的DMA操作,所幸相近的像素之间对于场景数据的coherent是相对较大的,所以software cache的命中率也会较高,再加上software hyperthreading的做法——把cache miss后的SPE转去处理其他已有现成场景数据的像素,等它所需要的数据异步DMA到达之后,再处理之。
至于多台CellBE的话,可以把场景数据通过网络同步到多台CellBE的主存中,然后通过协议分割屏幕像素以便处理。说实话,这种做法的工作也不小……
由此看来,加上
Folding@home在PS3上的巨大成功,我们有理由相信类似CellBE架构的CPU将会成为未来高性能计算的主流之一——只是目前我们尚缺乏时间和工具。
题外话:似乎国内这方面动手的还是比较少,希望有经验的朋友多交流。
posted @
2007-05-24 10:38 eygneph 阅读(41) |
评论 (0) |
编辑
九十九夜,失落的奥德赛,似乎都用到这些技术。以前一直认为instancing很容易地就带上了hardware skining的,认真看了以后发觉不是这么回事。
不过,在sm 3.0上如果vertex texture fetch代价还是很大的情况下,很难将bone matrix编码在fp texture中,更何况每帧更新texture还很成问题。
所以想想在vs_2_0 的256 constant register配置下,bone matrix压缩为2个float4——translation和rotation,matrix到shader中再展开,这样20根骨骼的一个instance data只需要2×20=40个constant register,这样256个register中可以容纳6个instance data。如果同屏2000个人的话,勉强333次draw call可以对付对付……
posted @
2007-05-08 15:51 eygneph 阅读(88) |
评论 (2) |
编辑
昨天看美术用Maya的时候,发现Maya的实时渲染部分已经实现了stylized silhouette以及frame coherent,可是效率还是跟不上,在美术的机器上都卡的厉害,既然Maya都只能如此,我就暂时把它搁置一下下吧,等什么时候硬件对这种buffer readback不再感冒的时候,或者CPU/GPU大统一的时候再搞……
posted @
2006-11-18 22:20 eygneph 阅读(66) |
评论 (0) |
编辑
致此PS3发售之际,摘抄一段SCE的计划声明。
http://www.playstation.com/ps3-openplatform/index.htmlPLAYSTATION®3 allows any desired third-party system software to be installed on it besides its system software provided by Sony Computer Entertainment Inc. Details will be posted on this site soon.
鬼子们,咱们等着……
posted @
2006-11-12 22:33 eygneph 阅读(42) |
评论 (0) |
编辑
呃,很久以前拷下来的代码……
//let P = v1 - v0
