/** SGX

The   sss    gggg x   x   
     s      g      x x    Engine
      sss   g  gg   x
         s  g   g  x x          Copyright 1995-2009.
     ssss    gggg x   x         Steven Goodwin. All Rights Reserved.
    
This version has been released under the GNU Public License v2.0.

Please see the license files for details.

File: sgx/include/sgx/input/rumble_profile.hpp

*/

#ifndef SGX_INPUT_RUMBLE_PROFILE_HPP
#define SGX_INPUT_RUMBLE_PROFILE_HPP	1

class CSGXRumbleProfile {
public:
	virtual tREAL32 getRumbleOutput(const tREAL32 t) const  = 0;
	virtual tREAL32 getInnerCone() const;
	virtual tREAL32 getOuterCone() const;
};

class CSGXRumbleProfileConstant : public CSGXRumbleProfile  {
public:
	virtual tREAL32 getRumbleOutput(const tREAL32 t) const;
};

class CSGXRumbleProfilePulse : public CSGXRumbleProfileConstant  {
public:
	CSGXRumbleProfilePulse(const tREAL32 t);
	virtual tREAL32 getRumbleOutput(const tREAL32 t) const;
protected:
	tREAL32	m_fPulseDuration;
};

class CSGXRumbleProfileSpike : public CSGXRumbleProfileConstant  {
public:
	CSGXRumbleProfileSpike(const tREAL32 tailDuration);
	virtual tREAL32 getRumbleOutput(const tREAL32 t) const;
protected:
	tREAL32	m_fTailDuration;
};

class CSGXRumbleProfileSawtooth : public CSGXRumbleProfileConstant  {
public:
	CSGXRumbleProfileSawtooth(const tREAL32 period);
	virtual tREAL32 getRumbleOutput(const tREAL32 t) const;
protected:
	tREAL32	m_fPeriod;
};

class CSGXRumbleProfileSquare : public CSGXRumbleProfileConstant  {
public:
	CSGXRumbleProfileSquare(const tREAL32 mark, const tREAL32 space);
	virtual tREAL32 getRumbleOutput(const tREAL32 t) const;
protected:
	tREAL32	m_fMarkDuration;
	tREAL32	m_fSpaceDuration;
	tREAL32	m_fTotalDuration;
};

#endif

