성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

37
성성성성성성 성성성성성성 성성성성성성성 성성성성성성성 성성성 성성성 2003 / 11 / 15 2003 / 11 / 15 3 3 성성 성성 성성 성성 Part 1. 3D Game and 3D Graphics Part 1. 3D Game and 3D Graphics Part 2. 3D Game Platforms Part 2. 3D Game Platforms Part 3. 3D Game Engine and Realtime Rendering Part 3. 3D Game Engine and Realtime Rendering

description

3 차원 게임. Part 1. 3D Game and 3D Graphics Part 2. 3D Game Platforms Part 3. 3D Game Engine and Realtime Rendering. 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15. Part 1. 3D Game and 3D Graphics. 3D Game. The first 3D game: Wolfenstein 3D By id Software in 1992 First-person shooter - PowerPoint PPT Presentation

Transcript of 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

Page 1: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

성균관대학교성균관대학교정보통신공학부정보통신공학부한정현한정현

2003 / 11 / 152003 / 11 / 15

33 차원 게임차원 게임Part 1. 3D Game and 3D GraphicsPart 1. 3D Game and 3D GraphicsPart 2. 3D Game PlatformsPart 2. 3D Game PlatformsPart 3. 3D Game Engine and Realtime RenderingPart 3. 3D Game Engine and Realtime Rendering

Page 2: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

2

3 차원 게임 한정현

Part 1. 3D Game and 3D GraphicsPart 1. 3D Game and 3D Graphics

Page 3: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

3

3 차원 게임 한정현

3D Game 3D Game 3D Game 3D Game

The first 3D game: The first 3D game: Wolfenstein 3D Wolfenstein 3D By id Software in 1992By id Software in 1992 First-person shooterFirst-person shooter The items and enemies are sprites (a collection of static images) that The items and enemies are sprites (a collection of static images) that

are moved around, resized, and even animated. are moved around, resized, and even animated. No jump or stair climbing allowed No jump or stair climbing allowed

Since Wolfenstein 3D, id Software has produced Since Wolfenstein 3D, id Software has produced Doom, which added the ability to walk up stairs. Doom, which added the ability to walk up stairs.

Doom 1993; Doom 2 1994Doom 1993; Doom 2 1994 Quake, which added real 3D items and enemies by using polygon moQuake, which added real 3D items and enemies by using polygon mo

dels rather than sprites.dels rather than sprites. Quake 1996; Quake 2 1997; Quake 3 Arena 1999Quake 1996; Quake 2 1997; Quake 3 Arena 1999

Wolfenstein 3D Doom Quake 3[idS]

Page 4: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

4

3 차원 게임 한정현

3D Game 3D Game (cont’d)(cont’d)3D Game 3D Game (cont’d)(cont’d)

Now, 3D games are everywhere.Now, 3D games are everywhere.

A 2001 survey showed that 80% of the games published all over the wA 2001 survey showed that 80% of the games published all over the world were 3D. orld were 3D. [Gamemeca][Gamemeca]

Page 5: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

5

3 차원 게임 한정현

3D Graphics3D Graphics3D Graphics3D Graphics

The core of 3D game is 3D graphics.The core of 3D game is 3D graphics. 3D graphics = modeling + rendering + animation 3D graphics = modeling + rendering + animation

A model is a computer representation of an object. A model is a computer representation of an object. Rendering is the process of creating an image from a model.Rendering is the process of creating an image from a model. Animation is the process of generating repeated renderings of a scene.Animation is the process of generating repeated renderings of a scene.

The most popular 3D modeling technique is polygon or triangular The most popular 3D modeling technique is polygon or triangular mesh.mesh.

The set of vertices/polygons enters the The set of vertices/polygons enters the rendering pipelinerendering pipeline.. Application stage (e.g. collision detection)Application stage (e.g. collision detection) Geometry stage (for transformation, projection, lighting, etc.)Geometry stage (for transformation, projection, lighting, etc.) Rasterization stageRasterization stage

applicationan example(It really depends on

implementations.)

geometry rasterization

Page 6: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

6

3 차원 게임 한정현

Rendering Pipeline: Geometry StageRendering Pipeline: Geometry StageRendering Pipeline: Geometry StageRendering Pipeline: Geometry Stage

Modeling Transformation

Geometric transformations for perspective projection Geometric transformations for perspective projection

Lighting calculationLighting calculation

Viewing Transformation

Projection Transformation

Screen Mapping

Local Coordinates

Window CoordinatesNormalized Device Coordinates

World Coordinates Eye Coordinates

x

y

z

n

k

kspec

kdiff

kamb

kkspotemiambglobtot iiidcmmai

1

))(( l

nr

v

light light sourcesource

objectobject

eyeeye

Page 7: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

7

3 차원 게임 한정현

Rendering Pipeline: Rasterization Stage Rendering Pipeline: Rasterization Stage Rendering Pipeline: Rasterization Stage Rendering Pipeline: Rasterization Stage

Pixel/polygon fillingPixel/polygon filling

Shading and texture mappingShading and texture mapping

flat shadingflat shading smooth shadingsmooth shading texture mappingtexture mapping

x

y

scanline algorithmscanline algorithm

texturetexture

Page 8: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

8

3 차원 게임 한정현

Graphics AcceleratorGraphics AcceleratorGraphics AcceleratorGraphics Accelerator

A lot of the pipeline functions are performed by graphics accelerators.A lot of the pipeline functions are performed by graphics accelerators.

[Card]

Milestone graphics cards features

1996 3dfx Voodoo I Triangle setup & clipping

1997 NVIDIA Riva128Competing with Voodoo 1

(relatively high performance and low cost)

1998NVIDIA RivaTNT3dfx Voodoo IIATi Rage128

Hot year for gaming hardware, andalso for game development

(Quake2, Starcraft, Unreal, etc.)

1999 NVIDIA GeForce 256 Hardware transformation & lighting

2000ATi Radeon

NVIDIA GeForce2 GTSCompetition of the two major companies, NVIDIA and ATi

2001NVIDIA GeForce3

(NVIDIA GeForce2 MX)ATi Radeon 8500

Vertex and pixel shader support of DirectX 8.1

2002Radeon 9700 (Radeon 9000

NVIDIA GeForce4 Ti, MX)DirectX HLSL, occlusion query, etc.

2003~NVIDIA GeForce FX 5900, 5950

ATi Radeon 9800 XTDirectX 9.0

Page 9: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

9

3 차원 게임 한정현

OpenGL OpenGL OpenGL OpenGL

We need interfaces to the graphics acceleration hardware, and twWe need interfaces to the graphics acceleration hardware, and two best-known interfaces are OpenGL and DirectX.o best-known interfaces are OpenGL and DirectX.

OpenGL (Open Graphics Library) is the cross-platform OpenGL (Open Graphics Library) is the cross-platform standardstandard f for 3D rendering and 3D hardware acceleration.or 3D rendering and 3D hardware acceleration. For Windows, MacOS, Linux and Unix systems.For Windows, MacOS, Linux and Unix systems. Originally developed by Silicon Graphics Inc. (SGI)Originally developed by Silicon Graphics Inc. (SGI) Since 1992, by the OpenGL Architecture Review Board (ARB)Since 1992, by the OpenGL Architecture Review Board (ARB) 1992 version 1.0 1992 version 1.0 1996 version 1.11996 version 1.1 1998 version 1.21998 version 1.2 2001 version 1.32001 version 1.3 2002 version 1.42002 version 1.4 2003 version 1.52003 version 1.5

OpenGL is a general-purpose graphics library, but many games, sOpenGL is a general-purpose graphics library, but many games, such as id Software’s Quake 3, use OpenGL.uch as id Software’s Quake 3, use OpenGL.

Recently, its mobile version OpenGL ES has been announced.Recently, its mobile version OpenGL ES has been announced.

[OpenGL][OpenGL]

Page 10: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

10

3 차원 게임 한정현

DirectX DirectX DirectX DirectX

The The de factode facto standard for multimedia APIs built into Microsoft Wi standard for multimedia APIs built into Microsoft Windowsndows By Microsoft, and only for Windows platformBy Microsoft, and only for Windows platform Its APIs give multimedia applications access to 3D graphics acceleraIts APIs give multimedia applications access to 3D graphics accelera

tion chips and sound cards. tion chips and sound cards. They also control low-level functions, including 2D graphics accelerThey also control low-level functions, including 2D graphics acceler

ation; support for input devices such as joysticks, keyboards, and mation; support for input devices such as joysticks, keyboards, and mice; and control of sound mixing and sound output. ice; and control of sound mixing and sound output.

First introduced in 1995 and now version 9.0 (2002)First introduced in 1995 and now version 9.0 (2002) DirectX 9.0 componentsDirectX 9.0 components

DirectX Graphics DirectX Graphics DirectInputDirectInput DirectPlay DirectPlay DirectSound DirectSound DirectMusic DirectMusic DirectShow DirectShow DirectSetup DirectSetup DirectX Media ObjectDirectX Media Object [DX][DX]

Page 11: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

11

3 차원 게임 한정현

Part 2. 3D Game PlatformsPart 2. 3D Game Platforms

Page 12: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

12

3 차원 게임 한정현

PCPC Console Console

Xbox, PlayStation 2, etc.Xbox, PlayStation 2, etc. Arcade hardwareArcade hardware Mobile devices Mobile devices

PDA and cell phonePDA and cell phone Game Boy Advance (GBA), PlayStation Portable (PSP), etc.Game Boy Advance (GBA), PlayStation Portable (PSP), etc.

3D Game Platforms 3D Game Platforms 3D Game Platforms 3D Game Platforms

Page 13: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

13

3 차원 게임 한정현

PC: Programmable Pipeline PC: Programmable Pipeline PC: Programmable Pipeline PC: Programmable Pipeline

3D on PC has been based on OpenGL and DirectX.3D on PC has been based on OpenGL and DirectX. Revolution has been going on: from fixed-function pipeline to Revolution has been going on: from fixed-function pipeline to

programmable pipelineprogrammable pipeline..

Fixed-function pipelineFixed-function pipeline

Programmable pipelineProgrammable pipeline

[DX][DX]

[DX][DX]

Page 14: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

14

3 차원 게임 한정현

Vertex and Pixel ShadersVertex and Pixel ShadersVertex and Pixel ShadersVertex and Pixel Shaders

DirectX vertex shader 1.0 DirectX pixel shader 1.4DirectX vertex shader 1.0 DirectX pixel shader 1.4

Pipeline programmability is achieved though shaders.Pipeline programmability is achieved though shaders. Vertex shader (for geometry stage) Vertex shader (for geometry stage) Pixel shader (for rasterization stage)Pixel shader (for rasterization stage)

Page 15: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

15

3 차원 게임 한정현

Shading Languages Shading Languages Shading Languages Shading Languages

DirectXDirectX Version 8.0: assembly languageVersion 8.0: assembly language Version 9.0: HLSL (High Level Shading Language)Version 9.0: HLSL (High Level Shading Language)

OpenGL 1.5 (2003 July) and the upcoming version 2.0 (will) support OpenGL 1.5 (2003 July) and the upcoming version 2.0 (will) support ‘OpenGL Shading Language.’ ‘OpenGL Shading Language.’

//c0~c3: view_proj_matrix//c4~c6: texture_matrix0

dp4 oPos.x, v0, c0dp4 oPos.y, v0, c1dp4 oPos.z, v0, c2dp4 oPos.w, v0, c3

dp4 oT0.x, v0, c4dp4 oT0.y, v0, c5 dp4 oT0.z, v0, c6

float4x4 view_proj_matrix;float4x4 texture_matrix0;

struct VS_OUTPUT { float4 Pos : POSITION; float3 Pshade : TEXCOORD0;};

VS_OUTPUT main (float4 vPosition : POSITION) { VS_OUTPUT Out = (VS_OUTPUT) 0; Out.Pos = mul (view_proj_matrix, vPosition); Out.Pshade = mul (texture_matrix0, vPosition); return Out;}

assembly code example HLSL code example

Page 16: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

16

3 차원 게임 한정현

Car painting with DirectX 9 pixel shaderFur rendering with DirectX 9 pixel shader

Shader: ExamplesShader: ExamplesShader: ExamplesShader: Examples

Shaders work fine for skinning animation, procedural deformation, pShaders work fine for skinning animation, procedural deformation, procedural texture mapping, bump mapping, environment mapping, crocedural texture mapping, bump mapping, environment mapping, cartoon rendering, etc. artoon rendering, etc.

Natural Light with DirectX 9 (Paul Debevec) “Pipe Dream” with DirectX 9 [ATi]

Page 17: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

17

3 차원 게임 한정현

XboxXboxXboxXbox

Microsoft Xbox™ technical specificationsMicrosoft Xbox™ technical specifications Ethernet port Ethernet port 233MHz custom-designed chip, developed by Microsoft and NVIDIA 233MHz custom-designed chip, developed by Microsoft and NVIDIA Intel 733MHz processorIntel 733MHz processor 64 MB RAM and 8/10 GB Hard Drive 64 MB RAM and 8/10 GB Hard Drive 3D Audio Support in Hardware (64-bit)3D Audio Support in Hardware (64-bit)

XDK (Xbox Development Kit) providedXDK (Xbox Development Kit) provided The core of the Xbox's OS is a version derived from Windows 2000 The core of the Xbox's OS is a version derived from Windows 2000

from which numerous functions are removed that are useless on from which numerous functions are removed that are useless on the console.the console.

A subset of the Win32 APIs is supported.A subset of the Win32 APIs is supported. GraphicsGraphics

A subset of Direct3D A subset of Direct3D Compatible with DirectX at the API layer, while providing the thinnest Compatible with DirectX at the API layer, while providing the thinnest

and fastest-possible access to the hardwareand fastest-possible access to the hardware AudioAudio

Based on subsets of DirectSound and DirectMusicBased on subsets of DirectSound and DirectMusic

Page 18: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

18

3 차원 게임 한정현

Code Comparison: Xbox vs. DirectX 8.1 Code Comparison: Xbox vs. DirectX 8.1 Code Comparison: Xbox vs. DirectX 8.1 Code Comparison: Xbox vs. DirectX 8.1

Xbox codeXbox code

Page 19: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

19

3 차원 게임 한정현

Code Comparison: Xbox vs. DirectX 8.1 Code Comparison: Xbox vs. DirectX 8.1 (cont’d)(cont’d)Code Comparison: Xbox vs. DirectX 8.1 Code Comparison: Xbox vs. DirectX 8.1 (cont’d)(cont’d)

DirectX 8.1 codeDirectX 8.1 code

Page 20: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

20

3 차원 게임 한정현

PlayStation 2PlayStation 2PlayStation 2PlayStation 2

PS2 system architecture by Sony Computer Entertainment Inc. (SCEI)PS2 system architecture by Sony Computer Entertainment Inc. (SCEI)

▪ SPU2: Sound Processor Unit

▪ IOP: I/O Processor

▪ EE: Emotion Engine (basically in charge of application and geometry stages)

▪ GS: Graphics Synthesizer (basically in charge of rasterization stage)

Page 21: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

21

3 차원 게임 한정현

PlayStation 2: Development KitPlayStation 2: Development KitPlayStation 2: Development KitPlayStation 2: Development Kit

Use IDE such as SN Systems’ ProDG and Metroworks’ CodeWarrior.Use IDE such as SN Systems’ ProDG and Metroworks’ CodeWarrior. Download the executable into DTL-T10000, and execute it.Download the executable into DTL-T10000, and execute it. DTL-T10000 then displays game scenes into the TV screen.DTL-T10000 then displays game scenes into the TV screen.

The Lord of the Rings (PS2)

Page 22: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

22

3 차원 게임 한정현

Arcade HardwareArcade HardwareArcade HardwareArcade Hardware

SEGA Naomi 2 specificationsSEGA Naomi 2 specifications CPU: 200 MHz Hitachi SH-4 (SH7091)CPU: 200 MHz Hitachi SH-4 (SH7091) Geometry co-processor: VideoLogic custom T&L chip Geometry co-processor: VideoLogic custom T&L chip

SSustained Polygonal and Lighting Rate: 10M polygons/sec with 6 light sourcesustained Polygonal and Lighting Rate: 10M polygons/sec with 6 light sources Supported Lights: Ambient, parallel, point and spot Supported Lights: Ambient, parallel, point and spot

GPU: Two PowerVR2 (CLX2) GPU: Two PowerVR2 (CLX2) Pixel fill-rate: 200M pixels/sec Pixel fill-rate: 200M pixels/sec Graphic Effects: 16-bit and 24-bit color, multiple fog modes, super sampling for fGraphic Effects: 16-bit and 24-bit color, multiple fog modes, super sampling for f

ull scene anti-aliasing, specular highlighting, texture filtering: bilinear, trilinear, aull scene anti-aliasing, specular highlighting, texture filtering: bilinear, trilinear, anistropic, MIP mapping, bump mapping, perspective correction, 8-bit alpha blendnistropic, MIP mapping, bump mapping, perspective correction, 8-bit alpha blending (256 levels of transparency), ARGB gouraud shading, etc.ing (256 levels of transparency), ARGB gouraud shading, etc.

Page 23: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

23

3 차원 게임 한정현

Mobile DevicesMobile DevicesMobile DevicesMobile Devices

Cell phone games (far more popular than PDA games in Korea)Cell phone games (far more popular than PDA games in Korea) Virtual Machine (VM): GVM/GNEX, SK-VM, etc.Virtual Machine (VM): GVM/GNEX, SK-VM, etc. Native Binary: BREW, Symbian, etc.Native Binary: BREW, Symbian, etc.

Let’s see an example: Qualcomm Q3DimensionLet’s see an example: Qualcomm Q3Dimension™™ Gaming Platform Gaming Platform

[Q3Dimension]

Page 24: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

24

3 차원 게임 한정현

OpenGL ESOpenGL ESOpenGL ESOpenGL ES

Hardware graphics accelerators for mobile devices are coming to the Hardware graphics accelerators for mobile devices are coming to the market, and so we need their APIs. A candidate is OpenGL ES.market, and so we need their APIs. A candidate is OpenGL ES.

OpenGL ES: OpenGL for Embedded SystemsOpenGL ES: OpenGL for Embedded Systems Embedded 3D graphics APIEmbedded 3D graphics API A subset of OpenGL A subset of OpenGL By Khronos Group (sgi, Sun, ATI, ARM, NOKIA, Symbian, SK Telecom, etc.)By Khronos Group (sgi, Sun, ATI, ARM, NOKIA, Symbian, SK Telecom, etc.) Version 1.0 at July of 2003Version 1.0 at July of 2003

Embedded Hardware

Low-level Graphics APIs

High Level Graphics Libraries

Applications

[OpenGLES]

Page 25: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

25

3 차원 게임 한정현

Portable Game ConsolePortable Game ConsolePortable Game ConsolePortable Game Console

Nokia N-GageNokia N-Gage™ Game Deck ™ Game Deck Symbian OS with J2ME support Symbian OS with J2ME support A plenty of 3D games already availableA plenty of 3D games already available

PSP (PlayStation Portable) PSP (PlayStation Portable) To appear in 2004 To appear in 2004

[NGage]

PS 2 comparisons PSP

66 M polygons/s geometry stage 33 M polygons/s

2400 M pixels/s pixel fill rate 664M pixels/s

6.4GFlops floating-point operations 2.6GFlops

[PSP]

Page 26: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

26

3 차원 게임 한정현

Part 3. 3D Game Engine and Realtime RenderingPart 3. 3D Game Engine and Realtime Rendering

Page 27: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

27

3 차원 게임 한정현

What’s Game Engine?What’s Game Engine?What’s Game Engine?What’s Game Engine?

A game engine consists ofA game engine consists of library modules such as graphics/rendering, physics, AI, and sound library modules such as graphics/rendering, physics, AI, and sound

(sub) engines, and(sub) engines, and development tools such as map editor and scene graph editor. development tools such as map editor and scene graph editor.

Well-known game engines Well-known game engines Abroad: Quake, Unreal, LithTech, RenderWare, Alchemy, etc.Abroad: Quake, Unreal, LithTech, RenderWare, Alchemy, etc. Domestic: Dream3D, GI3D/G-Blender, etc.Domestic: Dream3D, GI3D/G-Blender, etc.

Let’s focus on the graphics/rendering engine, which is in charge oLet’s focus on the graphics/rendering engine, which is in charge of the f the realtime renderingrealtime rendering..

Page 28: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

28

3 차원 게임 한정현

Realtime RenderingRealtime RenderingRealtime RenderingRealtime Rendering

Performance goals in real-time renderingPerformance goals in real-time rendering frame rate: 60-85 frames/sec?frame rate: 60-85 frames/sec? resolution: 1600x1200?resolution: 1600x1200? photorealism (if necessary): undistinguishable from real scene!photorealism (if necessary): undistinguishable from real scene!

Unfortunately, there is no real upper limit on the scene complexity. Unfortunately, there is no real upper limit on the scene complexity. Jurassic Park's T-REX model : ~175,000 polygonsJurassic Park's T-REX model : ~175,000 polygons Boeing-777 model: ~500,000,000 polygonsBoeing-777 model: ~500,000,000 polygons

Therefore, numerous acceleration techniques have been developed. Therefore, numerous acceleration techniques have been developed. Let’s take one of them, Let’s take one of them, mesh simplificationmesh simplification and and levels of detail (LOD)levels of detail (LOD) technique, that can be done at the application stage of the rendering technique, that can be done at the application stage of the rendering pipeline.pipeline.

Page 29: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

29

3 차원 게임 한정현

Mesh SimplificationMesh Simplification Mesh SimplificationMesh Simplification

What do you want for mesh simplification?What do you want for mesh simplification? Geometric accuracy?Geometric accuracy? Visual fidelity?Visual fidelity? Drastic simplification?Drastic simplification? Completely automatic?Completely automatic? What else?What else?

The computer graphics literature is replete with excellent simplification The computer graphics literature is replete with excellent simplification algorithms, each with strengths and weaknesses.algorithms, each with strengths and weaknesses.

A popular approach is edge collapse (A popular approach is edge collapse (ecolecol), whose inverse operation is ), whose inverse operation is vertex split (vertex split (vsplitvsplit).).

Page 30: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

30

3 차원 게임 한정현

Progressive MeshProgressive MeshProgressive MeshProgressive Mesh

Mn Mi Mj M0

ecoln-1 ecoli-1 ecol0

Repeated application of Repeated application of ecolecol operations operations

Repeated application of vsplit operationsRepeated application of vsplit operations

Which LOD to use? Discrete or continuous?Which LOD to use? Discrete or continuous? As discrete LOD leads to popping effect, continuous LOD is preferable.As discrete LOD leads to popping effect, continuous LOD is preferable. A continuous LOD: The coarsest mesh A continuous LOD: The coarsest mesh MM00 and the series of and the series of vsplitvsplit operations constitut operations constitut

e the e the progressive mesh.progressive mesh.

M0 Mj Mi Mn

vsplit0 vsplitj vsplitn-1

Page 31: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

31

3 차원 게임 한정현

Progressive Mesh:Progressive Mesh: DemoDemoProgressive Mesh:Progressive Mesh: DemoDemo

Page 32: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

32

3 차원 게임 한정현

View-dependent LOD of Progressive MeshView-dependent LOD of Progressive MeshView-dependent LOD of Progressive MeshView-dependent LOD of Progressive Mesh

out of view frustum

back facing

distant

view–independent LOD view–dependent LOD

Criteria for view-dependent LODCriteria for view-dependent LOD View frustumView frustum Surface orientationSurface orientation Screen space errorScreen space error etc.etc.

Page 33: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

33

3 차원 게임 한정현 The Current Status of LOD in Game The Current Status of LOD in Game DevelopmentDevelopmentThe Current Status of LOD in Game The Current Status of LOD in Game DevelopmentDevelopment

DirectX has supported progressive mesh since v8.0.DirectX has supported progressive mesh since v8.0.

However, it seems that no game is using it at runtime. For example, However, it seems that no game is using it at runtime. For example, Homeworld2 (2003 by Relic Entertainment) simply adopts just a few Homeworld2 (2003 by Relic Entertainment) simply adopts just a few (discrete) LOD models with popping effect.(discrete) LOD models with popping effect.

Think about why? That will answer what 3D researchers have to do …Think about why? That will answer what 3D researchers have to do …

ID3DXMesh *ID3DXMesh *pMesh = NULL;pMesh = NULL;

ID3DXPMesh *m_pPMeshFull;ID3DXPMesh *m_pPMeshFull;

D3DXLoadMeshFromX( strMediaPath,…, &pMesh );D3DXLoadMeshFromX( strMediaPath,…, &pMesh );

D3DXGeneratePMesh( pMesh,…, & m_pPMeshFull);D3DXGeneratePMesh( pMesh,…, & m_pPMeshFull);

m_pPMeshFull->SetNumVertices( dwNumVertices );m_pPMeshFull->SetNumVertices( dwNumVertices );

m_pPMeshFull->DrawSubset( i );m_pPMeshFull->DrawSubset( i );

Page 34: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

34

3 차원 게임 한정현

Physics EnginePhysics EnginePhysics EnginePhysics Engine

Physics engines provide realistic motions and interactions between rePhysics engines provide realistic motions and interactions between real-world objects.al-world objects.

Components of physics enginesComponents of physics engines Collision: Detection and ResponseCollision: Detection and Response FluidFluid ParticleParticle Rigid BodyRigid Body JointJoint Spring and DamperSpring and Damper etc.etc.

Commercial physics enginesCommercial physics engines Havok Engine (Havok Engine (http://www.havok.comhttp://www.havok.com)) RenderWare Physics Engine (http://www.renderware.com)RenderWare Physics Engine (http://www.renderware.com)

Page 35: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

35

3 차원 게임 한정현

AI Engine AI Engine AI Engine AI Engine

Virtually all techniques used in academic AI are also useful in gamVirtually all techniques used in academic AI are also useful in game AI, including finite-state machines, learning, path finding, multi-ae AI, including finite-state machines, learning, path finding, multi-agent cooperation, fuzzy logic, neural network, genetic algorithms, ngent cooperation, fuzzy logic, neural network, genetic algorithms, natural language processing, etc. atural language processing, etc.

However, game AI is basically for However, game AI is basically for funfun while academic AI pursues e while academic AI pursues extraordinarily difficult problems such as imitating human cognition.xtraordinarily difficult problems such as imitating human cognition.

Commercial AI enginesCommercial AI engines AI.implantAI.implant

(http://www.ai-implant.com) SparkSpark

(http://www.louderthanabomb.com/) PathEnginePathEngine

(http://www.pathengine.com/) RenderWare AI Engine RenderWare AI Engine

(http://www.renderware.com)(http://www.renderware.com)

Sound engine is also needed, e.g. for 3D sound generation.Sound engine is also needed, e.g. for 3D sound generation.

Page 36: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

36

3 차원 게임 한정현

Next-generation IT Leaders: What To DoNext-generation IT Leaders: What To DoNext-generation IT Leaders: What To DoNext-generation IT Leaders: What To Do

A lot of research topics are in the areas of realtime rendering, physA lot of research topics are in the areas of realtime rendering, physics, AI, etc.ics, AI, etc.

Publish papers in prestigious societies such as SIGGRAPH.Publish papers in prestigious societies such as SIGGRAPH.

However, always face the real world. Do However, always face the real world. Do NOTNOT research for research. research for research. Work with game developers, and understand what the difficulties aWork with game developers, and understand what the difficulties a

nd challenges are in the real world.nd challenges are in the real world. They are eager to have your support!!!!They are eager to have your support!!!!

Page 37: 성균관대학교 정보통신공학부 한정현 2003 / 11 / 15

37

3 차원 게임 한정현

ReferencesReferencesReferencesReferences

[ATi] http://www.ati.com/developer/[ATi] http://www.ati.com/developer/ [Card] Graphics Cards Articles In Chronological Overview http://www.[Card] Graphics Cards Articles In Chronological Overview http://www.

tomshardware.com/graphic/tomshardware.com/graphic/ [DX] http://www.microsoft.com/directx[DX] http://www.microsoft.com/directx [Gamemeca] [Gamemeca] http://www.gamemeca.comhttp://www.gamemeca.com [idS] id Software http://www.idsoftware.com[idS] id Software http://www.idsoftware.com [NGage] http://www.n-gage.com[NGage] http://www.n-gage.com

[OpenGL] http://www.opengl.org[OpenGL] http://www.opengl.org [OpenGLES] Bringing 3D Graphics to Embedded Systems, BOF SIGG[OpenGLES] Bringing 3D Graphics to Embedded Systems, BOF SIGG

RAPH2003RAPH2003 [PSP] [PSP] http://http://www.kgda.or.kr/cgi/technote/read.cgi?boardwww.kgda.or.kr/cgi/technote/read.cgi?board==

info&y_numberinfo&y_number=1345&nnew=1=1345&nnew=1 [Q3Dimension] Q3Dimension™ gaming platform, http://www.cdmatec[Q3Dimension] Q3Dimension™ gaming platform, http://www.cdmatec

h.com/solutions/products/q3dimension.jsph.com/solutions/products/q3dimension.jsp