forked from AdaDoom3/AdaDoom3
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathneo-library-angles.ads
More file actions
135 lines (135 loc) · 3.29 KB
/
neo-library-angles.ads
File metadata and controls
135 lines (135 loc) · 3.29 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
--
--
--
--
--
--
--
--
--
--
--
--
--
--
--
--
with
Neo.Library.Vectors,
Neo.Library.Matrices,
Neo.Library.Rotations,
Neo.Library.Quaternion,
Neo.Foundation.Text_IO,
Neo.Foundation.Data_Types,
Neo.Foundation.Package_Testing;
use
Neo.Library.Vectors,
Neo.Library.Matrices,
Neo.Library.Rotations,
Neo.Library.Quaternion,
Neo.Foundation.Text_IO,
Neo.Foundation.Data_Types,
Neo.Foundation.Package_Testing;
package Neo.Library.Angles
is
-------------
-- Records --
-------------
type Record_Angle
is record
Pitch : Float_4_Real := 0.0;
Yaw : Float_4_Real := 0.0;
Roll : Float_4_Real := 0.0;
end record;
-----------------
-- Subprograms --
-----------------
function To_Record_Vector_Polar(
Item : in Record_Vector_3)
return Record_Vector_Polar;
function To_Record_Vector_2(
Item : in Record_Vector_)
return Record_Vector_2;
function To_Record_Vector_3(
Item : in Record_Vector_)
return Record_Vector_3;
procedure Test;
procedure Put(
Item : in Record_Angle);
function "-"(
Left : in Record_Angle;
Right : in Record_Angle)
return Boolean;
function "-"(
Item : in Record_Angle)
return Boolean;
function "+"(
Left : in Record_Angle;
Right : in Record_Angle)
return Boolean;
function "+"(
Item : in Record_Angle)
return Boolean;
function "*"(
Left : in Record_Angle;
Right : in Record_Angle)
return Boolean;
function "/"(
Left : in Record_Angle;
Right : in Record_Angle)
return Boolean;
function "="(
Left : in Record_Angle;
Right : in Record_Angle)
return Boolean;
function Compare(
Item_A : in Record_Angle;
Item_B : in Record_Angle;
ε : in Float_4_Real)
return Boolean;
function Normalize(
Item : in Record_Angle;
Degree : in Float_4_Degree)
return Record_Angle;
procedure Normalize(
Item : in out Record_Angle;
Degree : in Float_4_Degree);
function Clamp(
Item : in Record_Angle;
Minimum : in Record_Angle;
Maximum : in Record_Angle)
return Record_Angle;
procedure Clamp(
Item : in out Record_Angle;
Minimum : in Record_Angle;
Maximum : in Record_Angle);
function To_Yaw(
Item : in Record_Vector_3)
return Float_4_Real;
function To_Pitch(
Item : in Record_Vector_3)
return Float_4_Real;
function To_Record_Angle(
Item : in Record_Vector_3)
return Record_Angle;
function To_Record_Vector_3(
ToVectors( idVec3 *forward, idVec3 *right = NULL, idVec3 *up = NULL ) const;
function To_Record_Vector_3_Forward(
Item : in Record_Angle)
return Record_Vector_3;
function To_Record_Vector_3_Angular_Velocity(
Item : in Record_Angle)
return Record_Vector_3;
function To_Record_Quaternion(
Item : in Record_Angle)
return Record_Quaternion;
function To_Record_Rotation(
Item : in Record_Angle)
return Record_Rotation;
function To_Record_Matrix_3
Item : in Record_Angle)
return Record_Matrix_3;
function To_Record_Matrix_4
Item : in Record_Angle)
return Record_Matrix_3;
end Neo.Library.Angles;