|
3 | 3 |
|
4 | 4 | #include "euler.h" |
5 | 5 |
|
6 | | - /*! \file |
7 | | - \brief Spherical circle declarations |
| 6 | + /* |
| 7 | + * ! \file \brief Spherical circle declarations |
8 | 8 | */ |
9 | | - |
10 | | - /*! |
11 | | - \brief Spherical circle. |
| 9 | + |
| 10 | + /* |
| 11 | + * ! \brief Spherical circle. |
12 | 12 | */ |
13 | | - typedef struct { |
14 | | - SPoint center; //!< the center of circle |
15 | | - float8 radius; //!< the circle radius in radians |
16 | | - } SCIRCLE; |
| 13 | +typedef struct |
| 14 | +{ |
| 15 | + SPoint center; |
| 16 | + /* !<the center of circle */ |
| 17 | + float8 radius; |
| 18 | + /* !<the circle radius in radians */ |
| 19 | +} SCIRCLE; |
17 | 20 |
|
18 | | - /*! |
19 | | - \brief Checks whether two circles are equal. |
20 | | - \param c1 pointer to first circle |
21 | | - \param c2 pointer to second circle |
22 | | - \return true, if equal |
| 21 | + /* |
| 22 | + * ! \brief Checks whether two circles are equal. \param c1 pointer to first |
| 23 | + * circle \param c2 pointer to second circle \return true, if equal |
23 | 24 | */ |
24 | | - bool scircle_eq ( const SCIRCLE * c1 , const SCIRCLE * c2 ); |
| 25 | +bool scircle_eq(const SCIRCLE *c1, const SCIRCLE *c2); |
25 | 26 |
|
26 | | - /*! |
27 | | - \brief checks whether circle contains point |
28 | | - \param p pointer to point |
29 | | - \param c pointer to circle |
30 | | - \return true, if circle contains point |
| 27 | + /* |
| 28 | + * ! \brief checks whether circle contains point \param p pointer to point |
| 29 | + * \param c pointer to circle \return true, if circle contains point |
31 | 30 | */ |
32 | | - bool spoint_in_circle ( const SPoint * p, const SCIRCLE * c ); |
| 31 | +bool spoint_in_circle(const SPoint *p, const SCIRCLE *c); |
33 | 32 |
|
34 | | - /*! |
35 | | - \brief transforms a circle using Euler transformation |
36 | | - \param out pointer to transformed circle |
37 | | - \param in pointer to circle |
38 | | - \param se pointer to Euler transformation |
39 | | - \return pointer to transformed circle |
| 33 | + /* |
| 34 | + * ! \brief transforms a circle using Euler transformation \param out pointer |
| 35 | + * to transformed circle \param in pointer to circle \param se pointer to |
| 36 | + * Euler transformation \return pointer to transformed circle |
40 | 37 | */ |
41 | | - SCIRCLE * euler_scircle_trans ( SCIRCLE * out , const SCIRCLE * in , const SEuler * se ); |
| 38 | +SCIRCLE *euler_scircle_trans(SCIRCLE *out, const SCIRCLE *in, const SEuler *se); |
42 | 39 |
|
43 | | - /*! |
44 | | - Takes the input and stores it as spherical |
45 | | - circle. |
46 | | - \brief a circle input function |
47 | | - \return a spherical circle datum |
48 | | - \note PostgreSQL function |
| 40 | + /* |
| 41 | + * ! Takes the input and stores it as spherical circle. \brief a circle input |
| 42 | + * function \return a spherical circle datum \note PostgreSQL function |
49 | 43 | */ |
50 | | - Datum spherecircle_in (PG_FUNCTION_ARGS); |
| 44 | +Datum spherecircle_in(PG_FUNCTION_ARGS); |
51 | 45 |
|
52 | | - /*! |
53 | | - Checks whether two circles are equal. |
54 | | - \brief equality of two circles |
55 | | - \return boolean datum |
56 | | - \note PostgreSQL function |
| 46 | + /* |
| 47 | + * ! Checks whether two circles are equal. \brief equality of two circles |
| 48 | + * \return boolean datum \note PostgreSQL function |
57 | 49 | */ |
58 | | - Datum spherecircle_equal (PG_FUNCTION_ARGS); |
| 50 | +Datum spherecircle_equal(PG_FUNCTION_ARGS); |
59 | 51 |
|
60 | | - /*! |
61 | | - Checks whether two circles are not equal. |
62 | | - \brief Checks whether two circles are not equal |
63 | | - \return boolean datum |
64 | | - \note PostgreSQL function |
| 52 | + /* |
| 53 | + * ! Checks whether two circles are not equal. \brief Checks whether two |
| 54 | + * circles are not equal \return boolean datum \note PostgreSQL function |
65 | 55 | */ |
66 | | - Datum spherecircle_equal_neg (PG_FUNCTION_ARGS); |
| 56 | +Datum spherecircle_equal_neg(PG_FUNCTION_ARGS); |
67 | 57 |
|
68 | | - /*! |
69 | | - Calculate the distance of two circles. |
70 | | - If overlapping, this function returns 0.0. |
71 | | - \brief distance of two circles |
72 | | - \return float8 datum |
73 | | - \note PostgreSQL function |
| 58 | + /* |
| 59 | + * ! Calculate the distance of two circles. If overlapping, this function |
| 60 | + * returns 0.0. \brief distance of two circles \return float8 datum \note |
| 61 | + * PostgreSQL function |
74 | 62 | */ |
75 | | - Datum spherecircle_distance (PG_FUNCTION_ARGS); |
| 63 | +Datum spherecircle_distance(PG_FUNCTION_ARGS); |
76 | 64 |
|
77 | | - /*! |
78 | | - Calculate the distance of circle and point. |
79 | | - If circle contains point, this function returns 0.0. |
80 | | - \brief distance of circle and point |
81 | | - \return float8 datum |
82 | | - \note PostgreSQL function |
83 | | - \see spherecircle_point_distance_com(PG_FUNCTION_ARGS) |
| 65 | + /* |
| 66 | + * ! Calculate the distance of circle and point. If circle contains point, |
| 67 | + * this function returns 0.0. \brief distance of circle and point \return |
| 68 | + * float8 datum \note PostgreSQL function \see |
| 69 | + * spherecircle_point_distance_com(PG_FUNCTION_ARGS) |
84 | 70 | */ |
85 | | - Datum spherecircle_point_distance (PG_FUNCTION_ARGS); |
| 71 | +Datum spherecircle_point_distance(PG_FUNCTION_ARGS); |
86 | 72 |
|
87 | | - /*! |
88 | | - Calculate the distance of point and circle. |
89 | | - If circle contains point, this function returns 0.0. |
90 | | - \brief distance of point and circle |
91 | | - \return float8 datum |
92 | | - \note PostgreSQL function |
93 | | - \see spherecircle_point_distance(PG_FUNCTION_ARGS) |
| 73 | + /* |
| 74 | + * ! Calculate the distance of point and circle. If circle contains point, |
| 75 | + * this function returns 0.0. \brief distance of point and circle \return |
| 76 | + * float8 datum \note PostgreSQL function \see |
| 77 | + * spherecircle_point_distance(PG_FUNCTION_ARGS) |
94 | 78 | */ |
95 | | - Datum spherecircle_point_distance_com (PG_FUNCTION_ARGS); |
| 79 | +Datum spherecircle_point_distance_com(PG_FUNCTION_ARGS); |
96 | 80 |
|
97 | | - /*! |
98 | | - \brief Checks whether circle contains point |
99 | | - \return boolean datum |
100 | | - \note PostgreSQL function |
| 81 | + /* |
| 82 | + * ! \brief Checks whether circle contains point \return boolean datum \note |
| 83 | + * PostgreSQL function |
101 | 84 | */ |
102 | | - Datum spherepoint_in_circle (PG_FUNCTION_ARGS); |
| 85 | +Datum spherepoint_in_circle(PG_FUNCTION_ARGS); |
103 | 86 |
|
104 | | - /*! |
105 | | - \brief Checks whether circle doesn't contain point |
106 | | - \return boolean datum |
107 | | - \note PostgreSQL function |
| 87 | + /* |
| 88 | + * ! \brief Checks whether circle doesn't contain point \return boolean datum |
| 89 | + * \note PostgreSQL function |
108 | 90 | */ |
109 | | - Datum spherepoint_in_circle_neg (PG_FUNCTION_ARGS); |
| 91 | +Datum spherepoint_in_circle_neg(PG_FUNCTION_ARGS); |
110 | 92 |
|
111 | | - /*! |
112 | | - \brief Checks whether circle contains point |
113 | | - \return boolean datum |
114 | | - \note PostgreSQL function |
| 93 | + /* |
| 94 | + * ! \brief Checks whether circle contains point \return boolean datum \note |
| 95 | + * PostgreSQL function |
115 | 96 | */ |
116 | | - Datum spherepoint_in_circle_com (PG_FUNCTION_ARGS); |
| 97 | +Datum spherepoint_in_circle_com(PG_FUNCTION_ARGS); |
117 | 98 |
|
118 | | - /*! |
119 | | - \brief Checks whether circle doesn't contain point |
120 | | - \return boolean datum |
121 | | - \note PostgreSQL function |
| 99 | + /* |
| 100 | + * ! \brief Checks whether circle doesn't contain point \return boolean datum |
| 101 | + * \note PostgreSQL function |
122 | 102 | */ |
123 | | - Datum spherepoint_in_circle_com_neg (PG_FUNCTION_ARGS); |
| 103 | +Datum spherepoint_in_circle_com_neg(PG_FUNCTION_ARGS); |
124 | 104 |
|
125 | | - /*! |
126 | | - \brief Checks whether circle is contained by other circle |
127 | | - \return boolean datum |
128 | | - \note PostgreSQL function |
| 105 | + /* |
| 106 | + * ! \brief Checks whether circle is contained by other circle \return |
| 107 | + * boolean datum \note PostgreSQL function |
129 | 108 | */ |
130 | | - Datum spherecircle_in_circle (PG_FUNCTION_ARGS); |
| 109 | +Datum spherecircle_in_circle(PG_FUNCTION_ARGS); |
131 | 110 |
|
132 | | - /*! |
133 | | - \brief Checks whether circle is not contained by other circle |
134 | | - \return boolean datum |
135 | | - \note PostgreSQL function |
| 111 | + /* |
| 112 | + * ! \brief Checks whether circle is not contained by other circle \return |
| 113 | + * boolean datum \note PostgreSQL function |
136 | 114 | */ |
137 | | - Datum spherecircle_in_circle_neg (PG_FUNCTION_ARGS); |
| 115 | +Datum spherecircle_in_circle_neg(PG_FUNCTION_ARGS); |
138 | 116 |
|
139 | | - /*! |
140 | | - \brief Checks whether circle contains other circle |
141 | | - \return boolean datum |
142 | | - \note PostgreSQL function |
| 117 | + /* |
| 118 | + * ! \brief Checks whether circle contains other circle \return boolean datum |
| 119 | + * \note PostgreSQL function |
143 | 120 | */ |
144 | | - Datum spherecircle_in_circle_com (PG_FUNCTION_ARGS); |
| 121 | +Datum spherecircle_in_circle_com(PG_FUNCTION_ARGS); |
145 | 122 |
|
146 | | - /*! |
147 | | - \brief Checks whether circle does not contain other circle |
148 | | - \return boolean datum |
149 | | - \note PostgreSQL function |
| 123 | + /* |
| 124 | + * ! \brief Checks whether circle does not contain other circle \return |
| 125 | + * boolean datum \note PostgreSQL function |
150 | 126 | */ |
151 | | - Datum spherecircle_in_circle_com_neg (PG_FUNCTION_ARGS); |
| 127 | +Datum spherecircle_in_circle_com_neg(PG_FUNCTION_ARGS); |
152 | 128 |
|
153 | | - /*! |
154 | | - \brief Checks whether two circle overlap |
155 | | - \return boolean datum |
156 | | - \note PostgreSQL function |
| 129 | + /* |
| 130 | + * ! \brief Checks whether two circle overlap \return boolean datum \note |
| 131 | + * PostgreSQL function |
157 | 132 | */ |
158 | | - Datum spherecircle_overlap (PG_FUNCTION_ARGS); |
| 133 | +Datum spherecircle_overlap(PG_FUNCTION_ARGS); |
159 | 134 |
|
160 | | - /*! |
161 | | - \brief Checks whether two circle overlap |
162 | | - \return boolean datum |
163 | | - \note PostgreSQL function |
| 135 | + /* |
| 136 | + * ! \brief Checks whether two circle overlap \return boolean datum \note |
| 137 | + * PostgreSQL function |
164 | 138 | */ |
165 | | - Datum spherecircle_overlap_neg (PG_FUNCTION_ARGS); |
| 139 | +Datum spherecircle_overlap_neg(PG_FUNCTION_ARGS); |
166 | 140 |
|
167 | | - /*! |
168 | | - \brief returns the center of circle |
169 | | - \return spherical point datum |
170 | | - \note PostgreSQL function |
| 141 | + /* |
| 142 | + * ! \brief returns the center of circle \return spherical point datum \note |
| 143 | + * PostgreSQL function |
171 | 144 | */ |
172 | | - Datum spherecircle_center (PG_FUNCTION_ARGS); |
| 145 | +Datum spherecircle_center(PG_FUNCTION_ARGS); |
173 | 146 |
|
174 | | - /*! |
175 | | - \brief returns the radius of circle |
176 | | - \return float8 datum |
177 | | - \note PostgreSQL function |
| 147 | + /* |
| 148 | + * ! \brief returns the radius of circle \return float8 datum \note |
| 149 | + * PostgreSQL function |
178 | 150 | */ |
179 | | - Datum spherecircle_radius (PG_FUNCTION_ARGS); |
| 151 | +Datum spherecircle_radius(PG_FUNCTION_ARGS); |
180 | 152 |
|
181 | | - /*! |
182 | | - \brief converts a point to a circle |
183 | | - \return spherical circle datum |
184 | | - \note PostgreSQL function |
| 153 | + /* |
| 154 | + * ! \brief converts a point to a circle \return spherical circle datum \note |
| 155 | + * PostgreSQL function |
185 | 156 | */ |
186 | | - Datum spherepoint_to_circle (PG_FUNCTION_ARGS); |
| 157 | +Datum spherepoint_to_circle(PG_FUNCTION_ARGS); |
187 | 158 |
|
188 | | - /*! |
189 | | - \brief Creates a circle from center and radius |
190 | | - \return spherical circle datum |
191 | | - \note PostgreSQL function |
| 159 | + /* |
| 160 | + * ! \brief Creates a circle from center and radius \return spherical circle |
| 161 | + * datum \note PostgreSQL function |
192 | 162 | */ |
193 | | - Datum spherecircle_by_center (PG_FUNCTION_ARGS); |
| 163 | +Datum spherecircle_by_center(PG_FUNCTION_ARGS); |
194 | 164 |
|
195 | | - /*! |
196 | | - Calculates the area of a circle in square |
197 | | - radians |
198 | | - \brief calculate the area of a circle |
199 | | - \return float8 datum |
200 | | - \note PostgreSQL function |
| 165 | + /* |
| 166 | + * ! Calculates the area of a circle in square radians \brief calculate the |
| 167 | + * area of a circle \return float8 datum \note PostgreSQL function |
201 | 168 | */ |
202 | | - Datum spherecircle_area (PG_FUNCTION_ARGS); |
| 169 | +Datum spherecircle_area(PG_FUNCTION_ARGS); |
203 | 170 |
|
204 | | - /*! |
205 | | - Calculates the circumference of a circle in |
206 | | - radians. |
207 | | - \brief calculate the circumference of a circle |
208 | | - \return float8 datum |
209 | | - \note PostgreSQL function |
| 171 | + /* |
| 172 | + * ! Calculates the circumference of a circle in radians. \brief calculate |
| 173 | + * the circumference of a circle \return float8 datum \note PostgreSQL |
| 174 | + * function |
210 | 175 | */ |
211 | | - Datum spherecircle_circ (PG_FUNCTION_ARGS); |
| 176 | +Datum spherecircle_circ(PG_FUNCTION_ARGS); |
212 | 177 |
|
213 | | - /*! |
214 | | - Transforms a circle using Euler transformation |
215 | | - \brief transforms a circle |
216 | | - \return spherical circle datum |
217 | | - \note PostgreSQL function |
| 178 | + /* |
| 179 | + * ! Transforms a circle using Euler transformation \brief transforms a |
| 180 | + * circle \return spherical circle datum \note PostgreSQL function |
218 | 181 | */ |
219 | | - Datum spheretrans_circle (PG_FUNCTION_ARGS); |
| 182 | +Datum spheretrans_circle(PG_FUNCTION_ARGS); |
220 | 183 |
|
221 | | - /*! |
222 | | - Invers transformation of a circle |
223 | | - using Euler transformation |
224 | | - \brief inverse transformation of a circle |
225 | | - \return spherical circle datum |
226 | | - \note PostgreSQL function |
| 184 | + /* |
| 185 | + * ! Invers transformation of a circle using Euler transformation \brief |
| 186 | + * inverse transformation of a circle \return spherical circle datum \note |
| 187 | + * PostgreSQL function |
227 | 188 | */ |
228 | | - Datum spheretrans_circle_inverse (PG_FUNCTION_ARGS); |
| 189 | +Datum spheretrans_circle_inverse(PG_FUNCTION_ARGS); |
229 | 190 |
|
230 | 191 |
|
231 | 192 |
|
|
0 commit comments