Subversion Repository Public Repository

Divide-Dependencies

This repository has no backups
This repository's network speed is throttled to 100KB/sec

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
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
/*
   Copyright (C) 2006, 2007 Sony Computer Entertainment Inc.
   All rights reserved.

   Redistribution and use in source and binary forms,
   with or without modification, are permitted provided that the
   following conditions are met:
    * Redistributions of source code must retain the above copyright
      notice, this list of conditions and the following disclaimer.
    * Redistributions in binary form must reproduce the above copyright
      notice, this list of conditions and the following disclaimer in the
      documentation and/or other materials provided with the distribution.
    * Neither the name of the Sony Computer Entertainment Inc nor the names
      of its contributors may be used to endorse or promote products derived
      from this software without specific prior written permission.

   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
   AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
   IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
   ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
   LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
   CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
   SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
   INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
   CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
   ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
   POSSIBILITY OF SUCH DAMAGE.
*/

#ifndef _VECTORMATH_QUAT_AOS_V_C_H
#define _VECTORMATH_QUAT_AOS_V_C_H
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */

/*-----------------------------------------------------------------------------
 * Definitions
 */
#ifndef _VECTORMATH_INTERNAL_FUNCTIONS
#define _VECTORMATH_INTERNAL_FUNCTIONS

#endif

static inline VmathQuat vmathQMakeFromElems_V( float _x, float _y, float _z, float _w )
{
    VmathQuat result;
    vmathQMakeFromElems(&result, _x, _y, _z, _w);
    return result;
}

static inline VmathQuat vmathQMakeFromV3Scalar_V( VmathVector3 xyz, float _w )
{
    VmathQuat result;
    vmathQMakeFromV3Scalar(&result, &xyz, _w);
    return result;
}

static inline VmathQuat vmathQMakeFromV4_V( VmathVector4 vec )
{
    VmathQuat result;
    vmathQMakeFromV4(&result, &vec);
    return result;
}

static inline VmathQuat vmathQMakeFromScalar_V( float scalar )
{
    VmathQuat result;
    vmathQMakeFromScalar(&result, scalar);
    return result;
}

static inline VmathQuat vmathQMakeIdentity_V( )
{
    VmathQuat result;
    vmathQMakeIdentity(&result);
    return result;
}

static inline VmathQuat vmathQLerp_V( float t, VmathQuat quat0, VmathQuat quat1 )
{
    VmathQuat result;
    vmathQLerp(&result, t, &quat0, &quat1);
    return result;
}

static inline VmathQuat vmathQSlerp_V( float t, VmathQuat unitQuat0, VmathQuat unitQuat1 )
{
    VmathQuat result;
    vmathQSlerp(&result, t, &unitQuat0, &unitQuat1);
    return result;
}

static inline VmathQuat vmathQSquad_V( float t, VmathQuat unitQuat0, VmathQuat unitQuat1, VmathQuat unitQuat2, VmathQuat unitQuat3 )
{
    VmathQuat result;
    vmathQSquad(&result, t, &unitQuat0, &unitQuat1, &unitQuat2, &unitQuat3);
    return result;
}

static inline void vmathQSetXYZ_V( VmathQuat *result, VmathVector3 vec )
{
    vmathQSetXYZ(result, &vec);
}

static inline VmathVector3 vmathQGetXYZ_V( VmathQuat quat )
{
    VmathVector3 result;
    vmathQGetXYZ(&result, &quat);
    return result;
}

static inline void vmathQSetX_V( VmathQuat *result, float _x )
{
    vmathQSetX(result, _x);
}

static inline float vmathQGetX_V( VmathQuat quat )
{
    return vmathQGetX(&quat);
}

static inline void vmathQSetY_V( VmathQuat *result, float _y )
{
    vmathQSetY(result, _y);
}

static inline float vmathQGetY_V( VmathQuat quat )
{
    return vmathQGetY(&quat);
}

static inline void vmathQSetZ_V( VmathQuat *result, float _z )
{
    vmathQSetZ(result, _z);
}

static inline float vmathQGetZ_V( VmathQuat quat )
{
    return vmathQGetZ(&quat);
}

static inline void vmathQSetW_V( VmathQuat *result, float _w )
{
    vmathQSetW(result, _w);
}

static inline float vmathQGetW_V( VmathQuat quat )
{
    return vmathQGetW(&quat);
}

static inline void vmathQSetElem_V( VmathQuat *result, int idx, float value )
{
    vmathQSetElem(result, idx, value);
}

static inline float vmathQGetElem_V( VmathQuat quat, int idx )
{
    return vmathQGetElem(&quat, idx);
}

static inline VmathQuat vmathQAdd_V( VmathQuat quat0, VmathQuat quat1 )
{
    VmathQuat result;
    vmathQAdd(&result, &quat0, &quat1);
    return result;
}

static inline VmathQuat vmathQSub_V( VmathQuat quat0, VmathQuat quat1 )
{
    VmathQuat result;
    vmathQSub(&result, &quat0, &quat1);
    return result;
}

static inline VmathQuat vmathQScalarMul_V( VmathQuat quat, float scalar )
{
    VmathQuat result;
    vmathQScalarMul(&result, &quat, scalar);
    return result;
}

static inline VmathQuat vmathQScalarDiv_V( VmathQuat quat, float scalar )
{
    VmathQuat result;
    vmathQScalarDiv(&result, &quat, scalar);
    return result;
}

static inline VmathQuat vmathQNeg_V( VmathQuat quat )
{
    VmathQuat result;
    vmathQNeg(&result, &quat);
    return result;
}

static inline float vmathQDot_V( VmathQuat quat0, VmathQuat quat1 )
{
    return vmathQDot(&quat0, &quat1);
}

static inline float vmathQNorm_V( VmathQuat quat )
{
    return vmathQNorm(&quat);
}

static inline float vmathQLength_V( VmathQuat quat )
{
    return vmathQLength(&quat);
}

static inline VmathQuat vmathQNormalize_V( VmathQuat quat )
{
    VmathQuat result;
    vmathQNormalize(&result, &quat);
    return result;
}

static inline VmathQuat vmathQMakeRotationArc_V( VmathVector3 unitVec0, VmathVector3 unitVec1 )
{
    VmathQuat result;
    vmathQMakeRotationArc(&result, &unitVec0, &unitVec1);
    return result;
}

static inline VmathQuat vmathQMakeRotationAxis_V( float radians, VmathVector3 unitVec )
{
    VmathQuat result;
    vmathQMakeRotationAxis(&result, radians, &unitVec);
    return result;
}

static inline VmathQuat vmathQMakeRotationX_V( float radians )
{
    VmathQuat result;
    vmathQMakeRotationX(&result, radians);
    return result;
}

static inline VmathQuat vmathQMakeRotationY_V( float radians )
{
    VmathQuat result;
    vmathQMakeRotationY(&result, radians);
    return result;
}

static inline VmathQuat vmathQMakeRotationZ_V( float radians )
{
    VmathQuat result;
    vmathQMakeRotationZ(&result, radians);
    return result;
}

static inline VmathQuat vmathQMul_V( VmathQuat quat0, VmathQuat quat1 )
{
    VmathQuat result;
    vmathQMul(&result, &quat0, &quat1);
    return result;
}

static inline VmathVector3 vmathQRotate_V( VmathQuat quat, VmathVector3 vec )
{
    VmathVector3 result;
    vmathQRotate(&result, &quat, &vec);
    return result;
}

static inline VmathQuat vmathQConj_V( VmathQuat quat )
{
    VmathQuat result;
    vmathQConj(&result, &quat);
    return result;
}

static inline VmathQuat vmathQSelect_V( VmathQuat quat0, VmathQuat quat1, unsigned int select1 )
{
    VmathQuat result;
    vmathQSelect(&result, &quat0, &quat1, select1);
    return result;
}

#ifdef _VECTORMATH_DEBUG

static inline void vmathQPrint_V( VmathQuat quat )
{
    vmathQPrint(&quat);
}

static inline void vmathQPrints_V( VmathQuat quat, const char *name )
{
    vmathQPrints(&quat, name);
}

#endif

#ifdef __cplusplus
}
#endif /* __cplusplus */

#endif

Commits for Divide-Dependencies/debug-draw/samples/vectormath/scalar/c/quat_aos_v.h

Diff revisions: vs.
Revision Author Commited Message
70 IonutCava picture IonutCava Wed 26 Jul, 2017 20:21:42 +0000

[Ionut]
- Added Hodgman’s variant of the debug-draw library. ref: https://github.com/hodgman/debug-draw