/frameworks/rs/driver/ |
D | rsdAllocation.cpp | 84 uint8_t *GetOffsetPtr(const android::renderscript::Allocation *alloc, in GetOffsetPtr() argument 87 uint8_t *ptr = (uint8_t *)alloc->mHal.drvState.lod[lod].mallocPtr; in GetOffsetPtr() 88 ptr += face * alloc->mHal.drvState.faceOffset; in GetOffsetPtr() 89 ptr += zoff * alloc->mHal.drvState.lod[lod].dimY * alloc->mHal.drvState.lod[lod].stride; in GetOffsetPtr() 90 ptr += yoff * alloc->mHal.drvState.lod[lod].stride; in GetOffsetPtr() 91 ptr += xoff * alloc->mHal.state.elementSizeBytes; in GetOffsetPtr() 96 static void Update2DTexture(const Context *rsc, const Allocation *alloc, const void *ptr, in Update2DTexture() argument 100 DrvAllocation *drv = (DrvAllocation *)alloc->mHal.drv; in Update2DTexture() 106 if (alloc->mHal.state.hasFaces) { in Update2DTexture() 115 static void Upload2DTexture(const Context *rsc, const Allocation *alloc, bool isFirstUpload) { in Upload2DTexture() argument [all …]
|
D | rsdAllocation.h | 81 android::renderscript::Allocation *alloc); 83 android::renderscript::Allocation *alloc, 87 android::renderscript::Allocation *alloc, 91 android::renderscript::Allocation *alloc); 93 android::renderscript::Allocation *alloc); 96 const android::renderscript::Allocation *alloc, 99 const android::renderscript::Allocation *alloc, 102 const android::renderscript::Allocation *alloc); 104 android::renderscript::Allocation *alloc, ANativeWindow *nw); 106 android::renderscript::Allocation *alloc); [all …]
|
D | rsdMeshObj.cpp | 140 const Allocation *alloc = mRSMesh->mHal.state.vertexBuffers[ct]; in renderPrimitiveRange() local 141 DrvAllocation *drv = (DrvAllocation *)alloc->mHal.drv; in renderPrimitiveRange() 143 rsdAllocationSyncAll(rsc, alloc, RS_ALLOCATION_USAGE_SCRIPT); in renderPrimitiveRange() 150 Allocation *alloc = mRSMesh->mHal.state.vertexBuffers[allocIndex]; in renderPrimitiveRange() local 151 DrvAllocation *drvAlloc = (DrvAllocation *)alloc->mHal.drv; in renderPrimitiveRange() 158 mAttribs[ct].ptr = (const uint8_t*)alloc->mHal.drvState.lod[0].mallocPtr; in renderPrimitiveRange()
|
/frameworks/rs/rsov/driver/ |
D | rsovAllocation.cpp | 82 size_t AllocationBuildPointerTable(const Context *rsc, const Allocation *alloc, in AllocationBuildPointerTable() argument 85 alloc->mHal.drvState.lod[0].dimX = type->getDimX(); in AllocationBuildPointerTable() 86 alloc->mHal.drvState.lod[0].dimY = type->getDimY(); in AllocationBuildPointerTable() 87 alloc->mHal.drvState.lod[0].dimZ = type->getDimZ(); in AllocationBuildPointerTable() 88 alloc->mHal.drvState.lod[0].mallocPtr = 0; in AllocationBuildPointerTable() 91 alloc->mHal.drvState.lod[0].dimX * type->getElementSizeBytes(); in AllocationBuildPointerTable() 92 alloc->mHal.drvState.lod[0].stride = rsRound(stride, requiredAlignment); in AllocationBuildPointerTable() 93 alloc->mHal.drvState.lodCount = type->getLODCount(); in AllocationBuildPointerTable() 94 alloc->mHal.drvState.faceCount = type->getDimFaces(); in AllocationBuildPointerTable() 99 size_t o = alloc->mHal.drvState.lod[0].stride * in AllocationBuildPointerTable() [all …]
|
D | rsovAllocation.h | 82 android::renderscript::Allocation *alloc, 86 android::renderscript::Allocation *alloc); 89 const android::renderscript::Allocation *alloc, 94 const android::renderscript::Allocation *alloc, 101 const android::renderscript::Allocation *alloc, 108 const android::renderscript::Allocation *alloc, 113 const android::renderscript::Allocation *alloc, 120 const android::renderscript::Allocation *alloc, 128 const android::renderscript::Allocation *alloc); 132 const android::renderscript::Allocation *alloc); [all …]
|
/frameworks/rs/support/jni/ |
D | android_rscompat_usage_io_driver.cpp | 15 static bool IoGetBuffer(const Context *rsc, Allocation *alloc, ANativeWindow *nw) { in IoGetBuffer() argument 16 DrvAllocation *drv = (DrvAllocation *)alloc->mHal.drv; in IoGetBuffer() 28 alloc->mHal.drvState.lod[0].mallocPtr = dst; in IoGetBuffer() 29 … alloc->mHal.drvState.lod[0].stride = drv->wndBuffer->stride * alloc->mHal.state.elementSizeBytes; in IoGetBuffer() 35 Allocation *alloc = (Allocation *)allocR; in rscAllocationSetSurface() local 36 DrvAllocation *drv = (DrvAllocation *)alloc->mHal.drv; in rscAllocationSetSurface() 49 r = ANativeWindow_setBuffersGeometry(nw, alloc->mHal.drvState.lod[0].dimX, in rscAllocationSetSurface() 50 alloc->mHal.drvState.lod[0].dimY, in rscAllocationSetSurface() 57 IoGetBuffer(rsc, alloc, nw); in rscAllocationSetSurface() 71 extern "C" void rscAllocationDestroy(const Context *rsc, Allocation *alloc) { in rscAllocationDestroy() argument [all …]
|
D | android_rscompat_usage_io.cpp | 9 extern "C" void AllocationSetSurface(JNIEnv *_env, jobject _this, RsContext con, RsAllocation alloc… in AllocationSetSurface() argument 12 con, alloc, sur); in AllocationSetSurface() 18 dispatchTab.AllocationSetSurface(con, alloc, s); in AllocationSetSurface()
|
/frameworks/rs/tests/java_api/RSTest_CompatLibLegacy/src/com/android/rs/test/ |
D | UT_alloc_copyPadded.java | 93 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in testAllocation_Byte3_1D() local 94 alloc.setAutoPadding(true); in testAllocation_Byte3_1D() 95 alloc.copyFrom(inArray); in testAllocation_Byte3_1D() 96 alloc.copyTo(outArray); in testAllocation_Byte3_1D() 125 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in testAllocation_Byte3_2D() local 126 alloc.setAutoPadding(true); in testAllocation_Byte3_2D() 127 alloc.copyFrom(inArray); in testAllocation_Byte3_2D() 128 alloc.copyTo(outArray); in testAllocation_Byte3_2D() 158 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in testAllocation_Byte3_3D() local 159 alloc.setAutoPadding(true); in testAllocation_Byte3_3D() [all …]
|
D | UT_alloc_copy.java | 68 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in allocation_copy1DRangeTo_Byte() local 71 alloc.copy1DRangeFrom(offset, count, inArray); in allocation_copy1DRangeTo_Byte() 72 alloc.copy1DRangeTo(offset, count, outArray); in allocation_copy1DRangeTo_Byte() 110 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in allocation_copy1DRangeTo_Short() local 113 alloc.copy1DRangeFrom(offset, count, inArray); in allocation_copy1DRangeTo_Short() 114 alloc.copy1DRangeTo(offset, count, outArray); in allocation_copy1DRangeTo_Short() 152 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in allocation_copy1DRangeTo_Int() local 155 alloc.copy1DRangeFrom(offset, count, inArray); in allocation_copy1DRangeTo_Int() 156 alloc.copy1DRangeTo(offset, count, outArray); in allocation_copy1DRangeTo_Int() 194 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in allocation_copy1DRangeTo_Float() local [all …]
|
/frameworks/rs/tests/java_api/RSTest_CompatLib/src/com/android/rs/test/ |
D | UT_alloc_copyPadded.java | 93 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in testAllocation_Byte3_1D() local 94 alloc.setAutoPadding(true); in testAllocation_Byte3_1D() 95 alloc.copyFrom(inArray); in testAllocation_Byte3_1D() 96 alloc.copyTo(outArray); in testAllocation_Byte3_1D() 125 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in testAllocation_Byte3_2D() local 126 alloc.setAutoPadding(true); in testAllocation_Byte3_2D() 127 alloc.copyFrom(inArray); in testAllocation_Byte3_2D() 128 alloc.copyTo(outArray); in testAllocation_Byte3_2D() 158 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in testAllocation_Byte3_3D() local 159 alloc.setAutoPadding(true); in testAllocation_Byte3_3D() [all …]
|
D | UT_alloc_copy.java | 68 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in allocation_copy1DRangeTo_Byte() local 71 alloc.copy1DRangeFrom(offset, count, inArray); in allocation_copy1DRangeTo_Byte() 72 alloc.copy1DRangeTo(offset, count, outArray); in allocation_copy1DRangeTo_Byte() 110 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in allocation_copy1DRangeTo_Short() local 113 alloc.copy1DRangeFrom(offset, count, inArray); in allocation_copy1DRangeTo_Short() 114 alloc.copy1DRangeTo(offset, count, outArray); in allocation_copy1DRangeTo_Short() 152 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in allocation_copy1DRangeTo_Int() local 155 alloc.copy1DRangeFrom(offset, count, inArray); in allocation_copy1DRangeTo_Int() 156 alloc.copy1DRangeTo(offset, count, outArray); in allocation_copy1DRangeTo_Int() 194 Allocation alloc = Allocation.createTyped(mRS, typeBuilder.create()); in allocation_copy1DRangeTo_Float() local [all …]
|
/frameworks/rs/tests/java_api/RsTest/src/com/android/rs/test/ |
D | UT_fp16.java | 30 private Allocation alloc; field in UT_fp16 50 alloc = Allocation.createTyped(RS, type); in initializeGlobals() 55 s.set_gAlloc(alloc); in initializeGlobals() 62 s.forEach_set_kernel_half(alloc); in TestHalf() 66 alloc.destroy(); in TestHalf() 72 s.forEach_verify_kernel_half(alloc); in TestHalf() 75 alloc.destroy(); in TestHalf() 83 s.forEach_set_kernel_half2(alloc); in TestHalf2() 87 alloc.destroy(); in TestHalf2() 93 s.forEach_verify_kernel_half2(alloc); in TestHalf2() [all …]
|
/frameworks/rs/driver/runtime/ |
D | rs_allocation.c | 7 Allocation_t *alloc = (Allocation_t *)a.p; in rsAllocationGetDimX() local 8 return alloc->mHal.drvState.lod[0].dimX; in rsAllocationGetDimX() 13 Allocation_t *alloc = (Allocation_t *)a.p; in rsAllocationGetDimY() local 14 return alloc->mHal.drvState.lod[0].dimY; in rsAllocationGetDimY() 19 Allocation_t *alloc = (Allocation_t *)a.p; in rsAllocationGetDimZ() local 20 return alloc->mHal.drvState.lod[0].dimZ; in rsAllocationGetDimZ() 25 Allocation_t *alloc = (Allocation_t *)a.p; in rsAllocationGetDimLOD() local 26 return alloc->mHal.state.hasMipmaps; in rsAllocationGetDimLOD() 31 Allocation_t *alloc = (Allocation_t *)a.p; in rsAllocationGetDimFaces() local 32 return alloc->mHal.state.hasFaces; in rsAllocationGetDimFaces() [all …]
|
D | rs_sample.c | 268 getBilinearSample1D(const Allocation_t *alloc, float2 weights, in getBilinearSample1D() argument 272 const uint8_t *p = (const uint8_t *)alloc->mHal.drvState.lod[lod].mallocPtr; in getBilinearSample1D() 318 getBilinearSample2D(const Allocation_t *alloc, float w0, float w1, float w2, float w3, in getBilinearSample2D() argument 322 const uint8_t *p = (const uint8_t *)alloc->mHal.drvState.lod[lod].mallocPtr; in getBilinearSample2D() 323 size_t stride = alloc->mHal.drvState.lod[lod].stride; in getBilinearSample2D() 348 getNearestSample(const Allocation_t *alloc, uint32_t iPixel, rs_data_kind dk, in getNearestSample() argument 351 const uint8_t *p = (const uint8_t *)alloc->mHal.drvState.lod[lod].mallocPtr; in getNearestSample() 385 getNearestSample(const Allocation_t *alloc, uint2 iPixel, rs_data_kind dk, in getNearestSample() argument 388 const uint8_t *p = (const uint8_t *)alloc->mHal.drvState.lod[lod].mallocPtr; in getNearestSample() 389 size_t stride = alloc->mHal.drvState.lod[lod].stride; in getNearestSample() [all …]
|
/frameworks/rs/ |
D | rs_hal.h | 221 bool (*init)(const Context *rsc, Allocation *alloc, bool forceZero); 222 bool (*initOem)(const Context *rsc, Allocation *alloc, bool forceZero, void *usrPtr); 223 bool (*initAdapter)(const Context *rsc, Allocation *alloc); 224 void (*destroy)(const Context *rsc, Allocation *alloc); 225 uint32_t (*grallocBits)(const Context *rsc, Allocation *alloc); 227 void (*resize)(const Context *rsc, const Allocation *alloc, const Type *newType, 229 void (*syncAll)(const Context *rsc, const Allocation *alloc, RsAllocationUsageType src); 230 void (*markDirty)(const Context *rsc, const Allocation *alloc); 232 void (*setSurface)(const Context *rsc, Allocation *alloc, ANativeWindow *sur); 233 void (*ioSend)(const Context *rsc, Allocation *alloc); [all …]
|
D | rsAllocation.cpp | 42 Allocation::Allocation(Context *rsc, const Allocation *alloc, const Type *type) in Allocation() argument 46 mHal.state.baseAlloc = alloc; in Allocation() 47 mHal.state.usageFlags = alloc->mHal.state.usageFlags; in Allocation() 106 Allocation * Allocation::createAdapter(Context *rsc, const Allocation *alloc, const Type *type) { in createAdapter() argument 115 Allocation *a = new (allocMem) Allocation(rsc, alloc, type); in createAdapter() 483 Allocation *alloc = Allocation::createAllocation(rsc, type, RS_ALLOCATION_USAGE_SCRIPT); in createFromStream() local 489 uint32_t packedSize = alloc->getPackedSize(); in createFromStream() 494 ObjectBase::checkDelete(alloc); in createFromStream() 499 alloc->assignName(name); in createFromStream() 503 alloc->data(rsc, 0, 0, count, stream->getPtr() + stream->getPos(), dataSize); in createFromStream() [all …]
|
D | rsProgram.cpp | 152 void Program::bindAllocation(Context *rsc, Allocation *alloc, uint32_t slot) { in bindAllocation() argument 153 if (alloc != nullptr) { in bindAllocation() 160 if (alloc->getType() != mConstantTypes[slot].get()) { in bindAllocation() 167 if (mConstants[slot].get() == alloc) { in bindAllocation() 173 mConstants[slot].set(alloc); in bindAllocation() 174 mHal.state.constants[slot] = alloc; in bindAllocation() 175 if (alloc) { in bindAllocation() 176 alloc->addProgramToDirty(this); in bindAllocation()
|
/frameworks/rs/cpu_ref/ |
D | rsCpuIntrinsicYuvToRGB.cpp | 44 ObjectBaseRef<Allocation> alloc; member in android::renderscript::RsdCpuScriptIntrinsicYuvToRGB 54 alloc.set(static_cast<Allocation *>(data)); in setGlobalObj() 102 if (!cp->alloc.get()) { in kernel() 106 const uchar *pinY = (const uchar *)cp->alloc->mHal.drvState.lod[0].mallocPtr; in kernel() 112 size_t strideY = cp->alloc->mHal.drvState.lod[0].stride; in kernel() 115 if (cp->alloc->mHal.drvState.lod[0].dimY == 0) { in kernel() 124 size_t cstep = cp->alloc->mHal.drvState.yuv.step; in kernel() 126 const uchar *pinU = (const uchar *)cp->alloc->mHal.drvState.lod[1].mallocPtr; in kernel() 127 const size_t strideU = cp->alloc->mHal.drvState.lod[1].stride; in kernel() 130 const uchar *pinV = (const uchar *)cp->alloc->mHal.drvState.lod[2].mallocPtr; in kernel() [all …]
|
/frameworks/rs/tests/lldb/java/Reduction/src/com/android/rs/lldbreductiontest/ |
D | MainActivity.java | 66 RenderScript rs, ScriptC_reduce_auto_comb s, Allocation alloc) { in findMinUserTypeAutoComb() argument 71 return s.reduce_find_min_user_type_auto_comb(alloc).get(); in findMinUserTypeAutoComb() 74 private float findMinUserType(RenderScript rs, ScriptC_reduce s, Allocation alloc) { in findMinUserType() argument 79 return s.reduce_find_min_user_type(alloc).get(); in findMinUserType() 91 Allocation alloc = minUserType.getAllocation(); in findMinUserType1DAutoComb() local 93 return findMinUserTypeAutoComb(rs, s, alloc); in findMinUserType1DAutoComb() 105 Allocation alloc = minUserType.getAllocation(); in findMinUserType1D() local 107 return findMinUserType(rs, s, alloc); in findMinUserType1D()
|
/frameworks/base/libs/hwui/ |
D | RecordingCanvas.cpp | 96 addOp(alloc().create_trivial<EndLayerOp>()); in onSnapshotRestored() 98 addOp(alloc().create_trivial<EndUnclippedLayerOp>()); in onSnapshotRestored() 167 if (addOp(alloc().create_trivial<BeginLayerOp>( in saveLayer() 183 if (addOp(alloc().create_trivial<BeginUnclippedLayerOp>( in saveLayer() 248 addOp(alloc().create_trivial<ColorOp>( in drawColor() 274 addOp(alloc().create_trivial<PointsOp>( in drawPoints() 285 addOp(alloc().create_trivial<LinesOp>( in drawLines() 295 addOp(alloc().create_trivial<RectOp>( in drawRect() 328 addOp(alloc().create_trivial<SimpleRectsOp>( in drawSimpleRects() 368 addOp(alloc().create_trivial<RoundRectOp>( in drawRoundRect() [all …]
|
/frameworks/rs/support/java/src/android/support/v8/renderscript/ |
D | RenderScript.java | 409 native void rsnAllocationCopyToBitmap(long con, long alloc, Bitmap bmp); in rsnAllocationCopyToBitmap() argument 410 synchronized void nAllocationCopyToBitmap(long alloc, Bitmap bmp) { in nAllocationCopyToBitmap() argument 412 rsnAllocationCopyToBitmap(mContext, alloc, bmp); in nAllocationCopyToBitmap() 416 native void rsnAllocationSyncAll(long con, long alloc, int src); in rsnAllocationSyncAll() argument 417 synchronized void nAllocationSyncAll(long alloc, int src) { in nAllocationSyncAll() argument 419 rsnAllocationSyncAll(mContext, alloc, src); in nAllocationSyncAll() 422 native void rsnAllocationSetSurface(long con, long alloc, Surface sur); in rsnAllocationSetSurface() argument 423 synchronized void nAllocationSetSurface(long alloc, Surface sur) { in nAllocationSetSurface() argument 425 rsnAllocationSetSurface(mContext, alloc, sur); in nAllocationSetSurface() 428 native void rsnAllocationIoSend(long con, long alloc); in rsnAllocationIoSend() argument [all …]
|
/frameworks/base/rs/java/android/renderscript/ |
D | RenderScript.java | 474 native void rsnAllocationCopyToBitmap(long con, long alloc, Bitmap bmp); in rsnAllocationCopyToBitmap() argument 475 synchronized void nAllocationCopyToBitmap(long alloc, Bitmap bmp) { in nAllocationCopyToBitmap() argument 477 rsnAllocationCopyToBitmap(mContext, alloc, bmp); in nAllocationCopyToBitmap() 480 native void rsnAllocationSyncAll(long con, long alloc, int src); in rsnAllocationSyncAll() argument 481 synchronized void nAllocationSyncAll(long alloc, int src) { in nAllocationSyncAll() argument 483 rsnAllocationSyncAll(mContext, alloc, src); in nAllocationSyncAll() 486 …native ByteBuffer rsnAllocationGetByteBuffer(long con, long alloc, long[] stride, int xBytesSize, … in rsnAllocationGetByteBuffer() argument 487 …synchronized ByteBuffer nAllocationGetByteBuffer(long alloc, long[] stride, int xBytesSize, int di… in nAllocationGetByteBuffer() argument 489 return rsnAllocationGetByteBuffer(mContext, alloc, stride, xBytesSize, dimY, dimZ); in nAllocationGetByteBuffer() 492 native void rsnAllocationSetupBufferQueue(long con, long alloc, int numAlloc); in rsnAllocationSetupBufferQueue() argument [all …]
|
D | Mesh.java | 361 Allocation alloc = null; in create() local 364 alloc = Allocation.createTyped(mRS, entry.t, mUsage); in create() 366 alloc = Allocation.createSized(mRS, entry.e, entry.size, mUsage); in create() 371 vertexBuffers[ct] = alloc; in create() 372 vtx[ct] = alloc.getID(mRS); in create() 376 Allocation alloc = null; in create() local 379 alloc = Allocation.createTyped(mRS, entry.t, mUsage); in create() 381 alloc = Allocation.createSized(mRS, entry.e, entry.size, mUsage); in create() 386 long allocID = (alloc == null) ? 0 : alloc.getID(mRS); in create() 387 indexBuffers[ct] = alloc; in create()
|
/frameworks/base/libs/hwui/tests/unit/ |
D | LinearAllocatorTests.cpp | 33 la.alloc<char>(64); in TEST() 53 la.alloc<char>(100); in TEST() 58 la.alloc<char>(100); in TEST() 72 auto addr = la.alloc<char>(100); in TEST()
|
/frameworks/base/rs/jni/ |
D | android_renderscript_RenderScript.cpp | 1239 nAllocationSetupBufferQueue(JNIEnv *_env, jobject _this, jlong con, jlong alloc, jint numAlloc) in nAllocationSetupBufferQueue() argument 1243 (RsAllocation)alloc, numAlloc); in nAllocationSetupBufferQueue() 1245 rsAllocationSetupBufferQueue((RsContext)con, (RsAllocation)alloc, (uint32_t)numAlloc); in nAllocationSetupBufferQueue() 1276 nAllocationSetSurface(JNIEnv *_env, jobject _this, jlong con, jlong alloc, jobject sur) in nAllocationSetSurface() argument 1280 (RsAllocation)alloc, (Surface *)sur); in nAllocationSetSurface() 1290 rsAllocationSetSurface((RsContext)con, (RsAllocation)alloc, anw); in nAllocationSetSurface() 1294 nAllocationIoSend(JNIEnv *_env, jobject _this, jlong con, jlong alloc) in nAllocationIoSend() argument 1297 ALOGD("nAllocationIoSend, con(%p), alloc(%p)", (RsContext)con, (RsAllocation)alloc); in nAllocationIoSend() 1299 rsAllocationIoSend((RsContext)con, (RsAllocation)alloc); in nAllocationIoSend() 1303 nAllocationIoReceive(JNIEnv *_env, jobject _this, jlong con, jlong alloc) in nAllocationIoReceive() argument [all …]
|