blob: 998296ba3f08392fd2e59c8e094421f46a733b06 [file] [log] [blame]
Jason Sams326e0dd2009-05-22 14:03:28 -07001
Jason Sams186e5912011-04-26 14:50:00 -07002DeviceCreate {
3 direct
4 nocontext
5 ret RsDevice
6}
7
8DeviceDestroy {
9 direct
10 nocontext
11 param RsDevice dev
12}
13
14DeviceSetConfig {
15 direct
16 nocontext
17 param RsDevice dev
18 param RsDeviceParam p
19 param int32_t value
20}
21
22ContextCreate {
23 direct
24 nocontext
25 param RsDevice dev
26 param uint32_t version
27 ret RsContext
28}
29
30ContextCreateGL {
31 direct
32 nocontext
33 param RsDevice dev
34 param uint32_t version
35 param RsSurfaceConfig sc
36 param uint32_t dpi
37 ret RsContext
38}
39
40ContextDestroy {
41 direct
42}
43
44ContextGetMessage {
45 direct
46 param void *data
47 param size_t *receiveLen
48 param uint32_t *subID
49 param bool wait
50 ret RsMessageToClientType
51}
52
53ContextPeekMessage {
54 direct
55 param size_t *receiveLen
56 param uint32_t *subID
57 param bool wait
58 ret RsMessageToClientType
59}
60
61ContextInitToClient {
62 direct
63}
64
65ContextDeinitToClient {
66 direct
67}
68
69aTypeCreate {
70 direct
71 param RsElement e
72 param uint32_t dimX
73 param uint32_t dimY
74 param uint32_t dimZ
75 param bool mips
76 param bool faces
77 ret RsType
78}
79
80aAllocationCreateTyped {
81 direct
82 param RsType vtype
83 param RsAllocationMipmapControl mips
84 param uint32_t usages
85 ret RsAllocation
86}
87
88aAllocationCreateFromBitmap {
89 direct
90 param RsType vtype
91 param RsAllocationMipmapControl mips
92 param const void *data
93 param uint32_t usages
94 ret RsAllocation
95}
96
97aAllocationCubeCreateFromBitmap {
98 direct
99 param RsType vtype
100 param RsAllocationMipmapControl mips
101 param const void *data
102 param uint32_t usages
103 ret RsAllocation
104}
105
106
107
Jason Sams8c880902010-06-15 12:15:57 -0700108ContextFinish {
109 handcodeApi
110 }
Jason Sams326e0dd2009-05-22 14:03:28 -0700111
Jason Sams326e0dd2009-05-22 14:03:28 -0700112ContextBindRootScript {
113 param RsScript sampler
114 }
115
Jason Samsccc010b2010-05-13 18:30:11 -0700116ContextBindProgramStore {
117 param RsProgramStore pgm
Jason Sams326e0dd2009-05-22 14:03:28 -0700118 }
119
120ContextBindProgramFragment {
121 param RsProgramFragment pgm
122 }
123
124ContextBindProgramVertex {
125 param RsProgramVertex pgm
126 }
127
Jason Sams5fd09d82009-09-23 13:57:02 -0700128ContextBindProgramRaster {
129 param RsProgramRaster pgm
130 }
131
Alex Sakhartchoukd3e0ad42010-06-24 17:15:34 -0700132ContextBindFont {
133 param RsFont pgm
134 }
135
Jason Sams86f1b232009-09-24 17:38:20 -0700136ContextPause {
137 }
138
139ContextResume {
140 }
141
Jason Sams458f2dc2009-11-03 13:58:36 -0800142ContextSetSurface {
Jason Sams613cad12009-11-12 15:10:25 -0800143 param uint32_t width
144 param uint32_t height
Dianne Hackborn1c769c32010-06-30 13:56:17 -0700145 param ANativeWindow *sur
Jason Sams458f2dc2009-11-03 13:58:36 -0800146 }
147
Jason Samsc21cf402009-11-17 17:26:46 -0800148ContextDump {
149 param int32_t bits
150}
151
Jason Sams613cad12009-11-12 15:10:25 -0800152ContextSetPriority {
Jason Sams15832442009-11-15 12:14:26 -0800153 param int32_t priority
Jason Sams613cad12009-11-12 15:10:25 -0800154 }
155
Jason Sams741aac92010-12-24 14:38:39 -0800156ContextDestroyWorker {
Jason Sams1dcefab2010-12-09 12:19:46 -0800157}
158
Jason Samsa0a1b6f2009-06-10 15:04:38 -0700159AssignName {
Alex Sakhartchouk70b83c12011-04-06 10:57:51 -0700160 param RsObjectBase obj
Jason Samsa0a1b6f2009-06-10 15:04:38 -0700161 param const char *name
162 }
Jason Sams326e0dd2009-05-22 14:03:28 -0700163
Jason Sams707aaf32009-08-18 14:14:24 -0700164ObjDestroy {
Jason Sams2353ae32010-10-14 17:48:46 -0700165 param RsAsyncVoidPtr objPtr
Jason Sams707aaf32009-08-18 14:14:24 -0700166 }
167
Jason Samsd01d9702009-12-23 14:35:29 -0800168ElementCreate {
169 param RsDataType mType
170 param RsDataKind mKind
171 param bool mNormalized
172 param uint32_t mVectorSize
173 ret RsElement
Jason Sams326e0dd2009-05-22 14:03:28 -0700174 }
175
Jason Samsd01d9702009-12-23 14:35:29 -0800176ElementCreate2 {
Jason Samsd01d9702009-12-23 14:35:29 -0800177 param const RsElement * elements
178 param const char ** names
179 param const size_t * nameLengths
Jason Sams46e45542010-09-02 17:35:23 -0700180 param const uint32_t * arraySize
Jason Sams326e0dd2009-05-22 14:03:28 -0700181 ret RsElement
182 }
183
Jason Sams837e3882010-12-10 16:03:15 -0800184AllocationCopyToBitmap {
185 param RsAllocation alloc
186 param void * data
Alex Sakhartchouk39f2ef62010-10-11 12:35:15 -0700187 }
188
Jason Sams326e0dd2009-05-22 14:03:28 -0700189
Jason Sams4b45b892010-12-29 14:31:29 -0800190Allocation1DData {
Jason Sams186e5912011-04-26 14:50:00 -0700191 handcodeApi
Jason Sams326e0dd2009-05-22 14:03:28 -0700192 param RsAllocation va
193 param uint32_t xoff
Jason Sams4b45b892010-12-29 14:31:29 -0800194 param uint32_t lod
Jason Sams326e0dd2009-05-22 14:03:28 -0700195 param uint32_t count
196 param const void *data
Jason Samsd34b7252009-08-04 16:58:20 -0700197 }
Jason Sams326e0dd2009-05-22 14:03:28 -0700198
Jason Sams4b45b892010-12-29 14:31:29 -0800199Allocation1DElementData {
Jason Sams186e5912011-04-26 14:50:00 -0700200 handcodeApi
Jason Sams5f0c84c2010-08-31 13:50:42 -0700201 param RsAllocation va
202 param uint32_t x
Jason Sams4b45b892010-12-29 14:31:29 -0800203 param uint32_t lod
Jason Sams5f0c84c2010-08-31 13:50:42 -0700204 param const void *data
205 param uint32_t comp_offset
Jason Sams5f0c84c2010-08-31 13:50:42 -0700206 }
207
Jason Sams4b45b892010-12-29 14:31:29 -0800208Allocation2DData {
Jason Sams326e0dd2009-05-22 14:03:28 -0700209 param RsAllocation va
210 param uint32_t xoff
211 param uint32_t yoff
Jason Sams4b45b892010-12-29 14:31:29 -0800212 param uint32_t lod
213 param RsAllocationCubemapFace face
Jason Sams326e0dd2009-05-22 14:03:28 -0700214 param uint32_t w
215 param uint32_t h
216 param const void *data
217 }
218
Jason Sams4b45b892010-12-29 14:31:29 -0800219Allocation2DElementData {
Jason Sams5f0c84c2010-08-31 13:50:42 -0700220 param RsAllocation va
221 param uint32_t x
222 param uint32_t y
Jason Sams4b45b892010-12-29 14:31:29 -0800223 param uint32_t lod
224 param RsAllocationCubemapFace face
Jason Sams5f0c84c2010-08-31 13:50:42 -0700225 param const void *data
226 param uint32_t element_offset
Jason Sams5f0c84c2010-08-31 13:50:42 -0700227 }
228
Jason Samsa2371512011-01-12 13:28:37 -0800229AllocationGenerateMipmaps {
230 param RsAllocation va
231}
232
Jason Samse579df42009-08-10 14:55:26 -0700233AllocationRead {
234 param RsAllocation va
235 param void * data
236 }
Jason Sams326e0dd2009-05-22 14:03:28 -0700237
Jason Sams366c9c82010-12-08 16:14:36 -0800238AllocationSyncAll {
239 param RsAllocation va
240 param RsAllocationUsageType src
241}
242
Jason Sams326e0dd2009-05-22 14:03:28 -0700243
Jason Sams96abf812010-10-05 13:32:49 -0700244AllocationResize1D {
245 param RsAllocation va
246 param uint32_t dimX
247 }
248
249AllocationResize2D {
250 param RsAllocation va
251 param uint32_t dimX
252 param uint32_t dimY
253 }
254
Jason Sams326e0dd2009-05-22 14:03:28 -0700255SamplerBegin {
256 }
257
258SamplerSet {
259 param RsSamplerParam p
260 param RsSamplerValue value
261 }
262
Alex Sakhartchouk1103d8e2010-09-30 11:36:37 -0700263SamplerSet2 {
264 param RsSamplerParam p
265 param float value
266 }
267
Jason Sams326e0dd2009-05-22 14:03:28 -0700268SamplerCreate {
269 ret RsSampler
270 }
271
272
Jason Sams326e0dd2009-05-22 14:03:28 -0700273
274ScriptBindAllocation {
275 param RsScript vtm
276 param RsAllocation va
277 param uint32_t slot
278 }
279
280
Jason Samsd34b7252009-08-04 16:58:20 -0700281ScriptSetTimeZone {
282 param RsScript s
Romain Guy98e10fd2009-07-30 18:45:01 -0700283 param const char * timeZone
Romain Guy98e10fd2009-07-30 18:45:01 -0700284 }
285
Jason Sams8c6bc692009-09-16 15:04:38 -0700286
287ScriptInvoke {
288 param RsScript s
289 param uint32_t slot
290 }
291
Jason Samsbe36bf32010-05-11 14:03:58 -0700292ScriptInvokeV {
Jason Sams186e5912011-04-26 14:50:00 -0700293 handcodeApi
Jason Samsbe36bf32010-05-11 14:03:58 -0700294 param RsScript s
295 param uint32_t slot
296 param const void * data
Jason Samsbe36bf32010-05-11 14:03:58 -0700297 }
298
Jason Samsbe36bf32010-05-11 14:03:58 -0700299ScriptSetVarI {
300 param RsScript s
301 param uint32_t slot
302 param int value
303 }
304
Jason Samsa5eb6e12010-11-16 17:37:02 -0800305ScriptSetVarObj {
306 param RsScript s
307 param uint32_t slot
308 param RsObjectBase value
309 }
310
Stephen Hines0977c942010-10-11 10:54:21 -0700311ScriptSetVarJ {
312 param RsScript s
313 param uint32_t slot
314 param int64_t value
315 }
316
Jason Samsbe36bf32010-05-11 14:03:58 -0700317ScriptSetVarF {
318 param RsScript s
319 param uint32_t slot
320 param float value
321 }
322
Stephen Hines6d0a0742010-09-20 17:20:30 -0700323ScriptSetVarD {
324 param RsScript s
325 param uint32_t slot
326 param double value
327 }
328
Jason Samsbe36bf32010-05-11 14:03:58 -0700329ScriptSetVarV {
Jason Sams186e5912011-04-26 14:50:00 -0700330 handcodeApi
Jason Samsbe36bf32010-05-11 14:03:58 -0700331 param RsScript s
332 param uint32_t slot
333 param const void * data
Jason Samsbe36bf32010-05-11 14:03:58 -0700334 }
Jason Samsfa517192009-08-13 12:59:04 -0700335
336
Jason Sams326e0dd2009-05-22 14:03:28 -0700337ScriptCCreate {
Shih-wei Liao9503b662010-11-08 01:33:59 -0800338 param const char * resName
Shih-wei Liao15849d92010-12-10 01:03:59 -0800339 param const char * cacheDir
Jason Samsbad80742011-03-16 16:29:28 -0700340 param const char * text
Jason Sams326e0dd2009-05-22 14:03:28 -0700341 ret RsScript
342 }
343
344
Jason Sams721acc42011-04-06 11:23:54 -0700345ProgramStoreCreate {
346 param bool colorMaskR
347 param bool colorMaskG
348 param bool colorMaskB
349 param bool colorMaskA
350 param bool depthMask
351 param bool ditherEnable
Jason Sams326e0dd2009-05-22 14:03:28 -0700352 param RsBlendSrcFunc srcFunc
353 param RsBlendDstFunc destFunc
Jason Sams721acc42011-04-06 11:23:54 -0700354 param RsDepthFunc depthFunc
Jason Samsccc010b2010-05-13 18:30:11 -0700355 ret RsProgramStore
Jason Sams326e0dd2009-05-22 14:03:28 -0700356 }
357
Jason Sams5fd09d82009-09-23 13:57:02 -0700358ProgramRasterCreate {
Jason Sams5fd09d82009-09-23 13:57:02 -0700359 param bool pointSmooth
360 param bool lineSmooth
361 param bool pointSprite
Jason Sams721acc42011-04-06 11:23:54 -0700362 param float lineWidth
363 param RsCullMode cull
Jason Sams5fd09d82009-09-23 13:57:02 -0700364 ret RsProgramRaster
365}
366
Jason Sams4815c0d2009-12-15 12:58:36 -0800367ProgramBindConstants {
368 param RsProgram vp
369 param uint32_t slot
370 param RsAllocation constants
371 }
372
Jason Sams326e0dd2009-05-22 14:03:28 -0700373
Jason Sams7dad9c32009-12-17 16:55:08 -0800374ProgramBindTexture {
Jason Sams326e0dd2009-05-22 14:03:28 -0700375 param RsProgramFragment pf
376 param uint32_t slot
377 param RsAllocation a
378 }
379
Jason Sams7dad9c32009-12-17 16:55:08 -0800380ProgramBindSampler {
Jason Sams326e0dd2009-05-22 14:03:28 -0700381 param RsProgramFragment pf
382 param uint32_t slot
383 param RsSampler s
384 }
385
Jason Sams326e0dd2009-05-22 14:03:28 -0700386ProgramFragmentCreate {
Jason Samsf2e4fa22009-12-15 13:27:04 -0800387 param const char * shaderText
Jason Samsf2e4fa22009-12-15 13:27:04 -0800388 param const uint32_t * params
Jason Samsf2e4fa22009-12-15 13:27:04 -0800389 ret RsProgramFragment
390 }
391
Jason Sams326e0dd2009-05-22 14:03:28 -0700392ProgramVertexCreate {
Jason Sams4815c0d2009-12-15 12:58:36 -0800393 param const char * shaderText
Jason Sams4815c0d2009-12-15 12:58:36 -0800394 param const uint32_t * params
Jason Samsf2e4fa22009-12-15 13:27:04 -0800395 ret RsProgramVertex
Jason Samsb5909ce2009-07-21 12:20:54 -0700396 }
397
Alex Sakhartchoukd3e0ad42010-06-24 17:15:34 -0700398FontCreateFromFile {
399 param const char *name
Alex Sakhartchoukc17ace22010-12-17 11:41:08 -0800400 param float fontSize
Alex Sakhartchoukd3e0ad42010-06-24 17:15:34 -0700401 param uint32_t dpi
402 ret RsFont
403 }
404
Alex Sakhartchouk5224a272011-01-07 11:12:08 -0800405FontCreateFromMemory {
406 param const char *name
407 param float fontSize
408 param uint32_t dpi
Alex Sakhartchouk70b83c12011-04-06 10:57:51 -0700409 param const void *data
Alex Sakhartchouk5224a272011-01-07 11:12:08 -0800410 ret RsFont
411 }
412
Alex Sakhartchouk4e9a7a82010-07-01 16:14:06 -0700413MeshCreate {
414 ret RsMesh
415 param uint32_t vtxCount
416 param uint32_t idxCount
417 }
418
419MeshBindIndex {
420 param RsMesh mesh
421 param RsAllocation idx
422 param uint32_t primType
423 param uint32_t slot
424 }
425
Alex Sakhartchouk4e9a7a82010-07-01 16:14:06 -0700426MeshBindVertex {
427 param RsMesh mesh
428 param RsAllocation vtx
429 param uint32_t slot
430 }
431
Alex Sakhartchouk54929cc2010-11-08 15:10:52 -0800432MeshInitVertexAttribs {
433 param RsMesh mesh
434 }
Jason Sams186e5912011-04-26 14:50:00 -0700435