Roll NDK to pick std::deque patch.
[android_tools.git] / sdk / build-tools / 25.0.2 / renderscript / include / rs_allocation_create.rsh
blobd7f9fd66d8e2d405526ad6ee8cf4d5e4d3c89db0
1 /*
2  * Copyright (C) 2016 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
17 // Don't edit this file!  It is auto-generated by frameworks/rs/api/generate.sh.
20  * rs_allocation_create.rsh: Allocation Creation Functions
21  *
22  * The functions below can be used to create Allocations from a Script.
23  *
24  * These functions can be called directly or indirectly from an invokable
25  * function.  If some control-flow path can result in a call to these functions
26  * from a RenderScript kernel function, a compiler error will be generated.
27  */
29 #ifndef RENDERSCRIPT_RS_ALLOCATION_CREATE_RSH
30 #define RENDERSCRIPT_RS_ALLOCATION_CREATE_RSH
33  * rsCreateElement: Creates an rs_element object of the specified data type
34  *
35  *  Creates an rs_element object of the specified data type.  The data kind of
36  *  the Element will be set to RS_KIND_USER and vector_width will be set to 1,
37  *  indicating non-vector.
38  *
39  * Parameters:
40  *   data_type: Data type of the Element
41  */
42 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
43 extern rs_element __attribute__((overloadable))
44     rsCreateElement(rs_data_type data_type);
45 #endif
48  * rsCreateVectorElement: Creates an rs_element object of the specified data type and vector width
49  *
50  *  Creates an rs_element object of the specified data type and vector width.
51  *  Value of vector_width must be 2, 3 or 4.  The data kind of the Element will
52  *  be set to RS_KIND_USER.
53  *
54  * Parameters:
55  *   data_type: Data type of the Element
56  *   vector_width: Vector width (either 2, 3, or 4)
57  */
58 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
59 extern rs_element __attribute__((overloadable))
60     rsCreateVectorElement(rs_data_type data_type, uint32_t vector_width);
61 #endif
64  * rsCreatePixelElement: Creates an rs_element object of the specified data type and data kind
65  *
66  *  Creates an rs_element object of the specified data type and data kind.  The
67  *  vector_width of the Element will be set to 1, indicating non-vector.
68  *
69  * Parameters:
70  *   data_type: Data type of the Element
71  *   data_kind: Data kind of the Element
72  */
73 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
74 extern rs_element __attribute__((overloadable))
75     rsCreatePixelElement(rs_data_type data_type, rs_data_kind data_kind);
76 #endif
79  * rsCreateType: Creates an rs_type object with the specified Element and shape attributes
80  *
81  *  Creates an rs_type object with the specified Element and shape attributes.
82  *
83  *  dimX specifies the size of the X dimension.
84  *
85  *  dimY, if present and non-zero, indicates that the Y dimension is present and
86  *  indicates its size.
87  *
88  *  dimZ, if present and non-zero, indicates that the Z dimension is present and
89  *  indicates its size.
90  *
91  *  mipmaps indicates the presence of level of detail (LOD).
92  *
93  *  faces indicates the  presence of cubemap faces.
94  *
95  *  yuv_format indicates the associated YUV format (or RS_YUV_NONE).
96  *
97  * Parameters:
98  *   element: Element to be associated with the Type
99  *   dimX: Size along the X dimension
100  *   dimY: Size along the Y dimension
101  *   dimZ: Size along the Z dimension
102  *   mipmaps: Flag indicating if the Type has a mipmap chain
103  *   faces: Flag indicating if the Type is a cubemap
104  *   yuv_format: YUV layout for the Type
105  */
106 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
107 extern rs_type __attribute__((overloadable))
108     rsCreateType(rs_element element, uint32_t dimX, uint32_t dimY, uint32_t dimZ, bool mipmaps,
109                  bool faces, rs_yuv_format yuv_format);
110 #endif
112 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
113 extern rs_type __attribute__((overloadable))
114     rsCreateType(rs_element element, uint32_t dimX, uint32_t dimY, uint32_t dimZ);
115 #endif
117 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
118 extern rs_type __attribute__((overloadable))
119     rsCreateType(rs_element element, uint32_t dimX, uint32_t dimY);
120 #endif
122 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
123 extern rs_type __attribute__((overloadable))
124     rsCreateType(rs_element element, uint32_t dimX);
125 #endif
128  * rsCreateAllocation: Create an rs_allocation object of given Type.
130  *  Creates an rs_allocation object of the given Type and usage.
132  *  RS_ALLOCATION_USAGE_SCRIPT and RS_ALLOCATION_USAGE_GRAPHICS_TEXTURE are the
133  *  only supported usage flags for Allocations created from within a RenderScript
134  *  Script.
136  *  You can also use rsCreateAllocation_ wrapper functions to directly
137  *  create Allocations of scalar and vector numerical types without creating
138  *  intermediate rs_element or rs_type objects.
140  *  E.g. rsCreateAllocation_int4() returns an Allocation of int4 data type of
141  *  specified dimensions.
143  * Parameters:
144  *   type: Type of the Allocation
145  *   usage: Usage flag for the allocation
146  */
147 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
148 extern rs_allocation __attribute__((overloadable))
149     rsCreateAllocation(rs_type type, uint32_t usage);
150 #endif
152 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
153 extern rs_allocation __attribute__((overloadable))
154     rsCreateAllocation(rs_type type);
155 #endif
157 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
158 static inline rs_allocation __attribute__((overloadable))
159     rsCreateAllocation_half(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
160      rs_element e = rsCreateElement(RS_TYPE_FLOAT_16);
161      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
162      return rsCreateAllocation(t);
164 #endif
166 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
167 static inline rs_allocation __attribute__((overloadable))
168     rsCreateAllocation_float(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
169      rs_element e = rsCreateElement(RS_TYPE_FLOAT_32);
170      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
171      return rsCreateAllocation(t);
173 #endif
175 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
176 static inline rs_allocation __attribute__((overloadable))
177     rsCreateAllocation_double(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
178      rs_element e = rsCreateElement(RS_TYPE_FLOAT_64);
179      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
180      return rsCreateAllocation(t);
182 #endif
184 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
185 static inline rs_allocation __attribute__((overloadable))
186     rsCreateAllocation_char(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
187      rs_element e = rsCreateElement(RS_TYPE_SIGNED_8);
188      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
189      return rsCreateAllocation(t);
191 #endif
193 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
194 static inline rs_allocation __attribute__((overloadable))
195     rsCreateAllocation_uchar(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
196      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_8);
197      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
198      return rsCreateAllocation(t);
200 #endif
202 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
203 static inline rs_allocation __attribute__((overloadable))
204     rsCreateAllocation_short(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
205      rs_element e = rsCreateElement(RS_TYPE_SIGNED_16);
206      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
207      return rsCreateAllocation(t);
209 #endif
211 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
212 static inline rs_allocation __attribute__((overloadable))
213     rsCreateAllocation_ushort(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
214      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_16);
215      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
216      return rsCreateAllocation(t);
218 #endif
220 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
221 static inline rs_allocation __attribute__((overloadable))
222     rsCreateAllocation_int(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
223      rs_element e = rsCreateElement(RS_TYPE_SIGNED_32);
224      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
225      return rsCreateAllocation(t);
227 #endif
229 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
230 static inline rs_allocation __attribute__((overloadable))
231     rsCreateAllocation_uint(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
232      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_32);
233      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
234      return rsCreateAllocation(t);
236 #endif
238 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
239 static inline rs_allocation __attribute__((overloadable))
240     rsCreateAllocation_long(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
241      rs_element e = rsCreateElement(RS_TYPE_SIGNED_64);
242      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
243      return rsCreateAllocation(t);
245 #endif
247 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
248 static inline rs_allocation __attribute__((overloadable))
249     rsCreateAllocation_ulong(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
250      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_64);
251      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
252      return rsCreateAllocation(t);
254 #endif
256 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
257 static inline rs_allocation __attribute__((overloadable))
258     rsCreateAllocation_half2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
259      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 2);
260      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
261      return rsCreateAllocation(t);
263 #endif
265 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
266 static inline rs_allocation __attribute__((overloadable))
267     rsCreateAllocation_half3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
268      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 3);
269      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
270      return rsCreateAllocation(t);
272 #endif
274 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
275 static inline rs_allocation __attribute__((overloadable))
276     rsCreateAllocation_half4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
277      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 4);
278      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
279      return rsCreateAllocation(t);
281 #endif
283 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
284 static inline rs_allocation __attribute__((overloadable))
285     rsCreateAllocation_float2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
286      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 2);
287      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
288      return rsCreateAllocation(t);
290 #endif
292 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
293 static inline rs_allocation __attribute__((overloadable))
294     rsCreateAllocation_float3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
295      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 3);
296      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
297      return rsCreateAllocation(t);
299 #endif
301 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
302 static inline rs_allocation __attribute__((overloadable))
303     rsCreateAllocation_float4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
304      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 4);
305      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
306      return rsCreateAllocation(t);
308 #endif
310 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
311 static inline rs_allocation __attribute__((overloadable))
312     rsCreateAllocation_double2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
313      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 2);
314      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
315      return rsCreateAllocation(t);
317 #endif
319 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
320 static inline rs_allocation __attribute__((overloadable))
321     rsCreateAllocation_double3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
322      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 3);
323      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
324      return rsCreateAllocation(t);
326 #endif
328 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
329 static inline rs_allocation __attribute__((overloadable))
330     rsCreateAllocation_double4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
331      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 4);
332      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
333      return rsCreateAllocation(t);
335 #endif
337 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
338 static inline rs_allocation __attribute__((overloadable))
339     rsCreateAllocation_char2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
340      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 2);
341      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
342      return rsCreateAllocation(t);
344 #endif
346 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
347 static inline rs_allocation __attribute__((overloadable))
348     rsCreateAllocation_char3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
349      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 3);
350      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
351      return rsCreateAllocation(t);
353 #endif
355 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
356 static inline rs_allocation __attribute__((overloadable))
357     rsCreateAllocation_char4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
358      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 4);
359      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
360      return rsCreateAllocation(t);
362 #endif
364 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
365 static inline rs_allocation __attribute__((overloadable))
366     rsCreateAllocation_uchar2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
367      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 2);
368      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
369      return rsCreateAllocation(t);
371 #endif
373 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
374 static inline rs_allocation __attribute__((overloadable))
375     rsCreateAllocation_uchar3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
376      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 3);
377      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
378      return rsCreateAllocation(t);
380 #endif
382 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
383 static inline rs_allocation __attribute__((overloadable))
384     rsCreateAllocation_uchar4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
385      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 4);
386      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
387      return rsCreateAllocation(t);
389 #endif
391 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
392 static inline rs_allocation __attribute__((overloadable))
393     rsCreateAllocation_short2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
394      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 2);
395      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
396      return rsCreateAllocation(t);
398 #endif
400 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
401 static inline rs_allocation __attribute__((overloadable))
402     rsCreateAllocation_short3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
403      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 3);
404      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
405      return rsCreateAllocation(t);
407 #endif
409 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
410 static inline rs_allocation __attribute__((overloadable))
411     rsCreateAllocation_short4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
412      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 4);
413      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
414      return rsCreateAllocation(t);
416 #endif
418 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
419 static inline rs_allocation __attribute__((overloadable))
420     rsCreateAllocation_ushort2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
421      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 2);
422      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
423      return rsCreateAllocation(t);
425 #endif
427 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
428 static inline rs_allocation __attribute__((overloadable))
429     rsCreateAllocation_ushort3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
430      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 3);
431      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
432      return rsCreateAllocation(t);
434 #endif
436 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
437 static inline rs_allocation __attribute__((overloadable))
438     rsCreateAllocation_ushort4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
439      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 4);
440      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
441      return rsCreateAllocation(t);
443 #endif
445 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
446 static inline rs_allocation __attribute__((overloadable))
447     rsCreateAllocation_int2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
448      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 2);
449      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
450      return rsCreateAllocation(t);
452 #endif
454 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
455 static inline rs_allocation __attribute__((overloadable))
456     rsCreateAllocation_int3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
457      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 3);
458      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
459      return rsCreateAllocation(t);
461 #endif
463 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
464 static inline rs_allocation __attribute__((overloadable))
465     rsCreateAllocation_int4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
466      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 4);
467      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
468      return rsCreateAllocation(t);
470 #endif
472 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
473 static inline rs_allocation __attribute__((overloadable))
474     rsCreateAllocation_uint2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
475      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 2);
476      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
477      return rsCreateAllocation(t);
479 #endif
481 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
482 static inline rs_allocation __attribute__((overloadable))
483     rsCreateAllocation_uint3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
484      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 3);
485      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
486      return rsCreateAllocation(t);
488 #endif
490 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
491 static inline rs_allocation __attribute__((overloadable))
492     rsCreateAllocation_uint4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
493      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 4);
494      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
495      return rsCreateAllocation(t);
497 #endif
499 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
500 static inline rs_allocation __attribute__((overloadable))
501     rsCreateAllocation_long2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
502      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 2);
503      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
504      return rsCreateAllocation(t);
506 #endif
508 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
509 static inline rs_allocation __attribute__((overloadable))
510     rsCreateAllocation_long3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
511      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 3);
512      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
513      return rsCreateAllocation(t);
515 #endif
517 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
518 static inline rs_allocation __attribute__((overloadable))
519     rsCreateAllocation_long4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
520      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 4);
521      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
522      return rsCreateAllocation(t);
524 #endif
526 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
527 static inline rs_allocation __attribute__((overloadable))
528     rsCreateAllocation_ulong2(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
529      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 2);
530      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
531      return rsCreateAllocation(t);
533 #endif
535 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
536 static inline rs_allocation __attribute__((overloadable))
537     rsCreateAllocation_ulong3(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
538      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 3);
539      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
540      return rsCreateAllocation(t);
542 #endif
544 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
545 static inline rs_allocation __attribute__((overloadable))
546     rsCreateAllocation_ulong4(uint32_t dimX, uint32_t dimY, uint32_t dimZ) {
547      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 4);
548      rs_type t = rsCreateType(e, dimX, dimY, dimZ);
549      return rsCreateAllocation(t);
551 #endif
553 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
554 static inline rs_allocation __attribute__((overloadable))
555     rsCreateAllocation_half(uint32_t dimX, uint32_t dimY) {
556      rs_element e = rsCreateElement(RS_TYPE_FLOAT_16);
557      rs_type t = rsCreateType(e, dimX, dimY);
558      return rsCreateAllocation(t);
560 #endif
562 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
563 static inline rs_allocation __attribute__((overloadable))
564     rsCreateAllocation_float(uint32_t dimX, uint32_t dimY) {
565      rs_element e = rsCreateElement(RS_TYPE_FLOAT_32);
566      rs_type t = rsCreateType(e, dimX, dimY);
567      return rsCreateAllocation(t);
569 #endif
571 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
572 static inline rs_allocation __attribute__((overloadable))
573     rsCreateAllocation_double(uint32_t dimX, uint32_t dimY) {
574      rs_element e = rsCreateElement(RS_TYPE_FLOAT_64);
575      rs_type t = rsCreateType(e, dimX, dimY);
576      return rsCreateAllocation(t);
578 #endif
580 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
581 static inline rs_allocation __attribute__((overloadable))
582     rsCreateAllocation_char(uint32_t dimX, uint32_t dimY) {
583      rs_element e = rsCreateElement(RS_TYPE_SIGNED_8);
584      rs_type t = rsCreateType(e, dimX, dimY);
585      return rsCreateAllocation(t);
587 #endif
589 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
590 static inline rs_allocation __attribute__((overloadable))
591     rsCreateAllocation_uchar(uint32_t dimX, uint32_t dimY) {
592      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_8);
593      rs_type t = rsCreateType(e, dimX, dimY);
594      return rsCreateAllocation(t);
596 #endif
598 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
599 static inline rs_allocation __attribute__((overloadable))
600     rsCreateAllocation_short(uint32_t dimX, uint32_t dimY) {
601      rs_element e = rsCreateElement(RS_TYPE_SIGNED_16);
602      rs_type t = rsCreateType(e, dimX, dimY);
603      return rsCreateAllocation(t);
605 #endif
607 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
608 static inline rs_allocation __attribute__((overloadable))
609     rsCreateAllocation_ushort(uint32_t dimX, uint32_t dimY) {
610      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_16);
611      rs_type t = rsCreateType(e, dimX, dimY);
612      return rsCreateAllocation(t);
614 #endif
616 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
617 static inline rs_allocation __attribute__((overloadable))
618     rsCreateAllocation_int(uint32_t dimX, uint32_t dimY) {
619      rs_element e = rsCreateElement(RS_TYPE_SIGNED_32);
620      rs_type t = rsCreateType(e, dimX, dimY);
621      return rsCreateAllocation(t);
623 #endif
625 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
626 static inline rs_allocation __attribute__((overloadable))
627     rsCreateAllocation_uint(uint32_t dimX, uint32_t dimY) {
628      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_32);
629      rs_type t = rsCreateType(e, dimX, dimY);
630      return rsCreateAllocation(t);
632 #endif
634 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
635 static inline rs_allocation __attribute__((overloadable))
636     rsCreateAllocation_long(uint32_t dimX, uint32_t dimY) {
637      rs_element e = rsCreateElement(RS_TYPE_SIGNED_64);
638      rs_type t = rsCreateType(e, dimX, dimY);
639      return rsCreateAllocation(t);
641 #endif
643 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
644 static inline rs_allocation __attribute__((overloadable))
645     rsCreateAllocation_ulong(uint32_t dimX, uint32_t dimY) {
646      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_64);
647      rs_type t = rsCreateType(e, dimX, dimY);
648      return rsCreateAllocation(t);
650 #endif
652 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
653 static inline rs_allocation __attribute__((overloadable))
654     rsCreateAllocation_half2(uint32_t dimX, uint32_t dimY) {
655      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 2);
656      rs_type t = rsCreateType(e, dimX, dimY);
657      return rsCreateAllocation(t);
659 #endif
661 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
662 static inline rs_allocation __attribute__((overloadable))
663     rsCreateAllocation_half3(uint32_t dimX, uint32_t dimY) {
664      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 3);
665      rs_type t = rsCreateType(e, dimX, dimY);
666      return rsCreateAllocation(t);
668 #endif
670 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
671 static inline rs_allocation __attribute__((overloadable))
672     rsCreateAllocation_half4(uint32_t dimX, uint32_t dimY) {
673      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 4);
674      rs_type t = rsCreateType(e, dimX, dimY);
675      return rsCreateAllocation(t);
677 #endif
679 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
680 static inline rs_allocation __attribute__((overloadable))
681     rsCreateAllocation_float2(uint32_t dimX, uint32_t dimY) {
682      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 2);
683      rs_type t = rsCreateType(e, dimX, dimY);
684      return rsCreateAllocation(t);
686 #endif
688 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
689 static inline rs_allocation __attribute__((overloadable))
690     rsCreateAllocation_float3(uint32_t dimX, uint32_t dimY) {
691      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 3);
692      rs_type t = rsCreateType(e, dimX, dimY);
693      return rsCreateAllocation(t);
695 #endif
697 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
698 static inline rs_allocation __attribute__((overloadable))
699     rsCreateAllocation_float4(uint32_t dimX, uint32_t dimY) {
700      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 4);
701      rs_type t = rsCreateType(e, dimX, dimY);
702      return rsCreateAllocation(t);
704 #endif
706 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
707 static inline rs_allocation __attribute__((overloadable))
708     rsCreateAllocation_double2(uint32_t dimX, uint32_t dimY) {
709      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 2);
710      rs_type t = rsCreateType(e, dimX, dimY);
711      return rsCreateAllocation(t);
713 #endif
715 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
716 static inline rs_allocation __attribute__((overloadable))
717     rsCreateAllocation_double3(uint32_t dimX, uint32_t dimY) {
718      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 3);
719      rs_type t = rsCreateType(e, dimX, dimY);
720      return rsCreateAllocation(t);
722 #endif
724 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
725 static inline rs_allocation __attribute__((overloadable))
726     rsCreateAllocation_double4(uint32_t dimX, uint32_t dimY) {
727      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 4);
728      rs_type t = rsCreateType(e, dimX, dimY);
729      return rsCreateAllocation(t);
731 #endif
733 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
734 static inline rs_allocation __attribute__((overloadable))
735     rsCreateAllocation_char2(uint32_t dimX, uint32_t dimY) {
736      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 2);
737      rs_type t = rsCreateType(e, dimX, dimY);
738      return rsCreateAllocation(t);
740 #endif
742 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
743 static inline rs_allocation __attribute__((overloadable))
744     rsCreateAllocation_char3(uint32_t dimX, uint32_t dimY) {
745      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 3);
746      rs_type t = rsCreateType(e, dimX, dimY);
747      return rsCreateAllocation(t);
749 #endif
751 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
752 static inline rs_allocation __attribute__((overloadable))
753     rsCreateAllocation_char4(uint32_t dimX, uint32_t dimY) {
754      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 4);
755      rs_type t = rsCreateType(e, dimX, dimY);
756      return rsCreateAllocation(t);
758 #endif
760 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
761 static inline rs_allocation __attribute__((overloadable))
762     rsCreateAllocation_uchar2(uint32_t dimX, uint32_t dimY) {
763      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 2);
764      rs_type t = rsCreateType(e, dimX, dimY);
765      return rsCreateAllocation(t);
767 #endif
769 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
770 static inline rs_allocation __attribute__((overloadable))
771     rsCreateAllocation_uchar3(uint32_t dimX, uint32_t dimY) {
772      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 3);
773      rs_type t = rsCreateType(e, dimX, dimY);
774      return rsCreateAllocation(t);
776 #endif
778 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
779 static inline rs_allocation __attribute__((overloadable))
780     rsCreateAllocation_uchar4(uint32_t dimX, uint32_t dimY) {
781      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 4);
782      rs_type t = rsCreateType(e, dimX, dimY);
783      return rsCreateAllocation(t);
785 #endif
787 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
788 static inline rs_allocation __attribute__((overloadable))
789     rsCreateAllocation_short2(uint32_t dimX, uint32_t dimY) {
790      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 2);
791      rs_type t = rsCreateType(e, dimX, dimY);
792      return rsCreateAllocation(t);
794 #endif
796 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
797 static inline rs_allocation __attribute__((overloadable))
798     rsCreateAllocation_short3(uint32_t dimX, uint32_t dimY) {
799      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 3);
800      rs_type t = rsCreateType(e, dimX, dimY);
801      return rsCreateAllocation(t);
803 #endif
805 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
806 static inline rs_allocation __attribute__((overloadable))
807     rsCreateAllocation_short4(uint32_t dimX, uint32_t dimY) {
808      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 4);
809      rs_type t = rsCreateType(e, dimX, dimY);
810      return rsCreateAllocation(t);
812 #endif
814 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
815 static inline rs_allocation __attribute__((overloadable))
816     rsCreateAllocation_ushort2(uint32_t dimX, uint32_t dimY) {
817      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 2);
818      rs_type t = rsCreateType(e, dimX, dimY);
819      return rsCreateAllocation(t);
821 #endif
823 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
824 static inline rs_allocation __attribute__((overloadable))
825     rsCreateAllocation_ushort3(uint32_t dimX, uint32_t dimY) {
826      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 3);
827      rs_type t = rsCreateType(e, dimX, dimY);
828      return rsCreateAllocation(t);
830 #endif
832 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
833 static inline rs_allocation __attribute__((overloadable))
834     rsCreateAllocation_ushort4(uint32_t dimX, uint32_t dimY) {
835      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 4);
836      rs_type t = rsCreateType(e, dimX, dimY);
837      return rsCreateAllocation(t);
839 #endif
841 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
842 static inline rs_allocation __attribute__((overloadable))
843     rsCreateAllocation_int2(uint32_t dimX, uint32_t dimY) {
844      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 2);
845      rs_type t = rsCreateType(e, dimX, dimY);
846      return rsCreateAllocation(t);
848 #endif
850 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
851 static inline rs_allocation __attribute__((overloadable))
852     rsCreateAllocation_int3(uint32_t dimX, uint32_t dimY) {
853      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 3);
854      rs_type t = rsCreateType(e, dimX, dimY);
855      return rsCreateAllocation(t);
857 #endif
859 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
860 static inline rs_allocation __attribute__((overloadable))
861     rsCreateAllocation_int4(uint32_t dimX, uint32_t dimY) {
862      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 4);
863      rs_type t = rsCreateType(e, dimX, dimY);
864      return rsCreateAllocation(t);
866 #endif
868 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
869 static inline rs_allocation __attribute__((overloadable))
870     rsCreateAllocation_uint2(uint32_t dimX, uint32_t dimY) {
871      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 2);
872      rs_type t = rsCreateType(e, dimX, dimY);
873      return rsCreateAllocation(t);
875 #endif
877 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
878 static inline rs_allocation __attribute__((overloadable))
879     rsCreateAllocation_uint3(uint32_t dimX, uint32_t dimY) {
880      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 3);
881      rs_type t = rsCreateType(e, dimX, dimY);
882      return rsCreateAllocation(t);
884 #endif
886 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
887 static inline rs_allocation __attribute__((overloadable))
888     rsCreateAllocation_uint4(uint32_t dimX, uint32_t dimY) {
889      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 4);
890      rs_type t = rsCreateType(e, dimX, dimY);
891      return rsCreateAllocation(t);
893 #endif
895 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
896 static inline rs_allocation __attribute__((overloadable))
897     rsCreateAllocation_long2(uint32_t dimX, uint32_t dimY) {
898      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 2);
899      rs_type t = rsCreateType(e, dimX, dimY);
900      return rsCreateAllocation(t);
902 #endif
904 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
905 static inline rs_allocation __attribute__((overloadable))
906     rsCreateAllocation_long3(uint32_t dimX, uint32_t dimY) {
907      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 3);
908      rs_type t = rsCreateType(e, dimX, dimY);
909      return rsCreateAllocation(t);
911 #endif
913 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
914 static inline rs_allocation __attribute__((overloadable))
915     rsCreateAllocation_long4(uint32_t dimX, uint32_t dimY) {
916      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 4);
917      rs_type t = rsCreateType(e, dimX, dimY);
918      return rsCreateAllocation(t);
920 #endif
922 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
923 static inline rs_allocation __attribute__((overloadable))
924     rsCreateAllocation_ulong2(uint32_t dimX, uint32_t dimY) {
925      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 2);
926      rs_type t = rsCreateType(e, dimX, dimY);
927      return rsCreateAllocation(t);
929 #endif
931 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
932 static inline rs_allocation __attribute__((overloadable))
933     rsCreateAllocation_ulong3(uint32_t dimX, uint32_t dimY) {
934      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 3);
935      rs_type t = rsCreateType(e, dimX, dimY);
936      return rsCreateAllocation(t);
938 #endif
940 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
941 static inline rs_allocation __attribute__((overloadable))
942     rsCreateAllocation_ulong4(uint32_t dimX, uint32_t dimY) {
943      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 4);
944      rs_type t = rsCreateType(e, dimX, dimY);
945      return rsCreateAllocation(t);
947 #endif
949 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
950 static inline rs_allocation __attribute__((overloadable))
951     rsCreateAllocation_half(uint32_t dimX) {
952      rs_element e = rsCreateElement(RS_TYPE_FLOAT_16);
953      rs_type t = rsCreateType(e, dimX);
954      return rsCreateAllocation(t);
956 #endif
958 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
959 static inline rs_allocation __attribute__((overloadable))
960     rsCreateAllocation_float(uint32_t dimX) {
961      rs_element e = rsCreateElement(RS_TYPE_FLOAT_32);
962      rs_type t = rsCreateType(e, dimX);
963      return rsCreateAllocation(t);
965 #endif
967 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
968 static inline rs_allocation __attribute__((overloadable))
969     rsCreateAllocation_double(uint32_t dimX) {
970      rs_element e = rsCreateElement(RS_TYPE_FLOAT_64);
971      rs_type t = rsCreateType(e, dimX);
972      return rsCreateAllocation(t);
974 #endif
976 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
977 static inline rs_allocation __attribute__((overloadable))
978     rsCreateAllocation_char(uint32_t dimX) {
979      rs_element e = rsCreateElement(RS_TYPE_SIGNED_8);
980      rs_type t = rsCreateType(e, dimX);
981      return rsCreateAllocation(t);
983 #endif
985 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
986 static inline rs_allocation __attribute__((overloadable))
987     rsCreateAllocation_uchar(uint32_t dimX) {
988      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_8);
989      rs_type t = rsCreateType(e, dimX);
990      return rsCreateAllocation(t);
992 #endif
994 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
995 static inline rs_allocation __attribute__((overloadable))
996     rsCreateAllocation_short(uint32_t dimX) {
997      rs_element e = rsCreateElement(RS_TYPE_SIGNED_16);
998      rs_type t = rsCreateType(e, dimX);
999      return rsCreateAllocation(t);
1001 #endif
1003 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1004 static inline rs_allocation __attribute__((overloadable))
1005     rsCreateAllocation_ushort(uint32_t dimX) {
1006      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_16);
1007      rs_type t = rsCreateType(e, dimX);
1008      return rsCreateAllocation(t);
1010 #endif
1012 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1013 static inline rs_allocation __attribute__((overloadable))
1014     rsCreateAllocation_int(uint32_t dimX) {
1015      rs_element e = rsCreateElement(RS_TYPE_SIGNED_32);
1016      rs_type t = rsCreateType(e, dimX);
1017      return rsCreateAllocation(t);
1019 #endif
1021 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1022 static inline rs_allocation __attribute__((overloadable))
1023     rsCreateAllocation_uint(uint32_t dimX) {
1024      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_32);
1025      rs_type t = rsCreateType(e, dimX);
1026      return rsCreateAllocation(t);
1028 #endif
1030 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1031 static inline rs_allocation __attribute__((overloadable))
1032     rsCreateAllocation_long(uint32_t dimX) {
1033      rs_element e = rsCreateElement(RS_TYPE_SIGNED_64);
1034      rs_type t = rsCreateType(e, dimX);
1035      return rsCreateAllocation(t);
1037 #endif
1039 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1040 static inline rs_allocation __attribute__((overloadable))
1041     rsCreateAllocation_ulong(uint32_t dimX) {
1042      rs_element e = rsCreateElement(RS_TYPE_UNSIGNED_64);
1043      rs_type t = rsCreateType(e, dimX);
1044      return rsCreateAllocation(t);
1046 #endif
1048 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1049 static inline rs_allocation __attribute__((overloadable))
1050     rsCreateAllocation_half2(uint32_t dimX) {
1051      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 2);
1052      rs_type t = rsCreateType(e, dimX);
1053      return rsCreateAllocation(t);
1055 #endif
1057 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1058 static inline rs_allocation __attribute__((overloadable))
1059     rsCreateAllocation_half3(uint32_t dimX) {
1060      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 3);
1061      rs_type t = rsCreateType(e, dimX);
1062      return rsCreateAllocation(t);
1064 #endif
1066 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1067 static inline rs_allocation __attribute__((overloadable))
1068     rsCreateAllocation_half4(uint32_t dimX) {
1069      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_16, 4);
1070      rs_type t = rsCreateType(e, dimX);
1071      return rsCreateAllocation(t);
1073 #endif
1075 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1076 static inline rs_allocation __attribute__((overloadable))
1077     rsCreateAllocation_float2(uint32_t dimX) {
1078      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 2);
1079      rs_type t = rsCreateType(e, dimX);
1080      return rsCreateAllocation(t);
1082 #endif
1084 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1085 static inline rs_allocation __attribute__((overloadable))
1086     rsCreateAllocation_float3(uint32_t dimX) {
1087      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 3);
1088      rs_type t = rsCreateType(e, dimX);
1089      return rsCreateAllocation(t);
1091 #endif
1093 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1094 static inline rs_allocation __attribute__((overloadable))
1095     rsCreateAllocation_float4(uint32_t dimX) {
1096      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_32, 4);
1097      rs_type t = rsCreateType(e, dimX);
1098      return rsCreateAllocation(t);
1100 #endif
1102 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1103 static inline rs_allocation __attribute__((overloadable))
1104     rsCreateAllocation_double2(uint32_t dimX) {
1105      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 2);
1106      rs_type t = rsCreateType(e, dimX);
1107      return rsCreateAllocation(t);
1109 #endif
1111 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1112 static inline rs_allocation __attribute__((overloadable))
1113     rsCreateAllocation_double3(uint32_t dimX) {
1114      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 3);
1115      rs_type t = rsCreateType(e, dimX);
1116      return rsCreateAllocation(t);
1118 #endif
1120 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1121 static inline rs_allocation __attribute__((overloadable))
1122     rsCreateAllocation_double4(uint32_t dimX) {
1123      rs_element e = rsCreateVectorElement(RS_TYPE_FLOAT_64, 4);
1124      rs_type t = rsCreateType(e, dimX);
1125      return rsCreateAllocation(t);
1127 #endif
1129 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1130 static inline rs_allocation __attribute__((overloadable))
1131     rsCreateAllocation_char2(uint32_t dimX) {
1132      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 2);
1133      rs_type t = rsCreateType(e, dimX);
1134      return rsCreateAllocation(t);
1136 #endif
1138 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1139 static inline rs_allocation __attribute__((overloadable))
1140     rsCreateAllocation_char3(uint32_t dimX) {
1141      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 3);
1142      rs_type t = rsCreateType(e, dimX);
1143      return rsCreateAllocation(t);
1145 #endif
1147 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1148 static inline rs_allocation __attribute__((overloadable))
1149     rsCreateAllocation_char4(uint32_t dimX) {
1150      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_8, 4);
1151      rs_type t = rsCreateType(e, dimX);
1152      return rsCreateAllocation(t);
1154 #endif
1156 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1157 static inline rs_allocation __attribute__((overloadable))
1158     rsCreateAllocation_uchar2(uint32_t dimX) {
1159      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 2);
1160      rs_type t = rsCreateType(e, dimX);
1161      return rsCreateAllocation(t);
1163 #endif
1165 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1166 static inline rs_allocation __attribute__((overloadable))
1167     rsCreateAllocation_uchar3(uint32_t dimX) {
1168      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 3);
1169      rs_type t = rsCreateType(e, dimX);
1170      return rsCreateAllocation(t);
1172 #endif
1174 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1175 static inline rs_allocation __attribute__((overloadable))
1176     rsCreateAllocation_uchar4(uint32_t dimX) {
1177      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_8, 4);
1178      rs_type t = rsCreateType(e, dimX);
1179      return rsCreateAllocation(t);
1181 #endif
1183 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1184 static inline rs_allocation __attribute__((overloadable))
1185     rsCreateAllocation_short2(uint32_t dimX) {
1186      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 2);
1187      rs_type t = rsCreateType(e, dimX);
1188      return rsCreateAllocation(t);
1190 #endif
1192 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1193 static inline rs_allocation __attribute__((overloadable))
1194     rsCreateAllocation_short3(uint32_t dimX) {
1195      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 3);
1196      rs_type t = rsCreateType(e, dimX);
1197      return rsCreateAllocation(t);
1199 #endif
1201 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1202 static inline rs_allocation __attribute__((overloadable))
1203     rsCreateAllocation_short4(uint32_t dimX) {
1204      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_16, 4);
1205      rs_type t = rsCreateType(e, dimX);
1206      return rsCreateAllocation(t);
1208 #endif
1210 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1211 static inline rs_allocation __attribute__((overloadable))
1212     rsCreateAllocation_ushort2(uint32_t dimX) {
1213      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 2);
1214      rs_type t = rsCreateType(e, dimX);
1215      return rsCreateAllocation(t);
1217 #endif
1219 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1220 static inline rs_allocation __attribute__((overloadable))
1221     rsCreateAllocation_ushort3(uint32_t dimX) {
1222      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 3);
1223      rs_type t = rsCreateType(e, dimX);
1224      return rsCreateAllocation(t);
1226 #endif
1228 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1229 static inline rs_allocation __attribute__((overloadable))
1230     rsCreateAllocation_ushort4(uint32_t dimX) {
1231      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_16, 4);
1232      rs_type t = rsCreateType(e, dimX);
1233      return rsCreateAllocation(t);
1235 #endif
1237 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1238 static inline rs_allocation __attribute__((overloadable))
1239     rsCreateAllocation_int2(uint32_t dimX) {
1240      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 2);
1241      rs_type t = rsCreateType(e, dimX);
1242      return rsCreateAllocation(t);
1244 #endif
1246 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1247 static inline rs_allocation __attribute__((overloadable))
1248     rsCreateAllocation_int3(uint32_t dimX) {
1249      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 3);
1250      rs_type t = rsCreateType(e, dimX);
1251      return rsCreateAllocation(t);
1253 #endif
1255 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1256 static inline rs_allocation __attribute__((overloadable))
1257     rsCreateAllocation_int4(uint32_t dimX) {
1258      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_32, 4);
1259      rs_type t = rsCreateType(e, dimX);
1260      return rsCreateAllocation(t);
1262 #endif
1264 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1265 static inline rs_allocation __attribute__((overloadable))
1266     rsCreateAllocation_uint2(uint32_t dimX) {
1267      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 2);
1268      rs_type t = rsCreateType(e, dimX);
1269      return rsCreateAllocation(t);
1271 #endif
1273 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1274 static inline rs_allocation __attribute__((overloadable))
1275     rsCreateAllocation_uint3(uint32_t dimX) {
1276      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 3);
1277      rs_type t = rsCreateType(e, dimX);
1278      return rsCreateAllocation(t);
1280 #endif
1282 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1283 static inline rs_allocation __attribute__((overloadable))
1284     rsCreateAllocation_uint4(uint32_t dimX) {
1285      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_32, 4);
1286      rs_type t = rsCreateType(e, dimX);
1287      return rsCreateAllocation(t);
1289 #endif
1291 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1292 static inline rs_allocation __attribute__((overloadable))
1293     rsCreateAllocation_long2(uint32_t dimX) {
1294      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 2);
1295      rs_type t = rsCreateType(e, dimX);
1296      return rsCreateAllocation(t);
1298 #endif
1300 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1301 static inline rs_allocation __attribute__((overloadable))
1302     rsCreateAllocation_long3(uint32_t dimX) {
1303      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 3);
1304      rs_type t = rsCreateType(e, dimX);
1305      return rsCreateAllocation(t);
1307 #endif
1309 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1310 static inline rs_allocation __attribute__((overloadable))
1311     rsCreateAllocation_long4(uint32_t dimX) {
1312      rs_element e = rsCreateVectorElement(RS_TYPE_SIGNED_64, 4);
1313      rs_type t = rsCreateType(e, dimX);
1314      return rsCreateAllocation(t);
1316 #endif
1318 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1319 static inline rs_allocation __attribute__((overloadable))
1320     rsCreateAllocation_ulong2(uint32_t dimX) {
1321      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 2);
1322      rs_type t = rsCreateType(e, dimX);
1323      return rsCreateAllocation(t);
1325 #endif
1327 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1328 static inline rs_allocation __attribute__((overloadable))
1329     rsCreateAllocation_ulong3(uint32_t dimX) {
1330      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 3);
1331      rs_type t = rsCreateType(e, dimX);
1332      return rsCreateAllocation(t);
1334 #endif
1336 #if (defined(RS_VERSION) && (RS_VERSION >= 24))
1337 static inline rs_allocation __attribute__((overloadable))
1338     rsCreateAllocation_ulong4(uint32_t dimX) {
1339      rs_element e = rsCreateVectorElement(RS_TYPE_UNSIGNED_64, 4);
1340      rs_type t = rsCreateType(e, dimX);
1341      return rsCreateAllocation(t);
1343 #endif
1345 #endif // RENDERSCRIPT_RS_ALLOCATION_CREATE_RSH