Ball and Spring Toy
Chapter 4 of Ian Parberry's "Introduction to Game Physics with Box2D"
 All Classes Files Functions Variables Enumerations Pages
Functions | Variables
Springs.cpp File Reference

Code for the spring class CSpring. More...

#include "Springs.h"

Functions

float clip (float a, float b, float c)
 

Variables

int g_nScreenWidth
 
int g_nScreenHeight
 

Detailed Description

Code for the spring class CSpring.

Function Documentation

float clip ( float  a,
float  b,
float  c 
)
inline

Clip function.

Parameters
aSmallest allowable value.
bValue to be clipped.
cLargest allowable value.
Returns
The value b clipped between a and c.