#ifndef DISTORTBALL
#define DISTORTBALL

// yes, very ugly i need to fix this
#include "..\..\..\demosystem\sm_commonfx\source\fxmesh.h"  

class SM_DistortBall : public IRenderable
{
	FXMesh 				m_mesh;
	float 				m_s1[6];
	float 				m_s2[6];
	int 				m_shader;
	IKFAnimable*		m_pAnimable;
	int 				m_thetaSteps;
	int 				m_phiSteps;
	float				m_radius;

public:

	SM_DistortBall()
		: m_shader(-1)
		, m_thetaSteps(40)
		, m_phiSteps(40)
		, m_pAnimable(0)
		, m_radius(30)
	{}

    int 	Init				(int iShader, IKFAnimable* pAnimable);
    int     Shutdown			() {}
    int     Reset				() {}
	virtual void Render(RenderContext* pRenderContext, int iOutcode, float time);


	Vector3D			m_v3dPosition;
	Quaternion			m_qRotation;
private:
	void Update(float time);
};

#endif 

