Prof. Roger Crawfis Computer Science & Engineering The Ohio State University Advanced Game Design.

Slides:



Advertisements
Similar presentations
SEMINAR ON VIRTUAL REALITY 25-Mar-17
Advertisements

A Natural Interactive Game By Zak Wilson. Background This project was my second year group project at University and I have chosen it to present as it.
Virtual Reality Design Virtual reality systems are designed to produce in the participant the cognitive effects of feeling immersed in the environment.
Survey of Graphics and Games. Outline Overview of computer graphics – Coursework – Research Programming using game engines Computer game and animation.
Operating Systems High Level View Chapter 1,2. Who is the User? End Users Application Programmers System Programmers Administrators.
OS Fall ’ 02 Introduction Operating Systems Fall 2002.
W4118 Operating Systems OS Overview Junfeng Yang.
Game Design and Programming. Objectives Classify the games How games are design How games are implemented What are the main components of a game engine.
CHAPTER 1 Introduction to Game Development © 2008 Cengage Learning EMEA.
Chapter 13 Embedded Systems
Chapter 1 and 2 Computer System and Operating System Overview
Underlying Technologies Part Two: Software Mark Green School of Creative Media.
Ch 1 Intro to Graphics page 1CS 367 First Day Agenda Best course you have ever had (survey) Info Cards Name, , Nickname C / C++ experience, EOS experience.
AGD: 5. Game Arch.1 Objective o to discuss some of the main game architecture elements, rendering, and the game loop Animation and Games Development.
Virtual Reality Virtual Reality involves the user entering a 3D world generated by the computer. To be immersed in a 3D VR world requires special hardware.
Matthew J Mattia CSC  Cumbersome Code  Consistent/Predictable design (GUEPs #5, CD’s #10)  Display “proper” amount of information  Including.
Hardware Specialised Devices
Week 1 - Friday.  What did we talk about last time?  C#  SharpDX.
University of Texas at Austin CS 378 – Game Technology Don Fussell CS 378: Computer Game Technology Spring.
COM 205 Multimedia Applications
CSE 381 – Advanced Game Programming 3D Game Architecture.
SOFTWARE.
Designing 3D Interfaces Examples of 3D interfaces Pros and cons of 3D interfaces Overview of 3D software and hardware Four key design issues: system performance,
Introduction and Overview Questions answered in this lecture: What is an operating system? How have operating systems evolved? Why study operating systems?
London April 2005 London April 2005 Creating Eyeblaster Ads The Rich Media Platform The Rich Media Platform Eyeblaster.
London April 2005 London April 2005 Creating Eyeblaster Ads The Rich Media Platform The Rich Media Platform Eyeblaster.
Computing and the Web Operating Systems. Overview n What is an Operating System n Booting the Computer n User Interfaces n Files and File Management n.
Computer Graphics An Introduction. What’s this course all about? 06/10/2015 Lecture 1 2 We will cover… Graphics programming and algorithms Graphics data.
10/9/20151 Unreal Basics CIS 488/588 Bruce R. Maxim UM-Dearborn.
Multimedia Elements: Sound, Animation, and Video.
(c) University of Washington08-1 CSC 143 Models and Views Reading: Ch. 18.
Virtual Reality Lecture2. Some VR Systems & Applications 고려대학교 그래픽스 연구실.
4.1 Advanced Operating Systems Desktop Scheduling You are running some long simulations. In the mean time, why not watch an illegally downloaded Simpsons.
Graphics. What is a Graphic ? A Graphic is an image or a picture e.g. Pictures can be either drawn or painted. Pixel - Stands for Picture Element.
Issues Autonomic operation (fault tolerance) Minimize interference to applications Hardware support for new operating systems Resource management (global.
2.1. T HE G AME L OOP Central game update and render processes.
Reference: The Game Loop Animation / Game loop 1. Update variables 2. [Get input from the user] (GameLoop only) 3. Draw (using variables)
CS 638, Fall 2001 Interactive Programs Games are interactive systems - they must respond to the user Today is all about how interactive programs are designed.
Games Development Game Architecture: Entities CO2301 Games Development 1 Week 22.
11 General Game Programming Approach. The program is event-driven The program is event-driven –Messages = events –So as all windows system (for example.
Computer Graphics: Programming, Problem Solving, and Visual Communication Steve Cunningham California State University Stanislaus and Grinnell College.
Introduction to Interactive Media Interactive Media Tools: Authoring Applications.
1 Software. 2 What is software ► Software is the term that we use for all the programs and data on a computer system. ► Two types of software ► Program.
Reading Flash. Training target: Read the following reading materials and use the reading skills mentioned in the passages above. You may also choose some.
Super Pong Andrew S. Dunsmore CSC436 August 2004.
Vizard Virtual Reality Toolkits Vizard Virtual Reality Toolkits.
Games Development 1 Review / Revision CO2301 Games Development 1 Semester 2.
1 Lecture 1: Computer System Structures We go over the aspects of computer architecture relevant to OS design  overview  input and output (I/O) organization.
SCRIPT PROGRAMMING WITH FLASH Introductory Level 1.
UW EXTENSION CERTIFICATE PROGRAM IN GAME DEVELOPMENT 2 ND QUARTER: ADVANCED GRAPHICS Game program main loop.
GAM666 – Introduction To Game Programming ● Programmer's perspective of Game Industry ● Introduction to Windows Programming ● 2D animation using DirectX.
T HE G AME L OOP. A simple model How simply could we model a computer game? By separating the game in two parts: – the data inside the computer, and –
1 Why Threads are a Bad Idea (for most purposes) based on a presentation by John Ousterhout Sun Microsystems Laboratories Threads!
09/04/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Course intro Project management –Group size limit increased to 5 –Lecture notes had.
An operating system (OS) is a collection of system programs that together control the operation of a computer system.
Some of the utilities associated with the development of programs. These program development tools allow users to write and construct programs that the.
Reference: What is it? A multimedia python library – Window Management – Graphics geometric shapes bitmaps (sprites) – Input Mouse Keyboard.
Applications and Rendering pipeline
Interactive Animation
Computer Graphics Lecture 1 Introduction to Computer Graphics
Understand Windows Forms Applications and Console-based Applications
Advanced Game Design Dr. Matt Boggus
CSCI1600: Embedded and Real Time Software
Operating Systems.
AN INTRODUCTION TO COMPUTER GRAPHICS Subject: Computer Graphics Lecture No: 01 Batch: 16BS(Information Technology)
Chapter I Introduction
Model, View, Controller design pattern
02 | What DirectX Can Do and Creating the Main Game Loop
CSCI1600: Embedded and Real Time Software
Chapter 13: I/O Systems “The two main jobs of a computer are I/O and [CPU] processing. In many cases, the main job is I/O, and the [CPU] processing is.
Presentation transcript:

Prof. Roger Crawfis Computer Science & Engineering The Ohio State University Advanced Game Design

Course Overview Project-based / Team-based Little lecturing Focus on programming for games Systems integration – graphics, sound, AI, networking, user- interfaces, physics, scripting Utilize higher-level toolkits, allowing for more advanced progress while still developing programming skills.

Course Structure We will lecture for about the first two weeks. Student game project groups will provide several presentations on their game ideas and progress. Student technology teams will provide an intermediate and an advanced lecture on their findings and analysis about their area.

Project Goals Large-scale software development Team-based (synergistic development) Toolkit-based (fast-start development) Learn and utilize the many non-graphical elements needed for games. Leverage and extend your graphics and AI expertise.

Elements Gaming Engine Responsible for providing primitives Hardware abstraction Handle different areas of the game Physics, AI, etc. Game Defined by a genre Defines the gameplay

Requirements of a gaming engine Stunning Visuals Artificial Intelligence Immersive sound stage Simulation Animation Networking

Requirements of a game Scripting Varied input/output devices Supporting Tools Optimizing game content Developing game content Extending game content Debugging / Tuning of game performance

Stunning Visuals Adding realism Smarter Models Clutter Use hardware Bump-mapping Dynamic water or other liquids Rich textures (Billboards, gloss-maps, light-maps, etc.) Shadows Particle systems

Artificial Intelligence Games need specialized AI Strategy Path finding Modeling behavior Learning

Immersive sound stage Multi-track sound support Positional sound effects (3D immersion) Dynamic sounds / movement (doppler effects)

Input devices Commonly available devices are Keyboard, mouse, gamepads and joysticks Force feedback (haptic) devices are gaining popularity Steering wheels Joysticks Motion tracking Output devices Multiple monitors Head mounted displays

Scalability Multiple hardware capabilities Multi-resolution models Multi-user support LOD Multiple model definitions Multi-res models Subdivision surfaces

Scalability Multiple hardware capabilities Multi-resolution models Multi-user support LOD (Level-Of-Detail) Control – when to switch Construction – what levels to have

Animation Linear transformations Modeled animations Articulated motion Lip syncing Facial Expressions Blending animations

Networking Multi-player support essential Common problems Latency Synchronization Scalability Consistent game state Security

Scripting Strict coding is tedious Support for scripting is essential for RAD Scripting has added a whole new fun factor for many games.

Artificial Intelligence Games need specialized AI Strategy Path finding Modeling behavior Learning Non-perfect! Fast!

Tools Creating varied content models, video, images, sound Integrating content Common file format support Supporting existing popular tools via plug-ins 3DS Max, Lightwave, Maya etc. Adobe premier, Adobe Photoshop

Interactive Programs Games are interactive systems - they must respond to the user How?

Interactive Program Structure Event driven programming Everything happens in response to an event Events come from two sources: The user The system Events are also called messages An event causes a message to be sent… Initialize User Does Something or Timer Goes Off System Updates

User Events The OS manages user input Interrupts at the hardware level … Get converted into events in queues at the windowing level … Are made available to your program It is generally up to the application to make use of the event stream Windowing system / Game Framework may abstract the events for you

Polling for Events Most windowing systems provide a non-blocking event function Does not wait for an event, just returns NULL if one is not ready What type of games might use this structure? Why wouldn’t you always use it? while ( true ) if ( e = checkEvent() ) switch ( e.type ) … do more work

Waiting for Events Most windowing systems provide a blocking event function Waits (blocks) until an event is available Usually used with timer events. Why? On what systems is this better than the previous method? What types of games is it useful for? e = nextEvent(); switch ( e.type ) …

The Callback Abstraction A common event abstraction is the callback mechanism Applications register functions they wish to have called in response to particular events Translation table says which callbacks go with which events Generally found in GUI (graphical user interface) toolkits “When the button is pressed, invoke the callback” Many systems mix methods, or have a catch-all callback for unclaimed events Why are callbacks good? Why are they bad?

Upon Receiving an Event … Event responses fall into two classes: Task events: The event sparks a specific task or results in some change of state within the current mode eg Load, Save, Pick up a weapon, turn on the lights, … Call a function to do the job Mode switches: The event causes the game to shift to some other mode of operation eg Start game, quit, go to menu, … Switch event loops, because events now have different meanings Software structure reflects this - menu system is separate from run-time game system, for example

Real-Time Loop At the core of interactive games is a real-time loop: What else might you need to do? The number of times this loop executes per second is the frame rate # frames per second (fps) while ( true ) process events update animation / scene render

Lag Lag is the time between when a user does something and when they see the result - also called latency Too much lag and causality is distorted With tight visual/motion coupling, too much lag makes people motion sick Big problem with head-mounted displays for virtual reality Too much lag makes it hard to target objects (and track them, and do all sorts of other perceptual tasks) High variance in lag also makes interaction difficult Users can adjust to constant lag, but not variable lag From a psychological perspective, lag is the important variable

Computing Lag Lag is NOT the time it takes to compute 1 frame! What is the formula for maximum lag as a function of frame rate, fr? What is the formula for average lag? Process input Update state Render Process input Update state Render Process input Frame time Lag Event time

Frame Rate Questions What is an acceptable frame rate for twitch games? Why? What is the maximum useful frame rate? Why? What is the frame rate for NTSC television? What is the minimum frame rate required for a sense of presence? How do we know? How can we manipulate the frame rate?

Frame Rate Answers (I) Twitch games demand at least 30fs, but the higher the better (lower lag) Users see enemy’s motions sooner Higher frame rates make targeting easier The maximum useful frame rate is the monitor refresh rate Time taken for the monitor to draw one screen Synchronization issues Buffer swap in graphics is timed with vertical sweep, so ideal frame rate is monitor refresh rate Can turn of synchronization, but get nasty artifacts on screen

Frame Rate Answers (II) NTSC television draws all the odd lines of the screen, then all the even ones (interlace format) Full screen takes 1/30th of a second Use 60fps to improve visuals, but only half of each frame actually gets drawn by the screen Do consoles only render 1/2 screen each time? It was once argued that 10fps was required for a sense of presence (being there) Head mounted displays require 20fps or higher to avoid illness Many factors influence the sense of presence Perceptual studies indicate what frame rates are acceptable

Reducing Lag Faster algorithms and hardware is the obvious answer Designers choose a frame rate and put as much into the game as they can without going below the threshold Part of design documents presented to the publisher Threshold assumes fastest hardware and all game features turned on Options given to players to reduce game features and improve their frame rate There is a resource budget: How much of the loop is dedicated to each aspect of the game (graphics, AI, sound, …) Some other techniques allow for more features and less lag

Decoupling Computation It is most important to minimize lag between the user actions and their direct consequences So the input/rendering loop must have low latency Lag between actions and other consequences may be less severe Time between input and the reaction of enemy can be greater Time to switch animations can be greater Technique: Update different parts of the game at different rates, which requires decoupling them For example, run graphics at 60fps, AI at 10fps Done in Unreal engine, for instance

Animation and Sound Animation and sound need not be changed at high frequency, but they must be updated at high frequency For example, switching from walk to run can happen at low frequency, but joint angles for walking must be updated at every frame Solution is to package multiple frames of animation and submit them all at once to the renderer Good idea anyway, makes animation independent of frame rate Sound is offloaded to the sound card