Subversion Repositories gelsvn

Rev

Rev 595 | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 595 Rev 630
1
/* ----------------------------------------------------------------------- *
1
/* ----------------------------------------------------------------------- *
2
 * This file is part of GEL, http://www.imm.dtu.dk/GEL
2
 * This file is part of GEL, http://www.imm.dtu.dk/GEL
3
 * Copyright (C) the authors and DTU Informatics
3
 * Copyright (C) the authors and DTU Informatics
4
 * For license and list of authors, see ../../doc/intro.pdf
4
 * For license and list of authors, see ../../doc/intro.pdf
5
 * ----------------------------------------------------------------------- */
5
 * ----------------------------------------------------------------------- */
6
 
6
 
7
/** @file Vec2d.h
7
/** @file Vec2d.h
8
 * @brief 2D double vector class.
8
 * @brief 2D double vector class.
9
 */
9
 */
10
 
10
 
11
#ifndef __CGLA_VEC2D_H__
11
#ifndef __CGLA_VEC2D_H__
12
#define __CGLA_VEC2D_H__
12
#define __CGLA_VEC2D_H__
13
 
13
 
14
#include "ArithVec.h"
14
#include "ArithVec.h"
15
#include "Vec2i.h"
15
#include "Vec2i.h"
16
#include "Vec2f.h"
16
#include "Vec2f.h"
17
 
17
 
18
 
18
 
19
namespace CGLA {
19
namespace CGLA {
20
 
20
 
21
	/** \brief 2D double floating point vector */
21
	/** \brief 2D double floating point vector */
22
 
22
 
23
	class Vec2d: public ArithVec2Float<double,Vec2d>
23
	class Vec2d: public ArithVec2Float<double,Vec2d>
24
	{
24
	{
25
	public:
25
	public:
26
 
26
 
27
		Vec2d() {}
27
		Vec2d() {}
28
 
28
 
29
		Vec2d(double _a,double _b): 
29
		Vec2d(double _a,double _b): 
30
			ArithVec2Float<double,Vec2d>(_a,_b) {}
30
			ArithVec2Float<double,Vec2d>(_a,_b) {}
31
 
31
 
32
		explicit Vec2d(const Vec2i& v): 
32
		explicit Vec2d(const Vec2i& v): 
33
			ArithVec2Float<double,Vec2d>(v[0],v[1]) {}
33
			ArithVec2Float<double,Vec2d>(v[0],v[1]) {}
34
 
34
 
35
		explicit Vec2d(const Vec2f& v): 
35
		explicit Vec2d(const Vec2f& v): 
36
			ArithVec2Float<double,Vec2d>(v[0],v[1]) {}
36
			ArithVec2Float<double,Vec2d>(v[0],v[1]) {}
37
 
37
 
38
		explicit Vec2d(double a): 
38
		explicit Vec2d(double a): 
39
			ArithVec2Float<double,Vec2d>(a,a) {}
39
			ArithVec2Float<double,Vec2d>(a,a) {}
40
  
40
  
41
	};
41
	};
42
 
42
 
43
}
43
}
44
#endif
44
#endif
45
 
45