// Copyright (C) 2010, Guy Barrand. All rights reserved. // See the file tools.license for terms. #ifndef tools_curve #define tools_curve #include "scast" #include "S_STRING" #include "lina/vec3f" #include "lina/mat4f" namespace tools { class curve { public: TOOLS_SCLASS(tools::curve) virtual void* cast(const std::string& a_class) const { if(void* p = cmp_cast(this,a_class)) {return p;} return 0; } public: virtual void copy(curve*&) const = 0; public: virtual bool pos_tan_nor(float a_s, vec3f& a_pos, vec3f& a_tan, vec3f& a_nor) const = 0; public: curve(){ m_model.set_identity(); } virtual ~curve(){ } public: curve(const curve& a_from):m_model(a_from.m_model){ } curve& operator=(const curve& a_from){ m_model = a_from.m_model; return *this; } public: void set_model_matrix(const mat4f& a_m) {m_model = a_m;} protected: mat4f m_model; }; } #endif