Game Physics Cookbook
eBook - ePub

Game Physics Cookbook

Gabor Szauer

Condividi libro
  1. 480 pagine
  2. English
  3. ePUB (disponibile sull'app)
  4. Disponibile su iOS e Android
eBook - ePub

Game Physics Cookbook

Gabor Szauer

Dettagli del libro
Anteprima del libro
Indice dei contenuti
Citazioni

Informazioni sul libro

Discover over 100 easy-to-follow recipes to help you implement efficient game physics and collision detection in your gamesAbout This Book• Get a comprehensive coverage of techniques to create high performance collision detection in games• Learn the core mathematics concepts and physics involved in depicting collision detection for your games• Get a hands-on experience of building a rigid body physics engineWho This Book Is ForThis book is for beginner to intermediate game developers. You don't need to have a formal education in games—you can be a hobbyist or indie developer who started making games with Unity 3D.What You Will Learn• Implement fundamental maths so you can develop solid game physics• Use matrices to encode linear transformations• Know how to check geometric primitives for collisions• Build a Physics engine that can create realistic rigid body behavior• Understand advanced techniques, including the Separating Axis Theorem• Create physically accurate collision reactions• Explore spatial partitioning as an acceleration structure for collisions• Resolve rigid body collisions between primitive shapesIn DetailPhysics is really important for game programmers who want to add realism and functionality to their games. Collision detection in particular is a problem that affects all game developers, regardless of the platform, engine, or toolkit they use.This book will teach you the concepts and formulas behind collision detection. You will also be taught how to build a simple physics engine, where Rigid Body physics is the main focus, and learn about intersection algorithms for primitive shapes.You'll begin by building a strong foundation in mathematics that will be used throughout the book. We'll guide you through implementing 2D and 3D primitives and show you how to perform effective collision tests for them. We then pivot to one of the harder areas of game development—collision detection and resolution.Further on, you will learn what a Physics engine is, how to set up a game window, and how to implement rendering. We'll explore advanced physics topics such as constraint solving. You'll also find out how to implement a rudimentary physics engine, which you can use to build an Angry Birds type of game or a more advanced game.By the end of the book, you will have implemented all primitive and some advanced collision tests, and you will be able to read on geometry and linear Algebra formulas to take forward to your own games!Style and approachGain the necessary skills needed to build a Physics engine for your games through practical recipes, in an easy-to-read manner. Every topic explained in the book has clear, easy to understand code accompanying it.

Domande frequenti

Come faccio ad annullare l'abbonamento?
È semplicissimo: basta accedere alla sezione Account nelle Impostazioni e cliccare su "Annulla abbonamento". Dopo la cancellazione, l'abbonamento rimarrà attivo per il periodo rimanente già pagato. Per maggiori informazioni, clicca qui
È possibile scaricare libri? Se sì, come?
Al momento è possibile scaricare tramite l'app tutti i nostri libri ePub mobile-friendly. Anche la maggior parte dei nostri PDF è scaricabile e stiamo lavorando per rendere disponibile quanto prima il download di tutti gli altri file. Per maggiori informazioni, clicca qui
Che differenza c'è tra i piani?
Entrambi i piani ti danno accesso illimitato alla libreria e a tutte le funzionalità di Perlego. Le uniche differenze sono il prezzo e il periodo di abbonamento: con il piano annuale risparmierai circa il 30% rispetto a 12 rate con quello mensile.
Cos'è Perlego?
Perlego è un servizio di abbonamento a testi accademici, che ti permette di accedere a un'intera libreria online a un prezzo inferiore rispetto a quello che pagheresti per acquistare un singolo libro al mese. Con oltre 1 milione di testi suddivisi in più di 1.000 categorie, troverai sicuramente ciò che fa per te! Per maggiori informazioni, clicca qui.
Perlego supporta la sintesi vocale?
Cerca l'icona Sintesi vocale nel prossimo libro che leggerai per verificare se è possibile riprodurre l'audio. Questo strumento permette di leggere il testo a voce alta, evidenziandolo man mano che la lettura procede. Puoi aumentare o diminuire la velocità della sintesi vocale, oppure sospendere la riproduzione. Per maggiori informazioni, clicca qui.
Game Physics Cookbook è disponibile online in formato PDF/ePub?
Sì, puoi accedere a Game Physics Cookbook di Gabor Szauer in formato PDF e/o ePub, così come ad altri libri molto apprezzati nelle sezioni relative a Ciencia de la computación e Programación de juegos. Scopri oltre 1 milione di libri disponibili nel nostro catalogo.

Informazioni

Anno
2017
ISBN
9781787120815

Game Physics Cookbook


Table of Contents

Game Physics Cookbook
Credits
About the Author
Acknowledgements
About the Reviewer
Acknowledgements
www.PacktPub.com
eBooks, discount offers, and more
Why Subscribe?
Customer Feedback
Preface
What this book covers
What you need for this book
Who this book is for
Sections
Getting ready
How to do it…
How it works…
There's more…
See also
Conventions
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Vectors
Introduction
Vector definition
Getting ready
How to do it…
How it works…
There's more…
The W component
Component-wise operations
Getting ready
How to do it…
How it works…
Addition
Subtraction
Multiplication (Vector and Scalar)
Comparison
There's more…
Dot product
How to do it…
How it works…
There's more…
Geometric definition
Magnitude
Getting ready
How to do it…
How it works…
There's more…
Normalizing
Getting ready
How to do it…
How it works…
Cross product
Getting ready
How to do it…
How it works…
Angles
Getting ready
How to do it…
How it works…
There's more…
Radians and degrees
Projection
Getting ready
How to do it…
How it works…
Reflection
Getting ready
How to do it…
How it works…
2. Matrices
Introduction
Matrix definition
Getting ready
How to do it…
How it works…
Transpose
Getting ready
How to do it…
How it works…
Multiplication
Getting ready
How to do it…
How it works…
Identity matrix
Getting ready
How to do it…
How it works…
Determinant of a 2x2 matrix
How to do it…
How it works…
Matrix of minors
Getting ready
How to do it…
How it works…
Minor of a 2x2 matrix
Minor of a 3x3 matrix
Cofactor
Getting ready
How to do it…
How it works…
Determinant of a 3x3 matrix
Getting ready
How to do it…
How it works…
Operations on a 4x4 matrix
Getting ready
How to do it…
How it works…
Adjugate matrix
Getting ready
How to do it…
How it works…
Matrix inverse
Getting ready
How to do it…
How it works…
There's more…
Expanding the inverse
3. Matrix Transformations
Introduction
Matrix majors
Translation
Getting Ready
How to do it…
How it works…
Scaling
Getting ready
How to do it…
How it works…
How rotations work
Getting ready
How to do it…
How it works…
Rotation matrices
Getting ready
How to do it…
How it works…
X-Basis vector
Y-Basis vector
Z-Basis vector
There's more…
X and Y rotation
Axis angle rotation
Getting ready
How to do it…
How it works…
Vector matrix multiplication
Getting ready
How to do it…
How it works…
Transform matrix
Getting ready
How to do it…
How it works…
View matrix
Getting ready
How to do it…
How it works…
Projection matrix
Getting ready
How to do it…
How it works…
4. 2D Primitive Shapes
Introduction
2D points
Getting ready
How to do it…
How it works…
2D lines
Getting ready
How to do it…
How it works…
Circle
Getting ready
How to do it…
How it works…
Rectangle
Getting ready
How to do it…
How it works…
Oriented rectangle
Getting ready
How to do it…
How it works…
Point containment
Getting ready
How to do it…
How it works…
Point on a line
Point in a circle
Point in a rectangle
Point in an oriented rectangle
Line intersection
Getting ready
How to do it…
How it works…
Line circle
Line rectangle
Line oriented rectangle
5. 2D Collisions
Introduction
Circle to circle
Getting ready
How to do it…
How it works…
Circle to rectangle
Getting ready
How to do it…
How it works…
There's more…
Circle to oriented rectangle
Getting ready
How to do it…
How it works…
Rectangle to rectangle
Getting ready
How to do it…
How it works…
Separating Axis Theorem
Getting ready
How to do it…
How it works…
There's more…
Determining which axis to test
Rectangle to oriented rectangle
Getting ready
How to do it…
How it works…
Oriented rectangle to oriented rectangle
Getting ready
How to do it…
How it works…
6. 2D Optimizations
Introduction
Containing circle
Getting ready
How to do it…
How it works…
Containing rectangle
Getting ready
How to do it…
How it works…
Simple and complex shapes
Getting ready
How to do it…
How it works…
Quad tree
Getting ready
How to do it…
How it works…
Broad phase collisions
Getting ready
How to do it…
How it works…
7. 3D Primitive Shapes
Introduction
Point
Getting ready
How to do it…
How it works…
Line segment
Getting ready
How to do it…
How it works…
Ray
Ge...

Indice dei contenuti