Newer
Older
cg / include / vec.h
@glproj03 glproj03 on 29 Dec 2005 518 bytes Changes:
#ifndef _VEC_H
#define _VEC_H

#include <string>
class Vec {
	public:
		float c[3];

		Vec();
		Vec(float vx, float vy, float vz);
		Vec(Vec* v);
		float x();
		float y();
		float z();
		float* getCoords();
		Vec operator+(Vec* v);
		Vec operator+(Vec c);
		void add(Vec& a);
		Vec operator-(Vec& v);
		Vec operator*(float s);
		Vec operator*(Vec& s);
		Vec operator/(float s);
		Vec cross(Vec* v);
		Vec normalize();
		float length();
		void print();
		Vec* clone();
		void vardump(std::string whitespace);
};
#endif