just a test

Dependencies:   mbed

Fork of scoreLight_Advanced by Alvaro Cassinelli

Committer:
mbedalvaro
Date:
Tue Dec 02 04:28:42 2014 +0000
Revision:
48:7633d8e7b0d3
Parent:
30:d8af03f01cd4
this is the working version of the skin games sowtware (aka, scorelight but with pre-determined "games")

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mbedalvaro 30:d8af03f01cd4 1 #ifndef SPRING_H
mbedalvaro 30:d8af03f01cd4 2 #define SPRING_H
mbedalvaro 30:d8af03f01cd4 3
mbedalvaro 30:d8af03f01cd4 4 // Springs between particles of the active contour:
mbedalvaro 30:d8af03f01cd4 5
mbedalvaro 30:d8af03f01cd4 6 #include "classPointMass.h"
mbedalvaro 30:d8af03f01cd4 7
mbedalvaro 30:d8af03f01cd4 8 class spring {
mbedalvaro 30:d8af03f01cd4 9
mbedalvaro 30:d8af03f01cd4 10 public:
mbedalvaro 30:d8af03f01cd4 11
mbedalvaro 30:d8af03f01cd4 12 spring();
mbedalvaro 30:d8af03f01cd4 13
mbedalvaro 30:d8af03f01cd4 14 pointMass * massA;
mbedalvaro 30:d8af03f01cd4 15 pointMass * massB;
mbedalvaro 30:d8af03f01cd4 16
mbedalvaro 30:d8af03f01cd4 17 float distance;
mbedalvaro 30:d8af03f01cd4 18 float springiness; // this is the k, springiness constant
mbedalvaro 30:d8af03f01cd4 19
mbedalvaro 30:d8af03f01cd4 20 void update(); // add forces to both point masses
mbedalvaro 30:d8af03f01cd4 21 void assymetricUpdate(); // only second mass suffers a force
mbedalvaro 30:d8af03f01cd4 22
mbedalvaro 30:d8af03f01cd4 23
mbedalvaro 30:d8af03f01cd4 24 };
mbedalvaro 30:d8af03f01cd4 25
mbedalvaro 30:d8af03f01cd4 26
mbedalvaro 30:d8af03f01cd4 27 #endif