全英文微软公司项目介绍汇报总结商务型ppt模板

上传人:小**** 文档编号:185154789 上传时间:2021-07-03 格式:PPTX 页数:32 大小:3.25MB
返回 下载 相关 举报
全英文微软公司项目介绍汇报总结商务型ppt模板_第1页
第1页 / 共32页
全英文微软公司项目介绍汇报总结商务型ppt模板_第2页
第2页 / 共32页
全英文微软公司项目介绍汇报总结商务型ppt模板_第3页
第3页 / 共32页
全英文微软公司项目介绍汇报总结商务型ppt模板_第4页
第4页 / 共32页
全英文微软公司项目介绍汇报总结商务型ppt模板_第5页
第5页 / 共32页
点击查看更多>>
资源描述

《全英文微软公司项目介绍汇报总结商务型ppt模板》由会员分享,可在线阅读,更多相关《全英文微软公司项目介绍汇报总结商务型ppt模板(32页珍藏版)》请在金锄头文库上搜索。

1、Building a High Performance 3D Games for Windows Phone,Adam Schaeffer Microsoft Corporation,SESSION CODE: WPH308,Consistent sets of hardware capabilities defined by Microsoft,Windows Phone 7 Hardware,Resolution Touch Input CPU / GPU RAM Hardware keyboard is optional,The CPU,The Evolution Of Programm

2、ing,Low level control,Straight to the metal,Raw performance tuning,High level abstraction,Rely on compiler and runtime,Developer productivity,Why C# r0 x0rz,Powerful and expressive,Type safety reduces hard-to-track-down bugs,Reflection,Initializer syntax,Great tooling (IntelliSense),Similar enough t

3、o C that learning and porting are easy,Blazingly fast compiles,C#,.NET on Windows,Usually within a few percent of native performance,Awesome generational garbage collection,Performance shootout: Raymond Chen vs. Rico Mariani http:/,.NET on Xbox 360,360,Significant delta between managed and native,.N

4、ET Compact Framework Simplistic mark-and-sweep garbage collection,Xbox is not a general purpose computer Unforgiving in-order CPU architecture Requires custom VMX instructions for optimal math perf Security architecture poses challenges for jitted code,.NET on Windows Phone 7,In between Windows and

5、Xbox 360,.NET Compact Framework Keep an eye on garbage collection!,ARMv7 CPU More forgiving toward jitted code ARM jitter is more mature than PPC,Ways To Call Code,Instance method,Interface,Delegate / event,Reflection,Virtual method,Choose Your Own Address,C+ allows independent choice of,.NET types

6、dictate their allocation and usage semantics,Data type The memory in which a type lives (placement new) How a type instance is referenced (T, T*, T c = Matrix.Multiply(a, b); / copies 192 bytes! Matrix.Multiply(ref a, ref b, out c);,Memory Management,Garbage collection is not optional Cant have type

7、 safety without automatic memory management,Mark and Sweep,Triggered per megabyte of allocation,1,Starts with root references (stack variables, statics),2,Recursively follows all references to see what other objects can be reached,3,Anything we didnt reach must be garbage,4,Compacts the heap, slidin

8、g live objects down to fill holes,5,Frameworks designed for performance,Frameworks designed for performance,Two Ways To Keep GC Happy,Make it run Less Often,If you never allocate, GC will never run,Make it Finish Quickly,Collection time is proportional to how many object references must be traversed

9、,Use object pools,Simple heap = fast collection,Use value types and integer handles,GC.Collect,Explicitly forces a garbage collection,Use wisely to give yourself more headroom After loading During pauses in gameplay,Dont call every frame!,Avoiding Allocation,Beware of boxing,string vs. StringBuilder

10、,Use WeakReference to track GC frequency http:/,Use CLR Profiler on Windows See MIX10 talk: “Development and Debugging Tools for Windows Phone 7 Series”,Use .NET Reflector to peek behind the curtain http:/www.red-,The GPU,Plus hardware accelerated 2D sprite drawing,Five Configurable Effects,BasicEff

11、ect,SkinnedEffect,EnvironmentMapEffect,AlphaTestEffect,DualTextureEffect,BasicEffect,0-3 directional lights Blinn-Phong shading Optional texture Optional fog Optional vertex color,BasicEffect,DualTextureEffect,DualTextureEffect,For lightmaps, detail textures, decals Blends two textures Separate text

12、ure coordinates Modulate 2X combine mode (A*B*2) Good visuals at low pixel cost,AlphaTestEffect,For billboards and imposters Adds alpha test operations (pixel kill) Standard blending is free with all effects Only need alpha test if you want to disable depth/stencil writes,AlphaTestEffect,SkinnedEffe

13、ct,SkinnedEffect,For animated models and instancing Game code animates bones on CPU Vertex skinning performed by GPU Up to 72 bones One, two, or four weights per vertex,EnvironmentMapEffect,EnvironmentMapEffect,Oooh, shiny! Diffuse texture + cube environment map Cheap way to fake many complex lights

14、 Fresnel term simulates behavior when light reaches a surface and some reflects, some penetrates,A Balancing Act,Framerate,Number of Pixels,Pixel Cost,Balancing Framerate,Framerate,30 hz refresh rate No point updating faster than the display! Game.TargetElapsedTime = TimeSpan.FromSeconds(1f / 30);,A

15、 Balancing Act,Pixel Cost,Prefer cheaper effects Minimize overdraw Many known algorithms: Distance, frustum, BSP, sort front to back Implement “overdraw x-ray mode” Draw untextured with additive blending Brighter areas indicate overdraw,A Balancing Act,Number of Pixels,800 x480 is 25% more pixels th

16、an Xbox 1 Great for text Too many pixels for intensive games 800 x480 = 384,000 pixels 600 x360 = 216,000 pixels (56%) Dedicated hardware scaler Does not consume any GPU Higher quality than bilinear upsampling,Scaler Demo,XNA Framework API Cheat Sheet,Summary,Great performance comes from great knowledge,Understand,Actions,Value types vs. reference types Garbage collection C# compiler magic (foreach, iterator methods, closures) Cost of the different graphical effect options,Use CLR Profiler and .

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 办公文档 > PPT模板库 > 互联网/IT

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号