Box2D Joint Toy
Ian Parberry's "Introduction to Game Physics"
Enumerations | Functions | Variables
GameDefines.h File Reference

Game specific defines. More...

#include "Defines.h"
#include "Box2D\Box2D.h"

Enumerations

enum class  eSprite : UINT {
  WindmillBg , WindmillBase , WindmillBlade , GearBg ,
  Gear0 , Gear1 , Gear2 , Gear3 ,
  Gear4 , Gear5 , NautilusBg , NautilusGear ,
  RackAndPinionBg , Pinion , Rack , CarBg ,
  CarBody , CarWheel , Platform , UpRamp ,
  DownRamp , NewtonBg , Ball , Cradle ,
  Line , Isaac , Eyeballs , ElephantBg ,
  Crate , Safe , Elephant , Pulley ,
  Size
}
 Sprite enumerated type. More...
 
enum class  eLevel : UINT {
  Windmill , Gears , NautilusGears , RackAndPinion ,
  Car , Newton , Pulley , Size
}
 Level enumerated type. More...
 

Functions

float PW2RW (float x)
 Physics World to Render World units for a float.
 
Vector2 PW2RW (const b2Vec2 &v)
 Physics World to Render World units for a vector.
 
float RW2PW (float x)
 Render World to Physics World units for a float.
 
float RW2PW (int x)
 Render World to Physics World units for an int.
 
b2Vec2 RW2PW (int x, int y)
 Render World to Physics World units for a vector provided as a pair of ints.
 
b2Vec2 RW2PW (const Vector2 &v)
 Render World to Physics World units for a vector.
 

Variables

const float fPRV = 10.0f
 Physics World to Render World rescale value.
 

Detailed Description

Game specific defines.

Enumeration Type Documentation

◆ eLevel

enum eLevel : UINT
strong

Level enumerated type.

Enumerated type for the level. Size must be last.

◆ eSprite

enum eSprite : UINT
strong

Sprite enumerated type.

An enumerated type for the sprites, which will be cast to an unsigned integer and used for the index of the corresponding texture in graphics memory. Size must be last.