did-you-know? rent-now

Amazon no longer offers textbook rentals. We do!

did-you-know? rent-now

Amazon no longer offers textbook rentals. We do!

We're the #1 textbook rental company. Let us show you why.

9781598220322

Introduction to Game Programming in C++

by
  • ISBN13:

    9781598220322

  • ISBN10:

    1598220322

  • Format: Paperback
  • Copyright: 2007-05-29
  • Publisher: Jones & Bartlett Learning
  • Purchase Benefits
  • Free Shipping Icon Free Shipping On Orders Over $35!
    Your order must be $35 or more to qualify for free economy shipping. Bulk sales, PO's, Marketplace items, eBooks and apparel do not qualify for this offer.
  • eCampus.com Logo Get Rewarded for Ordering Your Textbooks! Enroll Now
List Price: $44.95 Save up to $0.22
  • Buy New
    $44.73
    Add to Cart Free Shipping Icon Free Shipping

    PRINT ON DEMAND: 2-4 WEEKS. THIS ITEM CANNOT BE CANCELLED OR RETURNED.

Supplemental Materials

What is included with this book?

Summary

Introduction to Game Programming with C++ is an exciting book for readers with no previous experience in game development. Starting from the basics of C++ and ending with the intracies of real-time 3D graphics, this book explores the interesting world of game making. It explains how to program, explores the meaning of object-oriented programming, and examines game algorithms, 2D and 3D games, sound and music, and how to create game installers. Overall, this book will introduce you to the world of game development and get you started on the right path to making games that sell.

Table of Contents

Acknowledgmentsp. xvii
Introductionp. xix
Mathematics - The Language of Numbersp. 1
Number Systemsp. 2
Decimal System (Base 10)p. 3
Arithmeticp. 4
Additionp. 4
Subtractionp. 4
Multiplicationp. 4
Divisionp. 5
Number Partsp. 5
Dividing into Parts and Several Partsp. 6
Special Numbersp. 7
Ratiop. 8
Ratio and Proportionp. 9
Corresponding Proportion or Alternate Proportionp. 9
Ratios and Common Multipliersp. 10
Ratios and Common Divisorsp. 10
Inverse Proportionp. 10
Solving Problems with Ratiosp. 11
Discrete and Continuous Setsp. 12
Fractions - Incomplete Measurep. 13
Unit and Reciprocal Fractionsp. 15
Fractions and Whole Numbersp. 16
Complementsp. 16
Equivalentsp. 17
Comparing Fractionsp. 18
Adding and Subtracting Fractionsp. 20
Multiplying and Dividing Fractionsp. 20
Decimal Notation - Damn Those Dotsp. 22
Converting Vulgar Fractions to Decimalsp. 23
Percentagep. 24
As Ratiop. 24
Percent as Fractionsp. 25
Percent Ofp. 25
Conclusionp. 26
Algebrap. 27
What Is Algebra?p. 28
Rules of Algebrap. 28
Parenthesesp. 28
Multiplication and Factorsp. 29
Distributive Multiplicationp. 29
Division and Multiplicationp. 30
Multiplication Notationp. 30
Indices or Exponentsp. 30
Directed Numbersp. 32
Addition with Negativesp. 32
Subtraction with Negativesp. 33
Multiplication with Negativesp. 33
Division with Negativesp. 33
Algebraic Expressionsp. 34
Coefficientsp. 34
Like Termsp. 34
Collect Like Termsp. 35
Linear Equationsp. 35
Rearranging Equationsp. 36
Balancing Equationsp. 37
Balancing Methodsp. 38
Simplificationp. 39
Inequalitiesp. 40
Expressing Inequalitiesp. 40
Compound Inequalitiesp. 41
Chained/Continued Inequalitiesp. 41
Solving Inequalitiesp. 41
Simultaneous Linear Equationsp. 43
Solving by Substitutionp. 43
Solving by Eliminationp. 44
Conclusionp. 46
The Pictures of Mathematicsp. 47
1D Coordinatesp. 48
2D Coordinatesp. 48
3D Coordinatesp. 49
Primitives and Properties of Spacep. 50
Verticesp. 50
Lines and Line Segmentsp. 50
Rayp. 51
Anglep. 51
Perpendicularp. 51
Angle Typesp. 52
Parallelp. 52
Polygons and Shapesp. 53
Trianglesp. 54
Squaresp. 55
Area and Perimeterp. 55
Square Numbers and Square Rootsp. 56
Right Triangles and the Pythagorean Theoremp. 57
Right Triangles and Anglesp. 58
Sides, Angles, and Ratiosp. 59
Angle and Side Correspondencep. 60
Side Lengthsp. 61
Co Functionsp. 61
Area of a Trianglep. 62
The Circlep. 63
Chordsp. 64
Central and Inscribed Anglesp. 64
Length of a Chordp. 65
Pi ([pi])p. 65
Radiansp. 66
Equations of Linesp. 67
X and Y Interceptp. 68
Gradients (Slopes)p. 68
Slope Intercept Equationp. 69
Vectorsp. 69
Vector Magnitudep. 70
Unit Vectorp. 70
Conclusionp. 70
C++ and Programmingp. 71
Programmingp. 72
C++ as a Languagep. 73
C++ IDEp. 73
Microsoft Visual Studio.NETp. 74
Code::Blocksp. 75
Dev C++p. 75
Using an IDEp. 77
Projectsp. 77
Starting a New Visual C++ Projectp. 78
Starting a New Code::Blocks Projectp. 79
Starting a New Dev C++ Projectp. 81
Project Typesp. 81
Codingp. 82
Compilingp. 83
Compiling on Visual Studiop. 83
Compiling on Code::Blocksp. 84
Compiling on Dev C++p. 85
Executingp. 85
Executing on Visual Studiop. 86
Executing on Code::Blocksp. 86
Executing on Dev C++p. 87
Debuggingp. 87
Debugging on Visual Studio .NETp. 88
Debugging on Code::Blocksp. 88
Debugging on Dev C++p. 89
Opening and Saving Projectsp. 90
Conclusionp. 90
The Basics of C++p. 91
The First Programp. 92
Commentsp. 93
Preprocessor Directivesp. 94
Functionsp. 94
Printing Textp. 95
Conclusionp. 95
Variables, Constants, and Arraysp. 97
Constantsp. 98
Variablesp. 98
Data and Informationp. 98
Data in Memoryp. 99
Constants and Variables in Memoryp. 100
Data Typesp. 101
Integersp. 101
Floatsp. 101
Booleanp. 101
Charp. 102
Constants in C++p. 102
Variables in C++p. 103
Arithmetic Operatorsp. 104
Outputting Resultsp. 105
Data and Arraysp. 106
Array Definitionp. 106
Array Declarationp. 107
Array Usagep. 107
Two-dimensional Arraysp. 108
Shorthand Operationsp. 108
Conclusionp. 109
Controlling Program Flowp. 111
Handling Inputp. 112
Making Decisionsp. 112
Conditional Operatorsp. 113
Conditional Statementsp. 114
If Statementp. 114
Using Ifp. 115
If Else Statementp. 115
Using If Elsep. 116
Logical Operatorsp. 117
If Else Statements and Logical Operatorsp. 117
Multiple Choicep. 119
Switch-Case Statementp. 120
Loops and Repetitionp. 121
For Loopp. 121
Using For Loopsp. 122
While Loopp. 122
Using the While Loopp. 123
Do-While Loopp. 124
Using the Do-While Loopp. 125
Conclusionp. 126
Pointersp. 127
Memory Addressesp. 128
Pointersp. 128
Declaring Pointersp. 129
Address Ofp. 129
Pointer Dereferencingp. 130
Pointer Arithmeticp. 130
Pointers and Arraysp. 131
Using Pointers and Arraysp. 131
Conclusionp. 132
Functionsp. 133
Functions in Mathematicsp. 134
Function Notationp. 134
Functions in C++p. 135
Coding Functionsp. 135
Calling Functionsp. 137
Functions as Argumentsp. 138
Functions without Inputs and Outputsp. 139
Functions and Variablesp. 140
Variable Scopep. 140
Global, Local, and Block Variablesp. 141
Functions and Arguments as Pointersp. 144
Recursive Functionsp. 145
Functions and Default Argumentsp. 146
Functions and Overloadingp. 147
Conclusionp. 148
Data Structures and Classesp. 149
Organizing Datap. 150
Data Structuresp. 150
Declaring Data Structuresp. 151
Data Structures as Blueprintsp. 151
Data Structures and Membersp. 152
Data Structures and Sizep. 153
Further Data Representationp. 153
Classes and Object Orientationp. 154
Classes as Objectsp. 154
Classes and Objectsp. 156
Access Specifiersp. 156
Classes and Access Specifiersp. 157
Private and Publicp. 158
Constructors and Destructorsp. 159
Overloading Operatorsp. 159
Overloading Operators in Practicep. 160
Inheritancep. 162
Class Inheritancep. 162
Multiple Inheritancep. 163
Pointers to Classesp. 164
This Pointerp. 164
Overriding Functionsp. 165
Polymorphismp. 166
Polymorphism and Virtual Functionsp. 166
Conclusionp. 168
Memory Allocation and Stringsp. 169
Memory Allocationp. 170
New Keywordp. 170
Delete Keywordp. 171
Dynamic Arraysp. 172
Stringsp. 172
Strings with std::stringp. 174
Creating std::string Objectsp. 174
Using Strings and the + Operatorp. 174
String Methodsp. 175
String Lengthp. 175
String Conversionp. 176
Inserting Charactersp. 176
Substringsp. 177
Erasep. 177
Replacep. 178
String Processingp. 178
Cycling through a Stringp. 178
Cycling Backward through a Stringp. 179
Reversing a Stringp. 180
Conclusionp. 181
File I/O and Command-Line Argumentsp. 183
Filesp. 184
Reading and Writing Filesp. 185
Writing Data to Files with std::ofstreamp. 185
Creating Filesp. 186
Opening Filesp. 186
Writing Data to Filesp. 186
Reading Data from Files with std::ifstreamp. 187
Opening Filesp. 187
Reading Datap. 187
Seeking Datap. 188
Command-Line Argumentsp. 190
Conclusionp. 191
Algorithmsp. 193
Language and Contentp. 193
Common Algorithmsp. 195
Bubble Sortp. 195
Linked Listsp. 197
Stacks - Pop and Pushp. 204
Binary Heapsp. 205
A Breakdownp. 206
Child and Parentp. 206
Pushing Itemsp. 207
Popping Itemsp. 210
Applicationp. 212
Conclusionp. 216
Game Programmingp. 217
Game Developmentp. 218
Software Abstractionp. 219
Graphicsp. 219
DirectXp. 221
OpenGLp. 222
Other Librariesp. 222
SDLp. 223
ClanLibp. 223
OGRE 3D (Object-Oriented Graphics Rendering Engine)p. 223
A Sound and Musicp. 224
OpenALp. 224
FMODp. 225
BASSp. 225
More Middlewarep. 225
ODE (Open Dynamics Engine)p. 226
Nullsoft Scriptable Install Systemp. 226
Conclusionp. 227
2D Games and ClanLibp. 229
ClanLibp. 230
Downloading ClanLibp. 230
Building ClanLibp. 231
First ClanLib Applicationp. 232
Include Filesp. 232
Creating an Application Classp. 233
Overriding the Main Methodp. 233
Initializing Game Objectsp. 234
Initializing Game Windowp. 234
Games and the Message Loopp. 236
Graphics Renderingp. 238
Conclusionp. 239
ClanLib - Core Classesp. 241
2D Games and Imagesp. 242
Surfacesp. 242
Drawing Surfacesp. 244
Drawing a Surface in a Rectanglep. 245
Drawing a Rectangular Selection from a Surface in a Rectanglep. 246
Drawing a Surface Repeatedlyp. 246
Transformationp. 247
Scalep. 247
Rotationp. 248
Colorp. 248
Alphap. 249
XMLp. 249
XML Definedp. 249
Nodes and Elementsp. 251
Creating and Saving XML Using ClanLibp. 251
Create an XML Documentp. 251
Create a Root Elementp. 251
Create Other Elements and Set Attributesp. 252
Build the XML Hierarchyp. 252
Save the XML Hierarchy to a Filep. 252
Load XML Using ClanLibp. 252
Load an XML File into a Hierarchyp. 252
Get the Root Elementp. 253
Resourcesp. 253
Resource XML Filesp. 254
Creating Surfaces from Resourcesp. 254
Spritesp. 255
Defining Sprites in XMLp. 256
Creating Sprite Objectsp. 257
Drawing Sprite Objectsp. 257
Inputp. 258
Reading Input from the Keyboardp. 258
Reading Input from the Mousep. 258
Determine Cursor Positionp. 258
Determine Button Statusp. 259
Conclusionp. 259
ClanLib - Scene Managementp. 261
Scenesp. 262
Scenes and Designp. 262
Scene Implementationp. 264
Scene Manager - Core Propertiesp. 264
Scene Manager - Scene Objectsp. 265
Scene Manager - Object Relationshipsp. 266
Layersp. 268
Implementing Layersp. 269
Layer Scene Objectsp. 270
Adding Scene Objectsp. 272
Cycling through Objectsp. 272
Deleting Scene Objectsp. 272
Painting a Layerp. 273
Painting to a Surfacep. 273
CL_SceneLayer - Paintingp. 274
CL_SceneManager - Structurep. 275
CL_SceneManager - XMLp. 275
CL_SceneManager - Load from XMLp. 277
Overview - Using Scene Managerp. 279
Creating the Scene Manager Manuallyp. 280
Creating the Scene Manager from XMLp. 281
Conclusionp. 282
3D Games and OGRE 3Dp. 283
3D Gamesp. 284
OGRE 3Dp. 285
Downloading OGRE 3Dp. 286
Installing OGRE 3Dp. 287
Compiling the OGRE 3D Samplesp. 288
Running the OGRE 3D Samplesp. 289
Creating an OGRE Application Using a Wizardp. 289
Creating an OGRE Application Manuallyp. 293
Creating a Main Functionp. 293
Deriving from ExampleApplicationp. 293
Running OGRE Applicationsp. 294
Creating a Scenep. 297
OGRE Logp. 299
OGRE Documentationp. 299
Conclusionp. 300
Exploring OGRE 3Dp. 301
3D Scenesp. 302
Entitiesp. 302
Scene Nodesp. 303
Creating 3D Scenesp. 303
Create Entityp. 304
Create SceneNodep. 304
SceneNode Properties and Methodsp. 305
Lightsp. 306
Ambient Lightp. 306
Point Lightp. 307
Spotlightp. 307
Directional Lightp. 307
Camerasp. 307
Materials and Scriptsp. 309
Billboardsp. 311
Creating Billboardsp. 312
Particle Systemsp. 313
Scripted Particle Systemsp. 314
Loading Particle Systemsp. 316
Frame Listenersp. 317
Registering Frame Listenersp. 318
Inputp. 320
Keyboard Inputp. 321
Mouse Inputp. 321
Conclusionp. 321
Other Gaming Libraries - Install and Soundp. 323
Sound and Musicp. 324
FMODp. 324
Installing and Configuringp. 327
Playing Sound and Musicp. 327
BASSp. 328
Installing and Configuringp. 329
Playing Sound and Musicp. 329
NSIS -Windows Installerp. 330
Scripted Installsp. 331
Writing a Scriptp. 332
Compiling a Scriptp. 335
Running an Installerp. 335
Scriptingp. 336
Open-Source Softwarep. 336
Open Media Formatsp. 337
Conclusionp. 337
Afterwordp. 339
Trigonometric Tablep. 341
Degrees to Radiansp. 345
ClanLib Key Codesp. 347
OGRE Key Codesp. 351
C++ Keywordsp. 357
Recommended Readingp. 359
Indexp. 363
Table of Contents provided by Ingram. All Rights Reserved.

Supplemental Materials

What is included with this book?

The New copy of this book will include any supplemental materials advertised. Please check the title of the book to determine if it should include any access cards, study guides, lab manuals, CDs, etc.

The Used, Rental and eBook copies of this book are not guaranteed to include any supplemental materials. Typically, only the book itself is included. This is true even if the title states it includes any access cards, study guides, lab manuals, CDs, etc.

Rewards Program