1 /* 2 * Copyright (C) 2015 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 */ 16 17 18 #include "rsContext.h" 19 #include "rsFifo.h" 20 21 namespace android { 22 namespace renderscript { 23 typedef struct RS_CMD_ContextDestroy_rec RS_CMD_ContextDestroy; 24 typedef struct RS_CMD_ContextGetMessage_rec RS_CMD_ContextGetMessage; 25 typedef struct RS_CMD_ContextPeekMessage_rec RS_CMD_ContextPeekMessage; 26 typedef struct RS_CMD_ContextSendMessage_rec RS_CMD_ContextSendMessage; 27 typedef struct RS_CMD_ContextInitToClient_rec RS_CMD_ContextInitToClient; 28 typedef struct RS_CMD_ContextDeinitToClient_rec RS_CMD_ContextDeinitToClient; 29 typedef struct RS_CMD_ContextSetCacheDir_rec RS_CMD_ContextSetCacheDir; 30 typedef struct RS_CMD_TypeCreate_rec RS_CMD_TypeCreate; 31 typedef struct RS_CMD_TypeCreate2_rec RS_CMD_TypeCreate2; 32 typedef struct RS_CMD_AllocationCreateTyped_rec RS_CMD_AllocationCreateTyped; 33 typedef struct RS_CMD_AllocationCreateFromBitmap_rec RS_CMD_AllocationCreateFromBitmap; 34 typedef struct RS_CMD_AllocationCubeCreateFromBitmap_rec RS_CMD_AllocationCubeCreateFromBitmap; 35 typedef struct RS_CMD_AllocationSetupBufferQueue_rec RS_CMD_AllocationSetupBufferQueue; 36 typedef struct RS_CMD_AllocationShareBufferQueue_rec RS_CMD_AllocationShareBufferQueue; 37 typedef struct RS_CMD_AllocationGetSurface_rec RS_CMD_AllocationGetSurface; 38 typedef struct RS_CMD_AllocationSetSurface_rec RS_CMD_AllocationSetSurface; 39 typedef struct RS_CMD_AllocationAdapterCreate_rec RS_CMD_AllocationAdapterCreate; 40 typedef struct RS_CMD_AllocationAdapterOffset_rec RS_CMD_AllocationAdapterOffset; 41 typedef struct RS_CMD_ContextFinish_rec RS_CMD_ContextFinish; 42 typedef struct RS_CMD_ContextDump_rec RS_CMD_ContextDump; 43 typedef struct RS_CMD_ContextSetPriority_rec RS_CMD_ContextSetPriority; 44 typedef struct RS_CMD_ContextDestroyWorker_rec RS_CMD_ContextDestroyWorker; 45 typedef struct RS_CMD_AssignName_rec RS_CMD_AssignName; 46 typedef struct RS_CMD_ObjDestroy_rec RS_CMD_ObjDestroy; 47 typedef struct RS_CMD_ElementCreate_rec RS_CMD_ElementCreate; 48 typedef struct RS_CMD_ElementCreate2_rec RS_CMD_ElementCreate2; 49 typedef struct RS_CMD_AllocationCopyToBitmap_rec RS_CMD_AllocationCopyToBitmap; 50 typedef struct RS_CMD_AllocationGetPointer_rec RS_CMD_AllocationGetPointer; 51 typedef struct RS_CMD_Allocation1DData_rec RS_CMD_Allocation1DData; 52 typedef struct RS_CMD_Allocation1DElementData_rec RS_CMD_Allocation1DElementData; 53 typedef struct RS_CMD_AllocationElementData_rec RS_CMD_AllocationElementData; 54 typedef struct RS_CMD_Allocation2DData_rec RS_CMD_Allocation2DData; 55 typedef struct RS_CMD_Allocation3DData_rec RS_CMD_Allocation3DData; 56 typedef struct RS_CMD_AllocationGenerateMipmaps_rec RS_CMD_AllocationGenerateMipmaps; 57 typedef struct RS_CMD_AllocationRead_rec RS_CMD_AllocationRead; 58 typedef struct RS_CMD_Allocation1DRead_rec RS_CMD_Allocation1DRead; 59 typedef struct RS_CMD_AllocationElementRead_rec RS_CMD_AllocationElementRead; 60 typedef struct RS_CMD_Allocation2DRead_rec RS_CMD_Allocation2DRead; 61 typedef struct RS_CMD_Allocation3DRead_rec RS_CMD_Allocation3DRead; 62 typedef struct RS_CMD_AllocationSyncAll_rec RS_CMD_AllocationSyncAll; 63 typedef struct RS_CMD_AllocationResize1D_rec RS_CMD_AllocationResize1D; 64 typedef struct RS_CMD_AllocationCopy2DRange_rec RS_CMD_AllocationCopy2DRange; 65 typedef struct RS_CMD_AllocationCopy3DRange_rec RS_CMD_AllocationCopy3DRange; 66 typedef struct RS_CMD_ClosureCreate_rec RS_CMD_ClosureCreate; 67 typedef struct RS_CMD_InvokeClosureCreate_rec RS_CMD_InvokeClosureCreate; 68 typedef struct RS_CMD_ClosureSetArg_rec RS_CMD_ClosureSetArg; 69 typedef struct RS_CMD_ClosureSetGlobal_rec RS_CMD_ClosureSetGlobal; 70 typedef struct RS_CMD_SamplerCreate_rec RS_CMD_SamplerCreate; 71 typedef struct RS_CMD_ScriptBindAllocation_rec RS_CMD_ScriptBindAllocation; 72 typedef struct RS_CMD_ScriptSetTimeZone_rec RS_CMD_ScriptSetTimeZone; 73 typedef struct RS_CMD_ScriptInvokeIDCreate_rec RS_CMD_ScriptInvokeIDCreate; 74 typedef struct RS_CMD_ScriptInvoke_rec RS_CMD_ScriptInvoke; 75 typedef struct RS_CMD_ScriptInvokeV_rec RS_CMD_ScriptInvokeV; 76 typedef struct RS_CMD_ScriptForEach_rec RS_CMD_ScriptForEach; 77 typedef struct RS_CMD_ScriptForEachMulti_rec RS_CMD_ScriptForEachMulti; 78 typedef struct RS_CMD_ScriptReduce_rec RS_CMD_ScriptReduce; 79 typedef struct RS_CMD_ScriptSetVarI_rec RS_CMD_ScriptSetVarI; 80 typedef struct RS_CMD_ScriptSetVarObj_rec RS_CMD_ScriptSetVarObj; 81 typedef struct RS_CMD_ScriptSetVarJ_rec RS_CMD_ScriptSetVarJ; 82 typedef struct RS_CMD_ScriptSetVarF_rec RS_CMD_ScriptSetVarF; 83 typedef struct RS_CMD_ScriptSetVarD_rec RS_CMD_ScriptSetVarD; 84 typedef struct RS_CMD_ScriptSetVarV_rec RS_CMD_ScriptSetVarV; 85 typedef struct RS_CMD_ScriptGetVarV_rec RS_CMD_ScriptGetVarV; 86 typedef struct RS_CMD_ScriptSetVarVE_rec RS_CMD_ScriptSetVarVE; 87 typedef struct RS_CMD_ScriptCCreate_rec RS_CMD_ScriptCCreate; 88 typedef struct RS_CMD_ScriptIntrinsicCreate_rec RS_CMD_ScriptIntrinsicCreate; 89 typedef struct RS_CMD_ScriptKernelIDCreate_rec RS_CMD_ScriptKernelIDCreate; 90 typedef struct RS_CMD_ScriptFieldIDCreate_rec RS_CMD_ScriptFieldIDCreate; 91 typedef struct RS_CMD_ScriptGroupCreate_rec RS_CMD_ScriptGroupCreate; 92 typedef struct RS_CMD_ScriptGroupSetOutput_rec RS_CMD_ScriptGroupSetOutput; 93 typedef struct RS_CMD_ScriptGroupSetInput_rec RS_CMD_ScriptGroupSetInput; 94 typedef struct RS_CMD_ScriptGroupExecute_rec RS_CMD_ScriptGroupExecute; 95 typedef struct RS_CMD_ScriptGroup2Create_rec RS_CMD_ScriptGroup2Create; 96 typedef struct RS_CMD_AllocationIoSend_rec RS_CMD_AllocationIoSend; 97 typedef struct RS_CMD_AllocationIoReceive_rec RS_CMD_AllocationIoReceive; 98 typedef struct RS_CMD_ProgramStoreCreate_rec RS_CMD_ProgramStoreCreate; 99 typedef struct RS_CMD_ProgramRasterCreate_rec RS_CMD_ProgramRasterCreate; 100 typedef struct RS_CMD_ProgramBindConstants_rec RS_CMD_ProgramBindConstants; 101 typedef struct RS_CMD_ProgramBindTexture_rec RS_CMD_ProgramBindTexture; 102 typedef struct RS_CMD_ProgramBindSampler_rec RS_CMD_ProgramBindSampler; 103 typedef struct RS_CMD_ProgramFragmentCreate_rec RS_CMD_ProgramFragmentCreate; 104 typedef struct RS_CMD_ProgramVertexCreate_rec RS_CMD_ProgramVertexCreate; 105 typedef struct RS_CMD_FontCreateFromFile_rec RS_CMD_FontCreateFromFile; 106 typedef struct RS_CMD_FontCreateFromMemory_rec RS_CMD_FontCreateFromMemory; 107 typedef struct RS_CMD_MeshCreate_rec RS_CMD_MeshCreate; 108 typedef struct RS_CMD_ContextBindProgramStore_rec RS_CMD_ContextBindProgramStore; 109 typedef struct RS_CMD_ContextBindProgramFragment_rec RS_CMD_ContextBindProgramFragment; 110 typedef struct RS_CMD_ContextBindProgramVertex_rec RS_CMD_ContextBindProgramVertex; 111 typedef struct RS_CMD_ContextBindProgramRaster_rec RS_CMD_ContextBindProgramRaster; 112 typedef struct RS_CMD_ContextBindFont_rec RS_CMD_ContextBindFont; 113 typedef struct RS_CMD_ContextSetSurface_rec RS_CMD_ContextSetSurface; 114 typedef struct RS_CMD_ContextBindRootScript_rec RS_CMD_ContextBindRootScript; 115 typedef struct RS_CMD_ContextPause_rec RS_CMD_ContextPause; 116 typedef struct RS_CMD_ContextResume_rec RS_CMD_ContextResume; 117 118 #define RS_CMD_ID_ContextDestroy 1 119 struct __attribute__((packed)) RS_CMD_ContextDestroy_rec { 120 }; 121 122 #define RS_CMD_ID_ContextGetMessage 2 123 struct __attribute__((packed)) RS_CMD_ContextGetMessage_rec { 124 void * data; 125 size_t data_length; 126 size_t * receiveLen; 127 size_t receiveLen_length; 128 uint32_t * usrID; 129 size_t usrID_length; 130 }; 131 132 #define RS_CMD_ID_ContextPeekMessage 3 133 struct __attribute__((packed)) RS_CMD_ContextPeekMessage_rec { 134 size_t * receiveLen; 135 size_t receiveLen_length; 136 uint32_t * usrID; 137 size_t usrID_length; 138 }; 139 140 #define RS_CMD_ID_ContextSendMessage 4 141 struct __attribute__((packed)) RS_CMD_ContextSendMessage_rec { 142 uint32_t id; 143 const uint8_t * data; 144 size_t data_length; 145 }; 146 147 #define RS_CMD_ID_ContextInitToClient 5 148 struct __attribute__((packed)) RS_CMD_ContextInitToClient_rec { 149 }; 150 151 #define RS_CMD_ID_ContextDeinitToClient 6 152 struct __attribute__((packed)) RS_CMD_ContextDeinitToClient_rec { 153 }; 154 155 #define RS_CMD_ID_ContextSetCacheDir 7 156 struct __attribute__((packed)) RS_CMD_ContextSetCacheDir_rec { 157 const char * cacheDir; 158 size_t cacheDir_length; 159 }; 160 161 #define RS_CMD_ID_TypeCreate 8 162 struct __attribute__((packed)) RS_CMD_TypeCreate_rec { 163 RsElement e; 164 uint32_t dimX; 165 uint32_t dimY; 166 uint32_t dimZ; 167 bool mipmaps; 168 bool faces; 169 uint32_t yuv; 170 }; 171 172 #define RS_CMD_ID_TypeCreate2 9 173 struct __attribute__((packed)) RS_CMD_TypeCreate2_rec { 174 const RsTypeCreateParams * dat; 175 size_t dat_length; 176 }; 177 178 #define RS_CMD_ID_AllocationCreateTyped 10 179 struct __attribute__((packed)) RS_CMD_AllocationCreateTyped_rec { 180 RsType vtype; 181 RsAllocationMipmapControl mipmaps; 182 uint32_t usages; 183 uintptr_t ptr; 184 }; 185 186 #define RS_CMD_ID_AllocationCreateFromBitmap 11 187 struct __attribute__((packed)) RS_CMD_AllocationCreateFromBitmap_rec { 188 RsType vtype; 189 RsAllocationMipmapControl mipmaps; 190 const void * data; 191 size_t data_length; 192 uint32_t usages; 193 }; 194 195 #define RS_CMD_ID_AllocationCubeCreateFromBitmap 12 196 struct __attribute__((packed)) RS_CMD_AllocationCubeCreateFromBitmap_rec { 197 RsType vtype; 198 RsAllocationMipmapControl mipmaps; 199 const void * data; 200 size_t data_length; 201 uint32_t usages; 202 }; 203 204 #define RS_CMD_ID_AllocationSetupBufferQueue 13 205 struct __attribute__((packed)) RS_CMD_AllocationSetupBufferQueue_rec { 206 RsAllocation alloc; 207 uint32_t numAlloc; 208 }; 209 210 #define RS_CMD_ID_AllocationShareBufferQueue 14 211 struct __attribute__((packed)) RS_CMD_AllocationShareBufferQueue_rec { 212 RsAllocation alloc1; 213 RsAllocation alloc2; 214 }; 215 216 #define RS_CMD_ID_AllocationGetSurface 15 217 struct __attribute__((packed)) RS_CMD_AllocationGetSurface_rec { 218 RsAllocation alloc; 219 }; 220 221 #define RS_CMD_ID_AllocationSetSurface 16 222 struct __attribute__((packed)) RS_CMD_AllocationSetSurface_rec { 223 RsAllocation alloc; 224 RsNativeWindow sur; 225 }; 226 227 #define RS_CMD_ID_AllocationAdapterCreate 17 228 struct __attribute__((packed)) RS_CMD_AllocationAdapterCreate_rec { 229 RsType vtype; 230 RsAllocation baseAlloc; 231 }; 232 233 #define RS_CMD_ID_AllocationAdapterOffset 18 234 struct __attribute__((packed)) RS_CMD_AllocationAdapterOffset_rec { 235 RsAllocation alloc; 236 const uint32_t * offsets; 237 size_t offsets_length; 238 }; 239 240 #define RS_CMD_ID_ContextFinish 19 241 struct __attribute__((packed)) RS_CMD_ContextFinish_rec { 242 }; 243 244 #define RS_CMD_ID_ContextDump 20 245 struct __attribute__((packed)) RS_CMD_ContextDump_rec { 246 int32_t bits; 247 }; 248 249 #define RS_CMD_ID_ContextSetPriority 21 250 struct __attribute__((packed)) RS_CMD_ContextSetPriority_rec { 251 int32_t priority; 252 }; 253 254 #define RS_CMD_ID_ContextDestroyWorker 22 255 struct __attribute__((packed)) RS_CMD_ContextDestroyWorker_rec { 256 }; 257 258 #define RS_CMD_ID_AssignName 23 259 struct __attribute__((packed)) RS_CMD_AssignName_rec { 260 RsObjectBase obj; 261 const char * name; 262 size_t name_length; 263 }; 264 265 #define RS_CMD_ID_ObjDestroy 24 266 struct __attribute__((packed)) RS_CMD_ObjDestroy_rec { 267 RsAsyncVoidPtr objPtr; 268 }; 269 270 #define RS_CMD_ID_ElementCreate 25 271 struct __attribute__((packed)) RS_CMD_ElementCreate_rec { 272 RsDataType mType; 273 RsDataKind mKind; 274 bool mNormalized; 275 uint32_t mVectorSize; 276 }; 277 278 #define RS_CMD_ID_ElementCreate2 26 279 struct __attribute__((packed)) RS_CMD_ElementCreate2_rec { 280 const RsElement * elements; 281 size_t elements_length; 282 const char ** names; 283 size_t names_length_length; 284 const size_t * names_length; 285 const uint32_t * arraySize; 286 size_t arraySize_length; 287 }; 288 289 #define RS_CMD_ID_AllocationCopyToBitmap 27 290 struct __attribute__((packed)) RS_CMD_AllocationCopyToBitmap_rec { 291 RsAllocation alloc; 292 void * data; 293 size_t data_length; 294 }; 295 296 #define RS_CMD_ID_AllocationGetPointer 28 297 struct __attribute__((packed)) RS_CMD_AllocationGetPointer_rec { 298 RsAllocation va; 299 uint32_t lod; 300 RsAllocationCubemapFace face; 301 uint32_t z; 302 uint32_t array; 303 size_t * stride; 304 size_t stride_length; 305 }; 306 307 #define RS_CMD_ID_Allocation1DData 29 308 struct __attribute__((packed)) RS_CMD_Allocation1DData_rec { 309 RsAllocation va; 310 uint32_t xoff; 311 uint32_t lod; 312 uint32_t count; 313 const void * data; 314 size_t data_length; 315 }; 316 317 #define RS_CMD_ID_Allocation1DElementData 30 318 struct __attribute__((packed)) RS_CMD_Allocation1DElementData_rec { 319 RsAllocation va; 320 uint32_t x; 321 uint32_t lod; 322 const void * data; 323 size_t data_length; 324 size_t comp_offset; 325 }; 326 327 #define RS_CMD_ID_AllocationElementData 31 328 struct __attribute__((packed)) RS_CMD_AllocationElementData_rec { 329 RsAllocation va; 330 uint32_t x; 331 uint32_t y; 332 uint32_t z; 333 uint32_t lod; 334 const void * data; 335 size_t data_length; 336 size_t comp_offset; 337 }; 338 339 #define RS_CMD_ID_Allocation2DData 32 340 struct __attribute__((packed)) RS_CMD_Allocation2DData_rec { 341 RsAllocation va; 342 uint32_t xoff; 343 uint32_t yoff; 344 uint32_t lod; 345 RsAllocationCubemapFace face; 346 uint32_t w; 347 uint32_t h; 348 const void * data; 349 size_t data_length; 350 size_t stride; 351 }; 352 353 #define RS_CMD_ID_Allocation3DData 33 354 struct __attribute__((packed)) RS_CMD_Allocation3DData_rec { 355 RsAllocation va; 356 uint32_t xoff; 357 uint32_t yoff; 358 uint32_t zoff; 359 uint32_t lod; 360 uint32_t w; 361 uint32_t h; 362 uint32_t d; 363 const void * data; 364 size_t data_length; 365 size_t stride; 366 }; 367 368 #define RS_CMD_ID_AllocationGenerateMipmaps 34 369 struct __attribute__((packed)) RS_CMD_AllocationGenerateMipmaps_rec { 370 RsAllocation va; 371 }; 372 373 #define RS_CMD_ID_AllocationRead 35 374 struct __attribute__((packed)) RS_CMD_AllocationRead_rec { 375 RsAllocation va; 376 void * data; 377 size_t data_length; 378 }; 379 380 #define RS_CMD_ID_Allocation1DRead 36 381 struct __attribute__((packed)) RS_CMD_Allocation1DRead_rec { 382 RsAllocation va; 383 uint32_t xoff; 384 uint32_t lod; 385 uint32_t count; 386 void * data; 387 size_t data_length; 388 }; 389 390 #define RS_CMD_ID_AllocationElementRead 37 391 struct __attribute__((packed)) RS_CMD_AllocationElementRead_rec { 392 RsAllocation va; 393 uint32_t x; 394 uint32_t y; 395 uint32_t z; 396 uint32_t lod; 397 void * data; 398 size_t data_length; 399 size_t comp_offset; 400 }; 401 402 #define RS_CMD_ID_Allocation2DRead 38 403 struct __attribute__((packed)) RS_CMD_Allocation2DRead_rec { 404 RsAllocation va; 405 uint32_t xoff; 406 uint32_t yoff; 407 uint32_t lod; 408 RsAllocationCubemapFace face; 409 uint32_t w; 410 uint32_t h; 411 void * data; 412 size_t data_length; 413 size_t stride; 414 }; 415 416 #define RS_CMD_ID_Allocation3DRead 39 417 struct __attribute__((packed)) RS_CMD_Allocation3DRead_rec { 418 RsAllocation va; 419 uint32_t xoff; 420 uint32_t yoff; 421 uint32_t zoff; 422 uint32_t lod; 423 uint32_t w; 424 uint32_t h; 425 uint32_t d; 426 void * data; 427 size_t data_length; 428 size_t stride; 429 }; 430 431 #define RS_CMD_ID_AllocationSyncAll 40 432 struct __attribute__((packed)) RS_CMD_AllocationSyncAll_rec { 433 RsAllocation va; 434 RsAllocationUsageType src; 435 }; 436 437 #define RS_CMD_ID_AllocationResize1D 41 438 struct __attribute__((packed)) RS_CMD_AllocationResize1D_rec { 439 RsAllocation va; 440 uint32_t dimX; 441 }; 442 443 #define RS_CMD_ID_AllocationCopy2DRange 42 444 struct __attribute__((packed)) RS_CMD_AllocationCopy2DRange_rec { 445 RsAllocation dest; 446 uint32_t destXoff; 447 uint32_t destYoff; 448 uint32_t destMip; 449 uint32_t destFace; 450 uint32_t width; 451 uint32_t height; 452 RsAllocation src; 453 uint32_t srcXoff; 454 uint32_t srcYoff; 455 uint32_t srcMip; 456 uint32_t srcFace; 457 }; 458 459 #define RS_CMD_ID_AllocationCopy3DRange 43 460 struct __attribute__((packed)) RS_CMD_AllocationCopy3DRange_rec { 461 RsAllocation dest; 462 uint32_t destXoff; 463 uint32_t destYoff; 464 uint32_t destZoff; 465 uint32_t destMip; 466 uint32_t width; 467 uint32_t height; 468 uint32_t depth; 469 RsAllocation src; 470 uint32_t srcXoff; 471 uint32_t srcYoff; 472 uint32_t srcZoff; 473 uint32_t srcMip; 474 }; 475 476 #define RS_CMD_ID_ClosureCreate 44 477 struct __attribute__((packed)) RS_CMD_ClosureCreate_rec { 478 RsScriptKernelID kernelID; 479 RsAllocation returnValue; 480 RsScriptFieldID * fieldIDs; 481 size_t fieldIDs_length; 482 const int64_t * values; 483 size_t values_length; 484 const int * sizes; 485 size_t sizes_length; 486 RsClosure * depClosures; 487 size_t depClosures_length; 488 RsScriptFieldID * depFieldIDs; 489 size_t depFieldIDs_length; 490 }; 491 492 #define RS_CMD_ID_InvokeClosureCreate 45 493 struct __attribute__((packed)) RS_CMD_InvokeClosureCreate_rec { 494 RsScriptInvokeID invokeID; 495 const void * params; 496 size_t params_length; 497 const RsScriptFieldID * fieldIDs; 498 size_t fieldIDs_length; 499 const int64_t * values; 500 size_t values_length; 501 const int * sizes; 502 size_t sizes_length; 503 }; 504 505 #define RS_CMD_ID_ClosureSetArg 46 506 struct __attribute__((packed)) RS_CMD_ClosureSetArg_rec { 507 RsClosure closureID; 508 uint32_t index; 509 uintptr_t value; 510 int valueSize; 511 }; 512 513 #define RS_CMD_ID_ClosureSetGlobal 47 514 struct __attribute__((packed)) RS_CMD_ClosureSetGlobal_rec { 515 RsClosure closureID; 516 RsScriptFieldID fieldID; 517 int64_t value; 518 int valueSize; 519 }; 520 521 #define RS_CMD_ID_SamplerCreate 48 522 struct __attribute__((packed)) RS_CMD_SamplerCreate_rec { 523 RsSamplerValue magFilter; 524 RsSamplerValue minFilter; 525 RsSamplerValue wrapS; 526 RsSamplerValue wrapT; 527 RsSamplerValue wrapR; 528 float mAniso; 529 }; 530 531 #define RS_CMD_ID_ScriptBindAllocation 49 532 struct __attribute__((packed)) RS_CMD_ScriptBindAllocation_rec { 533 RsScript vtm; 534 RsAllocation va; 535 uint32_t slot; 536 }; 537 538 #define RS_CMD_ID_ScriptSetTimeZone 50 539 struct __attribute__((packed)) RS_CMD_ScriptSetTimeZone_rec { 540 RsScript s; 541 const char * timeZone; 542 size_t timeZone_length; 543 }; 544 545 #define RS_CMD_ID_ScriptInvokeIDCreate 51 546 struct __attribute__((packed)) RS_CMD_ScriptInvokeIDCreate_rec { 547 RsScript s; 548 uint32_t slot; 549 }; 550 551 #define RS_CMD_ID_ScriptInvoke 52 552 struct __attribute__((packed)) RS_CMD_ScriptInvoke_rec { 553 RsScript s; 554 uint32_t slot; 555 }; 556 557 #define RS_CMD_ID_ScriptInvokeV 53 558 struct __attribute__((packed)) RS_CMD_ScriptInvokeV_rec { 559 RsScript s; 560 uint32_t slot; 561 const void * data; 562 size_t data_length; 563 }; 564 565 #define RS_CMD_ID_ScriptForEach 54 566 struct __attribute__((packed)) RS_CMD_ScriptForEach_rec { 567 RsScript s; 568 uint32_t slot; 569 RsAllocation ain; 570 RsAllocation aout; 571 const void * usr; 572 size_t usr_length; 573 const RsScriptCall * sc; 574 size_t sc_length; 575 }; 576 577 #define RS_CMD_ID_ScriptForEachMulti 55 578 struct __attribute__((packed)) RS_CMD_ScriptForEachMulti_rec { 579 RsScript s; 580 uint32_t slot; 581 RsAllocation * ains; 582 size_t ains_length; 583 RsAllocation aout; 584 const void * usr; 585 size_t usr_length; 586 const RsScriptCall * sc; 587 size_t sc_length; 588 }; 589 590 #define RS_CMD_ID_ScriptReduce 56 591 struct __attribute__((packed)) RS_CMD_ScriptReduce_rec { 592 RsScript s; 593 uint32_t slot; 594 RsAllocation * ains; 595 size_t ains_length; 596 RsAllocation aout; 597 const RsScriptCall * sc; 598 size_t sc_length; 599 }; 600 601 #define RS_CMD_ID_ScriptSetVarI 57 602 struct __attribute__((packed)) RS_CMD_ScriptSetVarI_rec { 603 RsScript s; 604 uint32_t slot; 605 int value; 606 }; 607 608 #define RS_CMD_ID_ScriptSetVarObj 58 609 struct __attribute__((packed)) RS_CMD_ScriptSetVarObj_rec { 610 RsScript s; 611 uint32_t slot; 612 RsObjectBase value; 613 }; 614 615 #define RS_CMD_ID_ScriptSetVarJ 59 616 struct __attribute__((packed)) RS_CMD_ScriptSetVarJ_rec { 617 RsScript s; 618 uint32_t slot; 619 int64_t value; 620 }; 621 622 #define RS_CMD_ID_ScriptSetVarF 60 623 struct __attribute__((packed)) RS_CMD_ScriptSetVarF_rec { 624 RsScript s; 625 uint32_t slot; 626 float value; 627 }; 628 629 #define RS_CMD_ID_ScriptSetVarD 61 630 struct __attribute__((packed)) RS_CMD_ScriptSetVarD_rec { 631 RsScript s; 632 uint32_t slot; 633 double value; 634 }; 635 636 #define RS_CMD_ID_ScriptSetVarV 62 637 struct __attribute__((packed)) RS_CMD_ScriptSetVarV_rec { 638 RsScript s; 639 uint32_t slot; 640 const void * data; 641 size_t data_length; 642 }; 643 644 #define RS_CMD_ID_ScriptGetVarV 63 645 struct __attribute__((packed)) RS_CMD_ScriptGetVarV_rec { 646 RsScript s; 647 uint32_t slot; 648 void * data; 649 size_t data_length; 650 }; 651 652 #define RS_CMD_ID_ScriptSetVarVE 64 653 struct __attribute__((packed)) RS_CMD_ScriptSetVarVE_rec { 654 RsScript s; 655 uint32_t slot; 656 const void * data; 657 size_t data_length; 658 RsElement e; 659 const uint32_t * dims; 660 size_t dims_length; 661 }; 662 663 #define RS_CMD_ID_ScriptCCreate 65 664 struct __attribute__((packed)) RS_CMD_ScriptCCreate_rec { 665 const char * resName; 666 size_t resName_length; 667 const char * cacheDir; 668 size_t cacheDir_length; 669 const char * text; 670 size_t text_length; 671 }; 672 673 #define RS_CMD_ID_ScriptIntrinsicCreate 66 674 struct __attribute__((packed)) RS_CMD_ScriptIntrinsicCreate_rec { 675 uint32_t id; 676 RsElement eid; 677 }; 678 679 #define RS_CMD_ID_ScriptKernelIDCreate 67 680 struct __attribute__((packed)) RS_CMD_ScriptKernelIDCreate_rec { 681 RsScript sid; 682 int slot; 683 int sig; 684 }; 685 686 #define RS_CMD_ID_ScriptFieldIDCreate 68 687 struct __attribute__((packed)) RS_CMD_ScriptFieldIDCreate_rec { 688 RsScript sid; 689 int slot; 690 }; 691 692 #define RS_CMD_ID_ScriptGroupCreate 69 693 struct __attribute__((packed)) RS_CMD_ScriptGroupCreate_rec { 694 RsScriptKernelID * kernels; 695 size_t kernels_length; 696 RsScriptKernelID * src; 697 size_t src_length; 698 RsScriptKernelID * dstK; 699 size_t dstK_length; 700 RsScriptFieldID * dstF; 701 size_t dstF_length; 702 const RsType * type; 703 size_t type_length; 704 }; 705 706 #define RS_CMD_ID_ScriptGroupSetOutput 70 707 struct __attribute__((packed)) RS_CMD_ScriptGroupSetOutput_rec { 708 RsScriptGroup group; 709 RsScriptKernelID kernel; 710 RsAllocation alloc; 711 }; 712 713 #define RS_CMD_ID_ScriptGroupSetInput 71 714 struct __attribute__((packed)) RS_CMD_ScriptGroupSetInput_rec { 715 RsScriptGroup group; 716 RsScriptKernelID kernel; 717 RsAllocation alloc; 718 }; 719 720 #define RS_CMD_ID_ScriptGroupExecute 72 721 struct __attribute__((packed)) RS_CMD_ScriptGroupExecute_rec { 722 RsScriptGroup group; 723 }; 724 725 #define RS_CMD_ID_ScriptGroup2Create 73 726 struct __attribute__((packed)) RS_CMD_ScriptGroup2Create_rec { 727 const char * name; 728 size_t name_length; 729 const char * cacheDir; 730 size_t cacheDir_length; 731 RsClosure * closures; 732 size_t closures_length; 733 }; 734 735 #define RS_CMD_ID_AllocationIoSend 74 736 struct __attribute__((packed)) RS_CMD_AllocationIoSend_rec { 737 RsAllocation alloc; 738 }; 739 740 #define RS_CMD_ID_AllocationIoReceive 75 741 struct __attribute__((packed)) RS_CMD_AllocationIoReceive_rec { 742 RsAllocation alloc; 743 }; 744 745 #define RS_CMD_ID_ProgramStoreCreate 76 746 struct __attribute__((packed)) RS_CMD_ProgramStoreCreate_rec { 747 bool colorMaskR; 748 bool colorMaskG; 749 bool colorMaskB; 750 bool colorMaskA; 751 bool depthMask; 752 bool ditherEnable; 753 RsBlendSrcFunc srcFunc; 754 RsBlendDstFunc destFunc; 755 RsDepthFunc depthFunc; 756 }; 757 758 #define RS_CMD_ID_ProgramRasterCreate 77 759 struct __attribute__((packed)) RS_CMD_ProgramRasterCreate_rec { 760 bool pointSprite; 761 RsCullMode cull; 762 }; 763 764 #define RS_CMD_ID_ProgramBindConstants 78 765 struct __attribute__((packed)) RS_CMD_ProgramBindConstants_rec { 766 RsProgram vp; 767 uint32_t slot; 768 RsAllocation constants; 769 }; 770 771 #define RS_CMD_ID_ProgramBindTexture 79 772 struct __attribute__((packed)) RS_CMD_ProgramBindTexture_rec { 773 RsProgramFragment pf; 774 uint32_t slot; 775 RsAllocation a; 776 }; 777 778 #define RS_CMD_ID_ProgramBindSampler 80 779 struct __attribute__((packed)) RS_CMD_ProgramBindSampler_rec { 780 RsProgramFragment pf; 781 uint32_t slot; 782 RsSampler s; 783 }; 784 785 #define RS_CMD_ID_ProgramFragmentCreate 81 786 struct __attribute__((packed)) RS_CMD_ProgramFragmentCreate_rec { 787 const char * shaderText; 788 size_t shaderText_length; 789 const char ** textureNames; 790 size_t textureNames_length_length; 791 const size_t * textureNames_length; 792 const uintptr_t * params; 793 size_t params_length; 794 }; 795 796 #define RS_CMD_ID_ProgramVertexCreate 82 797 struct __attribute__((packed)) RS_CMD_ProgramVertexCreate_rec { 798 const char * shaderText; 799 size_t shaderText_length; 800 const char ** textureNames; 801 size_t textureNames_length_length; 802 const size_t * textureNames_length; 803 const uintptr_t * params; 804 size_t params_length; 805 }; 806 807 #define RS_CMD_ID_FontCreateFromFile 83 808 struct __attribute__((packed)) RS_CMD_FontCreateFromFile_rec { 809 const char * name; 810 size_t name_length; 811 float fontSize; 812 uint32_t dpi; 813 }; 814 815 #define RS_CMD_ID_FontCreateFromMemory 84 816 struct __attribute__((packed)) RS_CMD_FontCreateFromMemory_rec { 817 const char * name; 818 size_t name_length; 819 float fontSize; 820 uint32_t dpi; 821 const void * data; 822 size_t data_length; 823 }; 824 825 #define RS_CMD_ID_MeshCreate 85 826 struct __attribute__((packed)) RS_CMD_MeshCreate_rec { 827 RsAllocation * vtx; 828 size_t vtx_length; 829 RsAllocation * idx; 830 size_t idx_length; 831 uint32_t * primType; 832 size_t primType_length; 833 }; 834 835 #define RS_CMD_ID_ContextBindProgramStore 86 836 struct __attribute__((packed)) RS_CMD_ContextBindProgramStore_rec { 837 RsProgramStore pgm; 838 }; 839 840 #define RS_CMD_ID_ContextBindProgramFragment 87 841 struct __attribute__((packed)) RS_CMD_ContextBindProgramFragment_rec { 842 RsProgramFragment pgm; 843 }; 844 845 #define RS_CMD_ID_ContextBindProgramVertex 88 846 struct __attribute__((packed)) RS_CMD_ContextBindProgramVertex_rec { 847 RsProgramVertex pgm; 848 }; 849 850 #define RS_CMD_ID_ContextBindProgramRaster 89 851 struct __attribute__((packed)) RS_CMD_ContextBindProgramRaster_rec { 852 RsProgramRaster pgm; 853 }; 854 855 #define RS_CMD_ID_ContextBindFont 90 856 struct __attribute__((packed)) RS_CMD_ContextBindFont_rec { 857 RsFont pgm; 858 }; 859 860 #define RS_CMD_ID_ContextSetSurface 91 861 struct __attribute__((packed)) RS_CMD_ContextSetSurface_rec { 862 uint32_t width; 863 uint32_t height; 864 RsNativeWindow sur; 865 }; 866 867 #define RS_CMD_ID_ContextBindRootScript 92 868 struct __attribute__((packed)) RS_CMD_ContextBindRootScript_rec { 869 RsScript sampler; 870 }; 871 872 #define RS_CMD_ID_ContextPause 93 873 struct __attribute__((packed)) RS_CMD_ContextPause_rec { 874 }; 875 876 #define RS_CMD_ID_ContextResume 94 877 struct __attribute__((packed)) RS_CMD_ContextResume_rec { 878 }; 879 880 void rsi_ContextDestroy (Context *) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 881 RsMessageToClientType rsi_ContextGetMessage (Context *, void * data, size_t data_length, size_t * receiveLen, size_t receiveLen_length, uint32_t * usrID, size_t usrID_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 882 RsMessageToClientType rsi_ContextPeekMessage (Context *, size_t * receiveLen, size_t receiveLen_length, uint32_t * usrID, size_t usrID_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 883 void rsi_ContextSendMessage (Context *, uint32_t id, const uint8_t * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 884 void rsi_ContextInitToClient (Context *) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 885 void rsi_ContextDeinitToClient (Context *) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 886 void rsi_ContextSetCacheDir (Context *, const char * cacheDir, size_t cacheDir_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 887 RsType rsi_TypeCreate (Context *, RsElement e, uint32_t dimX, uint32_t dimY, uint32_t dimZ, bool mipmaps, bool faces, uint32_t yuv) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 888 RsType rsi_TypeCreate2 (Context *, const RsTypeCreateParams * dat, size_t dat_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 889 RsAllocation rsi_AllocationCreateTyped (Context *, RsType vtype, RsAllocationMipmapControl mipmaps, uint32_t usages, uintptr_t ptr) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 890 RsAllocation rsi_AllocationCreateFromBitmap (Context *, RsType vtype, RsAllocationMipmapControl mipmaps, const void * data, size_t data_length, uint32_t usages) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 891 RsAllocation rsi_AllocationCubeCreateFromBitmap (Context *, RsType vtype, RsAllocationMipmapControl mipmaps, const void * data, size_t data_length, uint32_t usages) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 892 void rsi_AllocationSetupBufferQueue (Context *, RsAllocation alloc, uint32_t numAlloc) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 893 void rsi_AllocationShareBufferQueue (Context *, RsAllocation alloc1, RsAllocation alloc2) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 894 RsNativeWindow rsi_AllocationGetSurface (Context *, RsAllocation alloc) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 895 void rsi_AllocationSetSurface (Context *, RsAllocation alloc, RsNativeWindow sur) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 896 RsAllocation rsi_AllocationAdapterCreate (Context *, RsType vtype, RsAllocation baseAlloc) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 897 void rsi_AllocationAdapterOffset (Context *, RsAllocation alloc, const uint32_t * offsets, size_t offsets_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 898 void rsi_ContextFinish (Context *) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 899 void rsi_ContextDump (Context *, int32_t bits) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 900 void rsi_ContextSetPriority (Context *, int32_t priority) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 901 void rsi_ContextDestroyWorker (Context *) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 902 void rsi_AssignName (Context *, RsObjectBase obj, const char * name, size_t name_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 903 void rsi_ObjDestroy (Context *, RsAsyncVoidPtr objPtr) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 904 RsElement rsi_ElementCreate (Context *, RsDataType mType, RsDataKind mKind, bool mNormalized, uint32_t mVectorSize) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 905 RsElement rsi_ElementCreate2 (Context *, const RsElement * elements, size_t elements_length, const char ** names, size_t names_length_length, const size_t * names_length, const uint32_t * arraySize, size_t arraySize_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 906 void rsi_AllocationCopyToBitmap (Context *, RsAllocation alloc, void * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 907 void * rsi_AllocationGetPointer (Context *, RsAllocation va, uint32_t lod, RsAllocationCubemapFace face, uint32_t z, uint32_t array, size_t * stride, size_t stride_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 908 void rsi_Allocation1DData (Context *, RsAllocation va, uint32_t xoff, uint32_t lod, uint32_t count, const void * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 909 void rsi_Allocation1DElementData (Context *, RsAllocation va, uint32_t x, uint32_t lod, const void * data, size_t data_length, size_t comp_offset) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 910 void rsi_AllocationElementData (Context *, RsAllocation va, uint32_t x, uint32_t y, uint32_t z, uint32_t lod, const void * data, size_t data_length, size_t comp_offset) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 911 void rsi_Allocation2DData (Context *, RsAllocation va, uint32_t xoff, uint32_t yoff, uint32_t lod, RsAllocationCubemapFace face, uint32_t w, uint32_t h, const void * data, size_t data_length, size_t stride) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 912 void rsi_Allocation3DData (Context *, RsAllocation va, uint32_t xoff, uint32_t yoff, uint32_t zoff, uint32_t lod, uint32_t w, uint32_t h, uint32_t d, const void * data, size_t data_length, size_t stride) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 913 void rsi_AllocationGenerateMipmaps (Context *, RsAllocation va) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 914 void rsi_AllocationRead (Context *, RsAllocation va, void * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 915 void rsi_Allocation1DRead (Context *, RsAllocation va, uint32_t xoff, uint32_t lod, uint32_t count, void * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 916 void rsi_AllocationElementRead (Context *, RsAllocation va, uint32_t x, uint32_t y, uint32_t z, uint32_t lod, void * data, size_t data_length, size_t comp_offset) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 917 void rsi_Allocation2DRead (Context *, RsAllocation va, uint32_t xoff, uint32_t yoff, uint32_t lod, RsAllocationCubemapFace face, uint32_t w, uint32_t h, void * data, size_t data_length, size_t stride) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 918 void rsi_Allocation3DRead (Context *, RsAllocation va, uint32_t xoff, uint32_t yoff, uint32_t zoff, uint32_t lod, uint32_t w, uint32_t h, uint32_t d, void * data, size_t data_length, size_t stride) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 919 void rsi_AllocationSyncAll (Context *, RsAllocation va, RsAllocationUsageType src) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 920 void rsi_AllocationResize1D (Context *, RsAllocation va, uint32_t dimX) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 921 void rsi_AllocationCopy2DRange (Context *, RsAllocation dest, uint32_t destXoff, uint32_t destYoff, uint32_t destMip, uint32_t destFace, uint32_t width, uint32_t height, RsAllocation src, uint32_t srcXoff, uint32_t srcYoff, uint32_t srcMip, uint32_t srcFace) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 922 void rsi_AllocationCopy3DRange (Context *, RsAllocation dest, uint32_t destXoff, uint32_t destYoff, uint32_t destZoff, uint32_t destMip, uint32_t width, uint32_t height, uint32_t depth, RsAllocation src, uint32_t srcXoff, uint32_t srcYoff, uint32_t srcZoff, uint32_t srcMip) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 923 RsClosure rsi_ClosureCreate (Context *, RsScriptKernelID kernelID, RsAllocation returnValue, RsScriptFieldID * fieldIDs, size_t fieldIDs_length, const int64_t * values, size_t values_length, const int * sizes, size_t sizes_length, RsClosure * depClosures, size_t depClosures_length, RsScriptFieldID * depFieldIDs, size_t depFieldIDs_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 924 RsClosure rsi_InvokeClosureCreate (Context *, RsScriptInvokeID invokeID, const void * params, size_t params_length, const RsScriptFieldID * fieldIDs, size_t fieldIDs_length, const int64_t * values, size_t values_length, const int * sizes, size_t sizes_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 925 void rsi_ClosureSetArg (Context *, RsClosure closureID, uint32_t index, uintptr_t value, int valueSize) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 926 void rsi_ClosureSetGlobal (Context *, RsClosure closureID, RsScriptFieldID fieldID, int64_t value, int valueSize) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 927 RsSampler rsi_SamplerCreate (Context *, RsSamplerValue magFilter, RsSamplerValue minFilter, RsSamplerValue wrapS, RsSamplerValue wrapT, RsSamplerValue wrapR, float mAniso) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 928 void rsi_ScriptBindAllocation (Context *, RsScript vtm, RsAllocation va, uint32_t slot) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 929 void rsi_ScriptSetTimeZone (Context *, RsScript s, const char * timeZone, size_t timeZone_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 930 RsScriptInvokeID rsi_ScriptInvokeIDCreate (Context *, RsScript s, uint32_t slot) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 931 void rsi_ScriptInvoke (Context *, RsScript s, uint32_t slot) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 932 void rsi_ScriptInvokeV (Context *, RsScript s, uint32_t slot, const void * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 933 void rsi_ScriptForEach (Context *, RsScript s, uint32_t slot, RsAllocation ain, RsAllocation aout, const void * usr, size_t usr_length, const RsScriptCall * sc, size_t sc_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 934 void rsi_ScriptForEachMulti (Context *, RsScript s, uint32_t slot, RsAllocation * ains, size_t ains_length, RsAllocation aout, const void * usr, size_t usr_length, const RsScriptCall * sc, size_t sc_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 935 void rsi_ScriptReduce (Context *, RsScript s, uint32_t slot, RsAllocation * ains, size_t ains_length, RsAllocation aout, const RsScriptCall * sc, size_t sc_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 936 void rsi_ScriptSetVarI (Context *, RsScript s, uint32_t slot, int value) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 937 void rsi_ScriptSetVarObj (Context *, RsScript s, uint32_t slot, RsObjectBase value) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 938 void rsi_ScriptSetVarJ (Context *, RsScript s, uint32_t slot, int64_t value) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 939 void rsi_ScriptSetVarF (Context *, RsScript s, uint32_t slot, float value) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 940 void rsi_ScriptSetVarD (Context *, RsScript s, uint32_t slot, double value) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 941 void rsi_ScriptSetVarV (Context *, RsScript s, uint32_t slot, const void * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 942 void rsi_ScriptGetVarV (Context *, RsScript s, uint32_t slot, void * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 943 void rsi_ScriptSetVarVE (Context *, RsScript s, uint32_t slot, const void * data, size_t data_length, RsElement e, const uint32_t * dims, size_t dims_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 944 RsScript rsi_ScriptCCreate (Context *, const char * resName, size_t resName_length, const char * cacheDir, size_t cacheDir_length, const char * text, size_t text_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 945 RsScript rsi_ScriptIntrinsicCreate (Context *, uint32_t id, RsElement eid) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 946 RsScriptKernelID rsi_ScriptKernelIDCreate (Context *, RsScript sid, int slot, int sig) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 947 RsScriptFieldID rsi_ScriptFieldIDCreate (Context *, RsScript sid, int slot) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 948 RsScriptGroup rsi_ScriptGroupCreate (Context *, RsScriptKernelID * kernels, size_t kernels_length, RsScriptKernelID * src, size_t src_length, RsScriptKernelID * dstK, size_t dstK_length, RsScriptFieldID * dstF, size_t dstF_length, const RsType * type, size_t type_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 949 void rsi_ScriptGroupSetOutput (Context *, RsScriptGroup group, RsScriptKernelID kernel, RsAllocation alloc) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 950 void rsi_ScriptGroupSetInput (Context *, RsScriptGroup group, RsScriptKernelID kernel, RsAllocation alloc) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 951 void rsi_ScriptGroupExecute (Context *, RsScriptGroup group) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 952 RsScriptGroup2 rsi_ScriptGroup2Create (Context *, const char * name, size_t name_length, const char * cacheDir, size_t cacheDir_length, RsClosure * closures, size_t closures_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 953 void rsi_AllocationIoSend (Context *, RsAllocation alloc) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 954 int64_t rsi_AllocationIoReceive (Context *, RsAllocation alloc) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 955 RsProgramStore rsi_ProgramStoreCreate (Context *, bool colorMaskR, bool colorMaskG, bool colorMaskB, bool colorMaskA, bool depthMask, bool ditherEnable, RsBlendSrcFunc srcFunc, RsBlendDstFunc destFunc, RsDepthFunc depthFunc) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 956 RsProgramRaster rsi_ProgramRasterCreate (Context *, bool pointSprite, RsCullMode cull) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 957 void rsi_ProgramBindConstants (Context *, RsProgram vp, uint32_t slot, RsAllocation constants) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 958 void rsi_ProgramBindTexture (Context *, RsProgramFragment pf, uint32_t slot, RsAllocation a) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 959 void rsi_ProgramBindSampler (Context *, RsProgramFragment pf, uint32_t slot, RsSampler s) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 960 RsProgramFragment rsi_ProgramFragmentCreate (Context *, const char * shaderText, size_t shaderText_length, const char ** textureNames, size_t textureNames_length_length, const size_t * textureNames_length, const uintptr_t * params, size_t params_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 961 RsProgramVertex rsi_ProgramVertexCreate (Context *, const char * shaderText, size_t shaderText_length, const char ** textureNames, size_t textureNames_length_length, const size_t * textureNames_length, const uintptr_t * params, size_t params_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 962 RsFont rsi_FontCreateFromFile (Context *, const char * name, size_t name_length, float fontSize, uint32_t dpi) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 963 RsFont rsi_FontCreateFromMemory (Context *, const char * name, size_t name_length, float fontSize, uint32_t dpi, const void * data, size_t data_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 964 RsMesh rsi_MeshCreate (Context *, RsAllocation * vtx, size_t vtx_length, RsAllocation * idx, size_t idx_length, uint32_t * primType, size_t primType_length) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 965 void rsi_ContextBindProgramStore (Context *, RsProgramStore pgm) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 966 void rsi_ContextBindProgramFragment (Context *, RsProgramFragment pgm) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 967 void rsi_ContextBindProgramVertex (Context *, RsProgramVertex pgm) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 968 void rsi_ContextBindProgramRaster (Context *, RsProgramRaster pgm) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 969 void rsi_ContextBindFont (Context *, RsFont pgm) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 970 void rsi_ContextSetSurface (Context *, uint32_t width, uint32_t height, RsNativeWindow sur) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 971 void rsi_ContextBindRootScript (Context *, RsScript sampler) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 972 void rsi_ContextPause (Context *) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 973 void rsi_ContextResume (Context *) __DEPRECATED_IN(31, "RenderScript is deprecated. See https://developer.android.com/guide/topics/renderscript/migrate"); 974 975 976 void rsp_ContextSendMessage (Context *, const void *); 977 void rsp_AllocationSetupBufferQueue (Context *, const void *); 978 void rsp_AllocationShareBufferQueue (Context *, const void *); 979 void rsp_AllocationGetSurface (Context *, const void *); 980 void rsp_AllocationSetSurface (Context *, const void *); 981 void rsp_AllocationAdapterOffset (Context *, const void *); 982 void rsp_ContextFinish (Context *, const void *); 983 void rsp_ContextDump (Context *, const void *); 984 void rsp_ContextSetPriority (Context *, const void *); 985 void rsp_ContextDestroyWorker (Context *, const void *); 986 void rsp_AssignName (Context *, const void *); 987 void rsp_ObjDestroy (Context *, const void *); 988 void rsp_AllocationCopyToBitmap (Context *, const void *); 989 void rsp_AllocationGetPointer (Context *, const void *); 990 void rsp_Allocation1DData (Context *, const void *); 991 void rsp_Allocation1DElementData (Context *, const void *); 992 void rsp_AllocationElementData (Context *, const void *); 993 void rsp_Allocation2DData (Context *, const void *); 994 void rsp_Allocation3DData (Context *, const void *); 995 void rsp_AllocationGenerateMipmaps (Context *, const void *); 996 void rsp_AllocationRead (Context *, const void *); 997 void rsp_Allocation1DRead (Context *, const void *); 998 void rsp_AllocationElementRead (Context *, const void *); 999 void rsp_Allocation2DRead (Context *, const void *); 1000 void rsp_Allocation3DRead (Context *, const void *); 1001 void rsp_AllocationSyncAll (Context *, const void *); 1002 void rsp_AllocationResize1D (Context *, const void *); 1003 void rsp_AllocationCopy2DRange (Context *, const void *); 1004 void rsp_AllocationCopy3DRange (Context *, const void *); 1005 void rsp_ClosureSetArg (Context *, const void *); 1006 void rsp_ClosureSetGlobal (Context *, const void *); 1007 void rsp_ScriptBindAllocation (Context *, const void *); 1008 void rsp_ScriptSetTimeZone (Context *, const void *); 1009 void rsp_ScriptInvokeIDCreate (Context *, const void *); 1010 void rsp_ScriptInvoke (Context *, const void *); 1011 void rsp_ScriptInvokeV (Context *, const void *); 1012 void rsp_ScriptForEach (Context *, const void *); 1013 void rsp_ScriptForEachMulti (Context *, const void *); 1014 void rsp_ScriptReduce (Context *, const void *); 1015 void rsp_ScriptSetVarI (Context *, const void *); 1016 void rsp_ScriptSetVarObj (Context *, const void *); 1017 void rsp_ScriptSetVarJ (Context *, const void *); 1018 void rsp_ScriptSetVarF (Context *, const void *); 1019 void rsp_ScriptSetVarD (Context *, const void *); 1020 void rsp_ScriptSetVarV (Context *, const void *); 1021 void rsp_ScriptGetVarV (Context *, const void *); 1022 void rsp_ScriptSetVarVE (Context *, const void *); 1023 void rsp_ScriptCCreate (Context *, const void *); 1024 void rsp_ScriptIntrinsicCreate (Context *, const void *); 1025 void rsp_ScriptGroupSetOutput (Context *, const void *); 1026 void rsp_ScriptGroupSetInput (Context *, const void *); 1027 void rsp_ScriptGroupExecute (Context *, const void *); 1028 void rsp_AllocationIoSend (Context *, const void *); 1029 void rsp_AllocationIoReceive (Context *, const void *); 1030 void rsp_ProgramBindConstants (Context *, const void *); 1031 void rsp_ProgramBindTexture (Context *, const void *); 1032 void rsp_ProgramBindSampler (Context *, const void *); 1033 void rsp_FontCreateFromFile (Context *, const void *); 1034 void rsp_FontCreateFromMemory (Context *, const void *); 1035 void rsp_MeshCreate (Context *, const void *); 1036 void rsp_ContextBindProgramStore (Context *, const void *); 1037 void rsp_ContextBindProgramFragment (Context *, const void *); 1038 void rsp_ContextBindProgramVertex (Context *, const void *); 1039 void rsp_ContextBindProgramRaster (Context *, const void *); 1040 void rsp_ContextBindFont (Context *, const void *); 1041 void rsp_ContextSetSurface (Context *, const void *); 1042 void rsp_ContextBindRootScript (Context *, const void *); 1043 void rsp_ContextPause (Context *, const void *); 1044 void rsp_ContextResume (Context *, const void *); 1045 typedef void (*RsPlaybackLocalFunc)(Context *, const void *, size_t sizeBytes); 1046 extern RsPlaybackLocalFunc gPlaybackFuncs[95]; 1047 } 1048 } 1049