sprite rendering

18
Sprite Rendering Games, Interaction and Robotics 2011

Upload: horizongir

Post on 09-Jul-2015

675 views

Category:

Technology


1 download

DESCRIPTION

A presentation on the basics of 3D render systems and their application to 2D sprite rendering.

TRANSCRIPT

Page 1: Sprite Rendering

Sprite Rendering

Games, Interaction and Robotics 2011

Page 2: Sprite Rendering

The Game Loop

Process Input

Update World

Render

Page 3: Sprite Rendering

Synthesis vs Analysis

Model Image

ComputerGraphics

ComputerVision

Page 4: Sprite Rendering

Rendering Steps

• A virtual scene is described, usually in terms of 3D surfaces in mathematical form.

• A virtual camera is positioned and oriented to produce the desired view of the scene.

• Various light sources are defined.

• The visual properties of the surfaces in the scene are described.

• The render equation is solved.

Chapter 10. Game Engine Architecture, 2009, A K Peters, Ltd.

Page 5: Sprite Rendering

Triangle Meshes

An example of a polygon mesh. Chrschn, 2007.

Page 6: Sprite Rendering

Texture Mapping

A depiction of how UV-Mapping works, showing the classic example of mapping a globe. Drawing by TSchmits, 2008.

Page 7: Sprite Rendering

3D Projection

Principle of the geometrical perspective projection. Drawing by Joachim Baecker, 2005.

Page 8: Sprite Rendering

Coordinate Systems

Handedness cartesian coordinate system in 3D. Gustavb, 2006.

Left-Handed Right-Handed

Page 9: Sprite Rendering

What’s in a Sprite?

Page 10: Sprite Rendering

What’s in a Sprite?

Page 11: Sprite Rendering

Transformation Matrix

Page 12: Sprite Rendering

Transformation Matrix

Page 13: Sprite Rendering

Transformation Matrix

Page 14: Sprite Rendering

Transformation Matrix

Page 15: Sprite Rendering

Composite Transformation

Page 16: Sprite Rendering

Orthographic Projection

• Projection lines orthogonal to projection plane.

• Distance to viewpoint does not decrease apparent size of object.

Page 17: Sprite Rendering

Rendering Sprites

Page 18: Sprite Rendering

Bibliography

1. Game Engine Architecture, Jason Gregory, 2009, A K Peters, Ltd.

2. OpenGL® Programming Guide: The Official Guide to Learning OpenGL®, Version 2.1, 6th Edition, 2007, Addison-Wesley Professional