/simpletypesystem/trunk

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/simpletypesystem/trunk

« back to all changes in this revision

Viewing changes to src/vec.h

  • Committer: Gustav Hartvigsson
  • Date: 2015-09-16 18:21:38 UTC
  • Revision ID: gustav.hartvigsson@gmail.com-20150916182138-oeaicreb512vio2k
* vec.h:
  macro -> inline for aliases, should make the __Generic happy, I hope.
* Added ALIGNED_[8,16] macros to align stuff...
* Made MSVC not see __Generic's. (Shit compiler).

Show diffs side-by-side

added added

removed removed

Lines of Context:
56
56
  sfloat c;
57
57
} Vec3_f;
58
58
 
59
 
 
 
59
#ifndef __MSC_VER
60
60
/**
61
61
 * Add Vectors together, resulting in a new vector.
62
62
 *
83
83
                                                   Vec3_f *: vec3_f_add_vec3_f\
84
84
                                                   )\
85
85
                                 )(x,y)
 
86
#endif /* __MSC_VER */
 
87
 
86
88
 
87
89
#define vec_free(x) free (x)
88
90
 
105
107
Vec3 *
106
108
vec3_add_vec3_16 (Vec3 * a, Vec3_16 * b);
107
109
 
108
 
#define vec3_add_vec3_f(x, y) vec3_f_add_vec3(y,x)
109
 
 
110
110
 
111
111
/**
112
112
 * @brief
120
120
Vec3_16 *
121
121
vec3_16_add_vec3_16 (Vec3_16 * a, Vec3_16 * b);
122
122
 
123
 
#define vec3_16_add_vec3(x, y) vec3_add_vec3_16(y, x)
124
 
 
125
 
#define vec3_16_add_vec3_f(x,y) vec3_f_add_vec3_16(y, x)
126
123
 
127
124
 
128
125
 
142
139
vec3_f_add_vec3_16 (Vec3_f * a, Vec3_16 * b);
143
140
 
144
141
 
 
142
/* Aliases */
 
143
inline Vec3_f *
 
144
vec3_add_vec3_f(Vec3 * x, Vec3_f * y){return vec3_f_add_vec3(y, x);}
 
145
 
 
146
inline Vec3 *
 
147
vec3_16_add_vec3(Vec3_16 * x, Vec3 * y) {return vec3_add_vec3_16(y, x);}
 
148
 
 
149
inline Vec3_f *
 
150
vec3_16_add_vec3_f(Vec3_16 * x, Vec3_f * y) {return vec3_f_add_vec3_16(y, x);}
 
151
 
145
152
/** @} */
146
153
 
147
154