⚲
Project
General
Profile
Sign in
Register
Home
Projects
Help
Search
:
SO3Engine
All Projects
Scol
»
SO3Engine
Overview
Activity
Roadmap
Issues
Spent time
Gantt
Calendar
News
Documents
Wiki
Files
Repository
API Documentation
SO3Engine
src
SO3Utils
SO3Point.cpp
Go to the documentation of this file.
1
/*
2
-----------------------------------------------------------------------------
3
This source file is part of OpenSpace3D
4
For the latest info, see http://www.openspace3d.com
5
6
Copyright (c) 2012 I-maginer
7
8
This program is free software; you can redistribute it and/or modify it under
9
the terms of the GNU Lesser General Public License as published by the Free Software
10
Foundation; either version 2 of the License, or (at your option) any later
11
version.
12
13
This program is distributed in the hope that it will be useful, but WITHOUT
14
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
15
FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
16
17
You should have received a copy of the GNU Lesser General Public License along with
18
this program; if not, write to the Free Software Foundation, Inc., 59 Temple
19
Place - Suite 330, Boston, MA 02111-1307, USA, or go to
20
http://www.gnu.org/copyleft/lesser.txt
21
22
-----------------------------------------------------------------------------
23
*/
24
25
#include "
SO3Utils/SO3Point.h
"
26
27
namespace
SO3
28
{
29
30
// int implementation
31
template
<>
const
SPoint<int>
SPoint<int>::ZERO
(0, 0);
32
template
<>
const
SPoint<int>
SPoint<int>::UNIT_X
(1, 0);
33
template
<>
const
SPoint<int>
SPoint<int>::UNIT_Y
(0, 1);
34
template
<>
const
SPoint<int>
SPoint<int>::NEGATIVE_UNIT_X
(-1, 0);
35
template
<>
const
SPoint<int>
SPoint<int>::NEGATIVE_UNIT_Y
(0, -1);
36
template
<>
const
SPoint<int>
SPoint<int>::UNIT_SCALE
(1, 1);
37
38
// short implementation
39
template
<>
const
SPoint<short>
SPoint<short>::ZERO
(0, 0);
40
template
<>
const
SPoint<short>
SPoint<short>::UNIT_X
(1, 0);
41
template
<>
const
SPoint<short>
SPoint<short>::UNIT_Y
(0, 1);
42
template
<>
const
SPoint<short>
SPoint<short>::NEGATIVE_UNIT_X
(-1, 0);
43
template
<>
const
SPoint<short>
SPoint<short>::NEGATIVE_UNIT_Y
(0, -1);
44
template
<>
const
SPoint<short>
SPoint<short>::UNIT_SCALE
(1, 1);
45
46
// long implementation
47
template
<>
const
SPoint<long>
SPoint<long>::ZERO
(0, 0);
48
template
<>
const
SPoint<long>
SPoint<long>::UNIT_X
(1, 0);
49
template
<>
const
SPoint<long>
SPoint<long>::UNIT_Y
(0, 1);
50
template
<>
const
SPoint<long>
SPoint<long>::NEGATIVE_UNIT_X
(-1, 0);
51
template
<>
const
SPoint<long>
SPoint<long>::NEGATIVE_UNIT_Y
(0, -1);
52
template
<>
const
SPoint<long>
SPoint<long>::UNIT_SCALE
(1, 1);
53
54
// unsigned int implementation
55
template
<>
const
SPoint<unsigned int>
SPoint<unsigned int>::ZERO
(0, 0);
56
template
<>
const
SPoint<unsigned int>
SPoint<unsigned int>::UNIT_X
(1, 0);
57
template
<>
const
SPoint<unsigned int>
SPoint<unsigned int>::UNIT_Y
(0, 1);
58
template
<>
const
SPoint<unsigned int>
SPoint<unsigned int>::UNIT_SCALE
(1, 1);
59
60
// unsigned short implementation
61
template
<>
const
SPoint<unsigned short>
SPoint<unsigned short>::ZERO
(0, 0);
62
template
<>
const
SPoint<unsigned short>
SPoint<unsigned short>::UNIT_X
(1, 0);
63
template
<>
const
SPoint<unsigned short>
SPoint<unsigned short>::UNIT_Y
(0, 1);
64
template
<>
const
SPoint<unsigned short>
SPoint<unsigned short>::UNIT_SCALE
(1, 1);
65
66
// unsigned long implementation
67
template
<>
const
SPoint<unsigned long>
SPoint<unsigned long>::ZERO
(0, 0);
68
template
<>
const
SPoint<unsigned long>
SPoint<unsigned long>::UNIT_X
(1, 0);
69
template
<>
const
SPoint<unsigned long>
SPoint<unsigned long>::UNIT_Y
(0, 1);
70
template
<>
const
SPoint<unsigned long>
SPoint<unsigned long>::UNIT_SCALE
(1, 1);
71
72
// float implementation
73
template
<>
const
SPoint<float>
SPoint<float>::ZERO
(0.0f, 0.0f);
74
template
<>
const
SPoint<float>
SPoint<float>::UNIT_X
(1.0f, 0.0f);
75
template
<>
const
SPoint<float>
SPoint<float>::UNIT_Y
(0.0f, 1.0f);
76
template
<>
const
SPoint<float>
SPoint<float>::NEGATIVE_UNIT_X
(-1.0f, 0.0f);
77
template
<>
const
SPoint<float>
SPoint<float>::NEGATIVE_UNIT_Y
(0.0f, -1.0f);
78
template
<>
const
SPoint<float>
SPoint<float>::UNIT_SCALE
(1.0f, 1.0f);
79
80
// double implementation
81
template
<>
const
SPoint<double>
SPoint<double>::ZERO
(0.0, 0.0);
82
template
<>
const
SPoint<double>
SPoint<double>::UNIT_X
(1.0, 0.0);
83
template
<>
const
SPoint<double>
SPoint<double>::UNIT_Y
(0.0, 1.0);
84
template
<>
const
SPoint<double>
SPoint<double>::NEGATIVE_UNIT_X
(-1.0, 0.0);
85
template
<>
const
SPoint<double>
SPoint<double>::NEGATIVE_UNIT_Y
(0.0, -1.0);
86
template
<>
const
SPoint<double>
SPoint<double>::UNIT_SCALE
(1.0, 1.0);
87
88
}
SO3Point.h
SO3::SPoint
Definition
SO3Point.h:37
SO3::SPoint::ZERO
static const SPoint ZERO
Definition
SO3Point.h:43
SO3::SPoint::NEGATIVE_UNIT_X
static const SPoint NEGATIVE_UNIT_X
Definition
SO3Point.h:46
SO3::SPoint::UNIT_SCALE
static const SPoint UNIT_SCALE
Definition
SO3Point.h:48
SO3::SPoint::UNIT_X
static const SPoint UNIT_X
Definition
SO3Point.h:44
SO3::SPoint::UNIT_Y
static const SPoint UNIT_Y
Definition
SO3Point.h:45
SO3::SPoint::NEGATIVE_UNIT_Y
static const SPoint NEGATIVE_UNIT_Y
Definition
SO3Point.h:47
SO3
Definition
SO3DataScol.h:38
Generated by
1.9.8
Loading...