diff options
author | marha <marha@users.sourceforge.net> | 2015-03-05 22:17:40 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2015-03-05 22:17:40 +0100 |
commit | 8574eba804031f6b19713f0b02952280730bf62e (patch) | |
tree | 9afa4d6fe299d43ab7e580dc08a5547120274561 /mesalib/src/mesa/vbo/vbo_attrib_tmp.h | |
parent | eef70231353a6103f47fcae88a6e89e765e5cd47 (diff) | |
download | vcxsrv-8574eba804031f6b19713f0b02952280730bf62e.tar.gz vcxsrv-8574eba804031f6b19713f0b02952280730bf62e.tar.bz2 vcxsrv-8574eba804031f6b19713f0b02952280730bf62e.zip |
fontconfig mesa git update 5 Mar 2015
Diffstat (limited to 'mesalib/src/mesa/vbo/vbo_attrib_tmp.h')
-rw-r--r-- | mesalib/src/mesa/vbo/vbo_attrib_tmp.h | 22 |
1 files changed, 18 insertions, 4 deletions
diff --git a/mesalib/src/mesa/vbo/vbo_attrib_tmp.h b/mesalib/src/mesa/vbo/vbo_attrib_tmp.h index 0c44540fc..b1c3d9842 100644 --- a/mesalib/src/mesa/vbo/vbo_attrib_tmp.h +++ b/mesalib/src/mesa/vbo/vbo_attrib_tmp.h @@ -28,6 +28,22 @@ USE OR OTHER DEALINGS IN THE SOFTWARE. #include "util/u_format_r11g11b10f.h" #include "main/varray.h" + +/* ATTR */ +#define ATTR( A, N, T, V0, V1, V2, V3 ) \ + ATTR_##T((A), (N), (T), (V0), (V1), (V2), (V3)) + +#define ATTR_GL_UNSIGNED_INT( A, N, T, V0, V1, V2, V3 ) \ + ATTR_UNION(A, N, T, UINT_AS_UNION(V0), UINT_AS_UNION(V1), \ + UINT_AS_UNION(V2), UINT_AS_UNION(V3)) +#define ATTR_GL_INT( A, N, T, V0, V1, V2, V3 ) \ + ATTR_UNION(A, N, T, INT_AS_UNION(V0), INT_AS_UNION(V1), \ + INT_AS_UNION(V2), INT_AS_UNION(V3)) +#define ATTR_GL_FLOAT( A, N, T, V0, V1, V2, V3 ) \ + ATTR_UNION(A, N, T, FLOAT_AS_UNION(V0), FLOAT_AS_UNION(V1),\ + FLOAT_AS_UNION(V2), FLOAT_AS_UNION(V3)) + + /* float */ #define ATTR1FV( A, V ) ATTR( A, 1, GL_FLOAT, (V)[0], 0, 0, 1 ) #define ATTR2FV( A, V ) ATTR( A, 2, GL_FLOAT, (V)[0], (V)[1], 0, 1 ) @@ -41,8 +57,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE. /* int */ #define ATTRI( A, N, X, Y, Z, W) ATTR( A, N, GL_INT, \ - INT_AS_FLT(X), INT_AS_FLT(Y), \ - INT_AS_FLT(Z), INT_AS_FLT(W) ) + X, Y, Z, W ) #define ATTR2IV( A, V ) ATTRI( A, 2, (V)[0], (V)[1], 0, 1 ) #define ATTR3IV( A, V ) ATTRI( A, 3, (V)[0], (V)[1], (V)[2], 1 ) @@ -56,8 +71,7 @@ USE OR OTHER DEALINGS IN THE SOFTWARE. /* uint */ #define ATTRUI( A, N, X, Y, Z, W) ATTR( A, N, GL_UNSIGNED_INT, \ - UINT_AS_FLT(X), UINT_AS_FLT(Y), \ - UINT_AS_FLT(Z), UINT_AS_FLT(W) ) + X, Y, Z, W ) #define ATTR2UIV( A, V ) ATTRUI( A, 2, (V)[0], (V)[1], 0, 1 ) #define ATTR3UIV( A, V ) ATTRUI( A, 3, (V)[0], (V)[1], (V)[2], 1 ) |