blob: b710146deb8336c0d6bdccd19cfc2d8a1a1b6999 [file] [log] [blame]
Jason Sams717e34a2010-03-16 15:35:57 -07001
2typedef char int8_t;
3typedef short int16_t;
4typedef int int32_t;
5//typedef long int64_t;
6
7typedef unsigned char uint8_t;
8typedef unsigned short uint16_t;
9typedef unsigned int uint32_t;
10//typedef long uint64_t;
11
12typedef uint8_t uchar;
13typedef uint16_t ushort;
14typedef uint32_t uint;
15//typedef uint64_t ulong;
16
Jason Samsfcee14d2010-03-18 16:29:59 -070017typedef int rs_element;
18typedef int rs_type;
19typedef int rs_allocation;
20typedef int rs_sampler;
21typedef int rs_script;
22typedef int rs_mesh;
23typedef int rs_program_fragment;
24typedef int rs_program_vertex;
25typedef int rs_program_raster;
26typedef int rs_program_store;
Jason Sams717e34a2010-03-16 15:35:57 -070027
28typedef float float2 __attribute__((ext_vector_type(2)));
29typedef float float3 __attribute__((ext_vector_type(3)));
30typedef float float4 __attribute__((ext_vector_type(4)));
31typedef float float8 __attribute__((ext_vector_type(8)));
32typedef float float16 __attribute__((ext_vector_type(16)));
33
34typedef uchar uchar2 __attribute__((ext_vector_type(2)));
35typedef uchar uchar3 __attribute__((ext_vector_type(3)));
36typedef uchar uchar4 __attribute__((ext_vector_type(4)));
37typedef uchar uchar8 __attribute__((ext_vector_type(8)));
38typedef uchar uchar16 __attribute__((ext_vector_type(16)));
39
40typedef ushort ushort2 __attribute__((ext_vector_type(2)));
41typedef ushort ushort3 __attribute__((ext_vector_type(3)));
42typedef ushort ushort4 __attribute__((ext_vector_type(4)));
43typedef ushort ushort8 __attribute__((ext_vector_type(8)));
44typedef ushort ushort16 __attribute__((ext_vector_type(16)));
45
46typedef uint uint2 __attribute__((ext_vector_type(2)));
47typedef uint uint3 __attribute__((ext_vector_type(3)));
48typedef uint uint4 __attribute__((ext_vector_type(4)));
49typedef uint uint8 __attribute__((ext_vector_type(8)));
50typedef uint uint16 __attribute__((ext_vector_type(16)));
51
52typedef char char2 __attribute__((ext_vector_type(2)));
53typedef char char3 __attribute__((ext_vector_type(3)));
54typedef char char4 __attribute__((ext_vector_type(4)));
55typedef char char8 __attribute__((ext_vector_type(8)));
56typedef char char16 __attribute__((ext_vector_type(16)));
57
58typedef short short2 __attribute__((ext_vector_type(2)));
59typedef short short3 __attribute__((ext_vector_type(3)));
60typedef short short4 __attribute__((ext_vector_type(4)));
61typedef short short8 __attribute__((ext_vector_type(8)));
62typedef short short16 __attribute__((ext_vector_type(16)));
63
64typedef int int2 __attribute__((ext_vector_type(2)));
65typedef int int3 __attribute__((ext_vector_type(3)));
66typedef int int4 __attribute__((ext_vector_type(4)));
67typedef int int8 __attribute__((ext_vector_type(8)));
68typedef int int16 __attribute__((ext_vector_type(16)));
69
70
Jason Samsf2bcce72010-03-26 15:33:42 -070071// RS_KIND_POSITION
72typedef float rs_position1;
73typedef float2 rs_position2;
74typedef float3 rs_position3;
75typedef float4 rs_position4;
76
77// RS_KIND_COLOR
78typedef float3 rs_color3f;
79typedef float4 rs_color4f;
80typedef uchar4 rs_color4u;
81
82// RS_KIND_NORMAL
83typedef float3 rs_normal;
84
85// RS_KIND_POINT_SIZE
86typedef float rs_point_size;
87
88// RS_KIND_TEXTURE
89typedef float rs_texture_coord1;
90typedef float2 rs_texture_coord2;
91typedef float3 rs_texture_coord3;
92typedef float4 rs_texture_coord4;
93
94// RS_KIND_INDEX
95typedef ushort rs_index;
Jason Sams717e34a2010-03-16 15:35:57 -070096