#ifndef _OF_TYPES_H 
#include "ofTypes.h"
#endif 

#ifndef ADDITIONALFUNCTIONS_H
#define	ADDITIONALFUNCTIONS_H

#define OF_ADDON_USING_OFXVECTORMATH

#include "ofAddons.h"
#include "ofMain.h"

float ofxVec2fDistance(ofxVec2f& first, ofxVec2f& second);
void scale2dVector( ofxVec2f& vec, const float scaleFactor);

bool ParticleSegmentCollide(ofxVec2f& P, const ofxVec2f& A, const ofxVec2f& B, double r);

bool ParticleSegmentCollide(const ofxVec2f& Pold, ofxVec2f& Pnew, 
                            const ofxVec2f& A, const ofxVec2f& B);
							
bool ParticleSegmentCollide(const ofxVec2f& Pold, ofxVec2f& Pnew, 
                            const ofxVec2f& Aold, ofxVec2f& Anew, 
                            const ofxVec2f& Bold, ofxVec2f& Bnew);

#endif
