Game Engines l Game Engine Assets models animations

  • Slides: 16
Download presentation
Game Engines l Game: – Engine – Assets (models, animations, sounds, AI, and physics)

Game Engines l Game: – Engine – Assets (models, animations, sounds, AI, and physics) – Code (Rules, AI, Scripting, etc. )

GE 161 l Includes – Main game loop, framerate – Event queue – 2

GE 161 l Includes – Main game loop, framerate – Event queue – 2 D sprites – Text l What is missing?

3 D Game Engines: Rendering Pipeline 1. Application/Scene l l l 2. Geometry l

3 D Game Engines: Rendering Pipeline 1. Application/Scene l l l 2. Geometry l l 3. Transforms: Model/World/Viewport & Backface Culling Triangles l 4. Scene database update/traversal Object/Camera Movement/Animation Visibility/LOD/Culling Scan-line conversion Rasterization l l l Shading Texturing/Fog/Alpha Depth

Game Engines: Shading Flat l Vertex (Gouraud) l Pixel (Phong) l Light Maps l

Game Engines: Shading Flat l Vertex (Gouraud) l Pixel (Phong) l Light Maps l Programmable (Vertex & Pixel Shaders) l

Game Engines: Memory Management l Cache Thrashing – – – l Group Primitives by

Game Engines: Memory Management l Cache Thrashing – – – l Group Primitives by Textures? Hardware T&L Compression Card Memory – – Why isn’t 32 bit color (16. 7 M) enough? 1280 x 1024 x 12 (Front, Back, Z)= 15 MB

Engine Considerations l l l l l Platforms Performance Data Rendering/Features Animation Physics &

Engine Considerations l l l l l Platforms Performance Data Rendering/Features Animation Physics & Environment Scripting Authoring I/O Save/Load

Performance l Occlusion Culling – Cell Based: BSP tree, Portal, Octree – Other: Potentially

Performance l Occlusion Culling – Cell Based: BSP tree, Portal, Octree – Other: Potentially Visible Set, HOM l LOD l Adaptive NURBS/Patches l Polygon Reduction l Terrain Primitives

Data Import/Export l 3 D file formats – X, 3 DS, MDL, MD 2,

Data Import/Export l 3 D file formats – X, 3 DS, MDL, MD 2, MAP, WAD Texture/Image Formats l Models/Animations: l – l Levels – l Maya, 3 D Studio MAX Worldcraft. T or Milkshape. T Plugins

Rendering Features l Open. GL vs. Direct. X – DX 6 -9 – Open.

Rendering Features l Open. GL vs. Direct. X – DX 6 -9 – Open. GL 1. 1 -1. 5, 2. 0 l l l Shadow Maps (Lightmaps) Shaders Dynamic Shadows MIP Maps/Multi Maps/ Bump Mapping Effects

Animation l l l l Keyframe Bones (Skinning) Facial Animation Vertex Animation Inverse Kinematics

Animation l l l l Keyframe Bones (Skinning) Facial Animation Vertex Animation Inverse Kinematics (IK) Dynamics High-level Authoring

Physics & Physical Environment l l l Visibility Collision Detection Terrain Following Gravity Physics

Physics & Physical Environment l l l Visibility Collision Detection Terrain Following Gravity Physics – Rigid & non-rigid bodies

Scripting • • Scripting languages add logic for controlling actors or objects Languages: •

Scripting • • Scripting languages add logic for controlling actors or objects Languages: • • • Javascript Luo -http: //www. lua. org/ Python Basic Custom: Unreal. Script, C-Script, etc. Script Compilers for performance

Save/Load System • • • allows the end user to save a complete game

Save/Load System • • • allows the end user to save a complete game state. 'freezes' all running scripts and all objects and variables of the game and writes them into a file Without such a system: • a script has to be written which stores the state of every variable and object and the position within every script function

Authoring/Editing • • • Level Editor Model Editor Script Editor Terrain Logic

Authoring/Editing • • • Level Editor Model Editor Script Editor Terrain Logic

GE 161 l What is missing? – 3 D support – Memory management, Multi-threading

GE 161 l What is missing? – 3 D support – Memory management, Multi-threading support – Scripting, Authoring – Save/Load – Physics – High performance data structures – Data Import and Export – Middleware integration (beyond SDL)

GE 161 l What is missing? – Networking – Sound

GE 161 l What is missing? – Networking – Sound