Subversion Repositories gelsvn

Rev

Rev 2 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2 Rev 5
Line 23... Line 23...
23
			ArithVecFloat<T,V,4>(a,b,c,d) {}
23
			ArithVecFloat<T,V,4>(a,b,c,d) {}
24
 
24
 
25
		/// Divide all coordinates by the fourth coordinate
25
		/// Divide all coordinates by the fourth coordinate
26
		void de_homogenize()
26
		void de_homogenize()
27
		{
27
		{
28
			float k = 1.0f/(*this)[3];
28
			float k = 1.0/(*this)[3];
29
			(*this)[0] = (*this)[0]*k;
29
			(*this)[0] = (*this)[0]*k;
30
			(*this)[1] = (*this)[1]*k;
30
			(*this)[1] = (*this)[1]*k;
31
			(*this)[2] = (*this)[2]*k;
31
			(*this)[2] = (*this)[2]*k;
32
			(*this)[3] = 1.0;
32
			(*this)[3] = 1.0;
33
		}
33
		}