maximizing the user experience

43

Upload: inoke

Post on 01-Feb-2016

43 views

Category:

Documents


0 download

DESCRIPTION

Maximizing the User Experience A comprehensive suite of level-of-detail (LOD) techniques for modern high-end F2P games 最优化用户体验 整套细节级别( LOD )技术全面运用于现代高端 F2P 游戏中. Speaker Introduction. Christopher Pfeiffer Balanced Worlds, CEO 14 years in the games industry - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Maximizing the User Experience
Page 2: Maximizing the User Experience

Maximizing the User ExperienceA comprehensive suite of level-of-detail (LOD) techniques for

modern high-end F2P games

最优化用户体验整套细节级别( LOD)技术全面运用于现代高端 F2P游戏中

Page 3: Maximizing the User Experience

Speaker IntroductionSpeaker Introduction

Christopher PfeifferChristopher PfeifferBalanced Worlds, CEOBalanced Worlds, CEO14 years in the games industry14 years in the games industryUniversity of Michigan, BSE in Computer EngineeringUniversity of Michigan, BSE in Computer Engineering

主讲人介绍主讲人介绍费浩然费浩然

和谐世界(北京)软件科技有限公司,首席执行官和谐世界(北京)软件科技有限公司,首席执行官十四年游戏行业从业经验十四年游戏行业从业经验密歇根大学,计算机工程学位密歇根大学,计算机工程学位

Page 4: Maximizing the User Experience

Games CreatedGames Created研发项目研发项目

Page 5: Maximizing the User Experience

Balanced WorldsBalanced Worlds和谐世界地理位置和谐世界地理位置

Page 6: Maximizing the User Experience

LOD BasicsLOD Basics

LODLOD 基本原理基本原理

Page 7: Maximizing the User Experience

What is LOD?What is LOD?Level of DetailLevel of Detail

The goal is to make highly interactive experiences while The goal is to make highly interactive experiences while using less resourcesusing less resources

The reduction in complexity comes from graphical The reduction in complexity comes from graphical reductions, algorithmic simplifications, and heuristic reductions, algorithmic simplifications, and heuristic process cullingprocess culling

何为何为 LODLOD ??细节级别细节级别

旨在用更少的资源获得更佳的互动体验效果旨在用更少的资源获得更佳的互动体验效果复杂程度的降低源自图形的减少,算法的简化,以及探索复杂程度的降低源自图形的减少,算法的简化,以及探索法流程的筛选法流程的筛选

Page 8: Maximizing the User Experience

Why is LOD important?Why is LOD important?One reason: QualityOne reason: Quality

The same game will provide completely different player The same game will provide completely different player experiences depending on whether its running at 15, 30, or experiences depending on whether its running at 15, 30, or 60 FPS60 FPS

Greater complexity results in more immersionGreater complexity results in more immersion

As a game developer, you will never be able to do everything As a game developer, you will never be able to do everything that you want to dothat you want to do

LODLOD 为何重要?为何重要?一个原因:为了品质一个原因:为了品质

同一款游戏,当采用同一款游戏,当采用 1515 ,, 3030 或或 6060 的不同帧速时,所带的不同帧速时,所带来用户体验效果会完全不同来用户体验效果会完全不同更高的复杂性会更加的引人入胜更高的复杂性会更加的引人入胜作为游戏开发人员,要实现所有想法几乎是不可能的作为游戏开发人员,要实现所有想法几乎是不可能的

Page 9: Maximizing the User Experience

PerformancePerformance

All team members must care about the frame rateAll team members must care about the frame rate

Games are entertainment; its ok to deceive the playerGames are entertainment; its ok to deceive the player

性能表现性能表现

所有项目成员都必须关注帧频所有项目成员都必须关注帧频游戏是为了娱乐,“欺瞒”玩家也是可以的游戏是为了娱乐,“欺瞒”玩家也是可以的

Page 10: Maximizing the User Experience

AccountabilityAccountability

Accountability is criticalAccountability is critical

Good performance does not happen naturallyGood performance does not happen naturally

Everyone must know who is reasonable for making sure Everyone must know who is reasonable for making sure that the frame rate is goodthat the frame rate is good

责任承担责任承担责任承担至关重要责任承担至关重要良好的性能表现不会自然成就良好的性能表现不会自然成就每个人都应该清楚该怎样合理地确保帧频良好每个人都应该清楚该怎样合理地确保帧频良好

Page 11: Maximizing the User Experience

BudgetsBudgetsPerformance Budgets MUST be maintainedPerformance Budgets MUST be maintained

If you don’t know how much time a system is taking If you don’t know how much time a system is taking during a frame, you don’t know if it is completeduring a frame, you don’t know if it is complete

Need in-game profiling toolsNeed in-game profiling tools

Provide testers with toolsProvide testers with tools

Target your game’s trouble spotsTarget your game’s trouble spots

预算预算必须满足性能预算要求必须满足性能预算要求

如果你不清楚系统在每一帧要花费的时间,你就无法知道如果你不清楚系统在每一帧要花费的时间,你就无法知道它的完成状态它的完成状态需要游戏中的剖析工具需要游戏中的剖析工具为测试者提供工具为测试者提供工具瞄准游戏的问题点瞄准游戏的问题点

Page 12: Maximizing the User Experience

2 Common Issues2 Common Issues

“ “ 突现”突现”

“ “ 正反复振正反复振””

两个常见问题两个常见问题

Pops!Pops!

Flip- FlopFlip- Flop

Page 13: Maximizing the User Experience

Pops!Pops!Why avoid pops?Why avoid pops?

They distract players from the game experience They distract players from the game experience

Types of popsTypes of pops

GraphicalGraphical

SimulationSimulation

““ 突现”突现”为何要避免“突现” ?为何要避免“突现” ?

它们会分散玩家精力,降低游戏体验效果它们会分散玩家精力,降低游戏体验效果““ 突现”分类突现”分类

图像图像模拟仿真模拟仿真

Page 14: Maximizing the User Experience

Flip-FlopFlip-Flop

Rapid switching between states causes many problemsRapid switching between states causes many problems

2 Methods to resolve it2 Methods to resolve it

Use separate test criteria for entering and exiting a stateUse separate test criteria for entering and exiting a state

Smooth out the metric across framesSmooth out the metric across frames

““正反复振正反复振””不同状态间的快速切换会带来很多问题不同状态间的快速切换会带来很多问题两个解决办法两个解决办法

针对某种状态的“进入”和“退出”采用不同的测试标准针对某种状态的“进入”和“退出”采用不同的测试标准平滑各帧间的进制平滑各帧间的进制

Page 15: Maximizing the User Experience

LOD Control MechanismsLOD Control Mechanisms

LODLOD 控制机制控制机制

Page 16: Maximizing the User Experience

LOD SelectionLOD SelectionHow does the game decide which LOD to use?How does the game decide which LOD to use?

Static methodsStatic methods

Algorithm selection and fixed parameter valuesAlgorithm selection and fixed parameter values

Adaptive methodsAdaptive methods

Reactive and predictiveReactive and predictive

LODLOD 选择选择游戏是如何确定该用哪个游戏是如何确定该用哪个 LODLOD 的呢?的呢?静态方法静态方法

算法选择及参数值处理算法选择及参数值处理

适配办法适配办法应对及预测应对及预测

Page 17: Maximizing the User Experience

Perception Based LODPerception Based LODTrigger LOD changes based on the objects state on screenTrigger LOD changes based on the objects state on screen

Distance squaredDistance squared

2d relative speed on screen2d relative speed on screen

2d distance from players’ focal point (the reticule)2d distance from players’ focal point (the reticule)

3d depth order3d depth order

Drawn or not drawnDrawn or not drawn

基于认知的基于认知的 LODLOD根据屏幕出现物体来触发根据屏幕出现物体来触发 LODLOD变化变化距离的平方距离的平方屏幕上二维相对速度屏幕上二维相对速度玩家焦点(分度线)的二维距离玩家焦点(分度线)的二维距离三维纵深顺序三维纵深顺序绘入还是不绘绘入还是不绘

Page 18: Maximizing the User Experience

Performance Based LODPerformance Based LOD

MetricsMetrics

Simple metricsSimple metrics

More complexMore complex

The point is that there lot of options availableThe point is that there lot of options available

基于性能的基于性能的 LODLOD度量体系度量体系

简单度量简单度量稍复杂稍复杂观点就是有很多可选方案观点就是有很多可选方案

Page 19: Maximizing the User Experience

User Selected LODUser Selected LOD

Game players want controlGame players want control

Users often have divergent desiresUsers often have divergent desires

Still need to group options to make them intuitiveStill need to group options to make them intuitive

基于用户选择的基于用户选择的 LODLOD

游戏玩家希望能够控制游戏玩家希望能够控制玩家通常会有很多不同的欲望玩家通常会有很多不同的欲望仍然需要分组选项来实现直观性仍然需要分组选项来实现直观性

Page 20: Maximizing the User Experience

Specific LOD TypesSpecific LOD TypesGraphical LODGraphical LOD

Skeletal LODSkeletal LOD

Simulation LODSimulation LOD

AI LODAI LOD

特定的特定的 LODLOD 类型类型图形图形 LODLOD

骨骼骨骼 LODLOD

模拟仿真模拟仿真 LODLOD

人工智能人工智能 LODLOD

Page 21: Maximizing the User Experience

Graphical LODGraphical LOD

图形图形 LODLOD

Page 22: Maximizing the User Experience

ResolutionResolutionResolution can be thought of a static LODResolution can be thought of a static LOD

Pixel fill ratePixel fill rate

LOD’ing one feature sometimes affects other features’ LOD’ing one feature sometimes affects other features’ LOD requirementsLOD requirements

分辨率分辨率分辨率可以想象为一种静态的分辨率可以想象为一种静态的 LODLOD

像素填充频率像素填充频率对某一特性运用对某一特性运用 LODLOD 有时会影响其他特性的有时会影响其他特性的 LODLOD 需求需求

Page 23: Maximizing the User Experience

ShadersShaders

ShadersShaders

Pixel popPixel pop

Shader swap often done at model swap timeShader swap often done at model swap time

Depending on your requirements, there are a myriad of Depending on your requirements, there are a myriad of possible LOD optionspossible LOD options

材质球材质球材质球材质球

像素突现像素突现材质球的替换经常发生在模型替换时材质球的替换经常发生在模型替换时根据需求不同,有许多根据需求不同,有许多 LODLOD 的可能选择的可能选择

Page 24: Maximizing the User Experience

Model SwappingModel SwappingMethodMethod

Assign each LOD of a model a distance rangeAssign each LOD of a model a distance range

Calculate distance from the camera and select the LODCalculate distance from the camera and select the LOD

ImprovementsImprovements

LOD distances per meshLOD distances per mesh

Cross-fade techniqueCross-fade technique

模型替换模型替换方法方法

对每一模型的对每一模型的 LODLOD 确定其对应的距离范围确定其对应的距离范围从镜头处计算距离并选择适当的从镜头处计算距离并选择适当的 LODLOD

改进方案改进方案根据每一网格确定根据每一网格确定 LODLOD距离距离同时淡出淡入的软切换技术同时淡出淡入的软切换技术

Page 25: Maximizing the User Experience

Model SwappingModel Swapping

ProductionProduction

Artists need to make all of the LOD models for each Artists need to make all of the LOD models for each assetasset

Artists must adjust both shader and model LODs Artists must adjust both shader and model LODs together in-gametogether in-game

模型替换模型替换生产过程生产过程美工需要对每一资产进行全套美工需要对每一资产进行全套 LODLOD 模型的制作模型的制作美工必须在游戏中同时调整材质球和模型的美工必须在游戏中同时调整材质球和模型的 LODLOD

Page 26: Maximizing the User Experience

Precomputed LightingPrecomputed Lighting

3 Stage Example3 Stage Example

Highest detail-level stores global illumination informationHighest detail-level stores global illumination information

Medium detail-level just stores a color per texelMedium detail-level just stores a color per texel

Low detail-level is vertex lit faces without a textureLow detail-level is vertex lit faces without a texture

预计算光照预计算光照

三个级别举例三个级别举例最高细节级别包含有全局照明信息最高细节级别包含有全局照明信息中等细节级别只保存每个材素点的颜色信息中等细节级别只保存每个材素点的颜色信息低细节级别是不包括材质的顶点照亮面低细节级别是不包括材质的顶点照亮面

Page 27: Maximizing the User Experience

Precomputed LightingPrecomputed Lighting

To enable blending actually requires 5 shaders!To enable blending actually requires 5 shaders!

Blend between high and mediumBlend between high and medium

Blend between medium and lowBlend between medium and low

预计算光照预计算光照

实际需要五个材质球才能完成混和!实际需要五个材质球才能完成混和!高级和中级之间的混和高级和中级之间的混和中级和低级之间的混和中级和低级之间的混和

Page 28: Maximizing the User Experience

View-dependant Dynamic Mesh LODView-dependant Dynamic Mesh LOD

Can be used for continuous terrains and other modelsCan be used for continuous terrains and other models

Implementing this type of technology represents a Implementing this type of technology represents a serious development risk and commitmentserious development risk and commitment

Morphing looks better than switching LOD levels Morphing looks better than switching LOD levels instantlyinstantly

Obscure itObscure it

视角决定动态网格的视角决定动态网格的 LODLOD

能被运用于连续地域和其他模型中能被运用于连续地域和其他模型中运用此类技术意味着严重的开发风险和投入运用此类技术意味着严重的开发风险和投入变形比突然切换变形比突然切换 LODLOD 级别看起来好很多级别看起来好很多要掩盖它要掩盖它

Page 29: Maximizing the User Experience

Visual Effects LODVisual Effects LOD

Visual effects rely on particles and alpha blendingVisual effects rely on particles and alpha blending

Effects have an interesting cost functionEffects have an interesting cost function

Which LOD method is best to use depends heavily on the Which LOD method is best to use depends heavily on the type of special effecttype of special effect

Very time consuming to get it rightVery time consuming to get it right

视觉特效视觉特效 LODLOD

视觉效果依靠的是粒子和视觉效果依靠的是粒子和 alphaalpha 的混和的混和效果有着有趣的价值函数效果有着有趣的价值函数何种何种 LODLOD方法才是最佳方案很大程度上取决于特效的类型方法才是最佳方案很大程度上取决于特效的类型要想做出正确选择是非常耗费时间的要想做出正确选择是非常耗费时间的

Page 30: Maximizing the User Experience

Skeletal LODSkeletal LOD

骨骼骨骼 LODLOD

Page 31: Maximizing the User Experience

Skeletal LODSkeletal LOD

3 types of bones3 types of bones

Bones that are manipulated or queried in the AIBones that are manipulated or queried in the AI

Bones that animate a collision modelBones that animate a collision model

Bones that skin the rendered geometryBones that skin the rendered geometry

骨骼骨骼 LODLOD

三种类型的骨骼三种类型的骨骼被控或在人工智能里问讯到的骨骼被控或在人工智能里问讯到的骨骼用于碰撞模型动画的骨骼用于碰撞模型动画的骨骼几何渲染时的蒙皮骨骼几何渲染时的蒙皮骨骼

Page 32: Maximizing the User Experience

Skeletal LODSkeletal LODSample Update LoopSample Update Loop

Determine the desired movement for all objectsDetermine the desired movement for all objects

Compute the actual movements based on collisionCompute the actual movements based on collision

Animate based on actual movement resultsAnimate based on actual movement results

Update physics objects within the sceneUpdate physics objects within the scene

Do post-physics update on each objectDo post-physics update on each object

骨骼骨骼 LODLOD样本升级循环样本升级循环

确定所有物体所期望实现的运动确定所有物体所期望实现的运动根据碰撞计算实际的运动根据碰撞计算实际的运动根据实际运动结果作出动画根据实际运动结果作出动画在场面中更新物理物体在场面中更新物理物体对每一物体进行后物理更新对每一物体进行后物理更新

Page 33: Maximizing the User Experience

Skeletal LODSkeletal LOD

ProductionProduction

Effects model constructionEffects model construction

Limits model fidelityLimits model fidelity

Requires testing to verify utilizationRequires testing to verify utilization

骨骼骨骼 LODLOD

生产过程生产过程效果模型的建造效果模型的建造极限模型的逼真极限模型的逼真需要测试来验证效用需要测试来验证效用

Page 34: Maximizing the User Experience

Simulation LODSimulation LOD

模拟仿真模拟仿真 LODLOD

Page 35: Maximizing the User Experience

PhysicsPhysicsOften physics isn’t necessaryOften physics isn’t necessary

Most physics in games is used for graphical flourishMost physics in games is used for graphical flourish

Simulation fidelity needs to vary by distance, view, and Simulation fidelity needs to vary by distance, view, and the complexity of the scenethe complexity of the scene

Carefully determine what actually mattersCarefully determine what actually matters

物理物理通常物理不是必须的通常物理不是必须的

多数游戏中的物理都是用于营造图形的夸张效果多数游戏中的物理都是用于营造图形的夸张效果模拟仿真的逼真度需要根据距离,视角和场面的复杂程度模拟仿真的逼真度需要根据距离,视角和场面的复杂程度来变化来变化仔细确定出真正重要的部分仔细确定出真正重要的部分

Page 36: Maximizing the User Experience

Artificial Intelligence LODArtificial Intelligence LOD

人工智能人工智能 LODLOD

Page 37: Maximizing the User Experience

AI LODAI LOD

AI has many features which can individually LODAI has many features which can individually LOD

Decision makingDecision making

Movement & SimulationMovement & Simulation

人工智能人工智能 LODLOD

人工智能有很多特性能个别地做人工智能有很多特性能个别地做 LODLOD

作出决策作出决策运动和模拟仿真运动和模拟仿真

Page 38: Maximizing the User Experience

Reasonable PracticesReasonable Practices

可能的实践可能的实践

Page 39: Maximizing the User Experience

LOD What Actually Matters LOD What Actually Matters

Worst case scenariosWorst case scenarios

LOD techniques can’t account for all situationsLOD techniques can’t account for all situations

Focus on your worst case scenarios and make them Focus on your worst case scenarios and make them perform wellperform well

LODLOD 确实重要确实重要最糟情况最糟情况

LODLOD 技术不能说明所有情况技术不能说明所有情况关注你遇到的最糟情况并改善其性能表现关注你遇到的最糟情况并改善其性能表现

Page 40: Maximizing the User Experience

Real-time VisualizationReal-time Visualization

In-game real-time visualization is a mustIn-game real-time visualization is a must

Rapid iteration is needed to achieve the best resultsRapid iteration is needed to achieve the best results

Tweaking is time consumingTweaking is time consuming

Artists must be empowered to independently improve the frame rateArtists must be empowered to independently improve the frame rate

实时影像实时影像游戏中实时影像的呈现已成必然游戏中实时影像的呈现已成必然

要达到最好效果需要做好快速迭代要达到最好效果需要做好快速迭代调整是耗费时间的调整是耗费时间的所有美工必须要有独立改善帧频的能力所有美工必须要有独立改善帧频的能力

Page 41: Maximizing the User Experience

Double Check AssumptionsDouble Check Assumptions

Problems are not always what they seemProblems are not always what they seem

Double-check architectural decisionsDouble-check architectural decisions

Make sure to properly identify the performance issueMake sure to properly identify the performance issue

复查假设复查假设问题不总是它们看起来的样子问题不总是它们看起来的样子

重复检查所做有关建筑的决定重复检查所做有关建筑的决定确保正确辨识出性能问题确保正确辨识出性能问题

Page 42: Maximizing the User Experience

References & Useful LinksReferences & Useful Links

参考文献及链接参考文献及链接

Page 43: Maximizing the User Experience

References & Useful LinksReferences & Useful Links参考文献及链接参考文献及链接

LOD Book:LOD Book:

http://lodbook.com/http://lodbook.com/

Great collection of papers:Great collection of papers:

http://debian.fmi.uni-sofia.bg/~sergei/cgsr/all.htmhttp://debian.fmi.uni-sofia.bg/~sergei/cgsr/all.htm

Insomniac Games:Insomniac Games:

http://www.insomniacgames.com/tech/techpage.phphttp://www.insomniacgames.com/tech/techpage.php

Gamasutra:Gamasutra:

http://www.gamasutra.comhttp://www.gamasutra.com

Wikipedia:Wikipedia:

http://en.wikipedia.org/wiki/Level_of_detailhttp://en.wikipedia.org/wiki/Level_of_detail