/frameworks/rs/ |
D | rsProgram.cpp | 30 mHal.state.inputElementsCount++; in Program() 33 mHal.state.constantsCount++; in Program() 36 mHal.state.texturesCount++; in Program() 40 mTextures = new ObjectBaseRef<Allocation>[mHal.state.texturesCount]; in Program() 41 mSamplers = new ObjectBaseRef<Sampler>[mHal.state.texturesCount]; in Program() 42 mInputElements = new ObjectBaseRef<Element>[mHal.state.inputElementsCount]; in Program() 43 mConstantTypes = new ObjectBaseRef<Type>[mHal.state.constantsCount]; in Program() 44 mConstants = new ObjectBaseRef<Allocation>[mHal.state.constantsCount]; in Program() 46 mHal.state.textures = new Allocation*[mHal.state.texturesCount]; in Program() 47 mHal.state.samplers = new Sampler*[mHal.state.texturesCount]; in Program() [all …]
|
D | rsType.cpp | 23 memset(&mHal, 0, sizeof(mHal)); in Type() 41 if (mHal.state.lodCount) { in clear() 42 delete [] mHal.state.lodDimX; in clear() 43 delete [] mHal.state.lodDimY; in clear() 44 delete [] mHal.state.lodDimZ; in clear() 45 delete [] mHal.state.lodOffset; in clear() 48 memset(&mHal, 0, sizeof(mHal)); in clear() 59 rsAssert(mHal.state.faces); in getOffsetForFace() 64 uint32_t oldLODCount = mHal.state.lodCount; in compute() 66 uint32_t l2x = rsFindHighBit(mHal.state.dimX) + 1; in compute() [all …]
|
D | rsMesh.cpp | 25 mHal.drv = NULL; in Mesh() 26 mHal.state.primitives = NULL; in Mesh() 27 mHal.state.primitivesCount = 0; in Mesh() 28 mHal.state.indexBuffers = NULL; in Mesh() 29 mHal.state.indexBuffersCount = 0; in Mesh() 30 mHal.state.vertexBuffers = NULL; in Mesh() 31 mHal.state.vertexBuffersCount = 0; in Mesh() 41 mHal.drv = NULL; in Mesh() 42 mHal.state.primitivesCount = primitivesCount; in Mesh() 43 mHal.state.indexBuffersCount = primitivesCount; in Mesh() [all …]
|
D | rsProgramStore.cpp | 29 memset(&mHal, 0, sizeof(mHal)); in ProgramStore() 31 mHal.state.ditherEnable = ditherEnable; in ProgramStore() 33 mHal.state.colorRWriteEnable = colorMaskR; in ProgramStore() 34 mHal.state.colorGWriteEnable = colorMaskG; in ProgramStore() 35 mHal.state.colorBWriteEnable = colorMaskB; in ProgramStore() 36 mHal.state.colorAWriteEnable = colorMaskA; in ProgramStore() 37 mHal.state.blendSrc = srcFunc; in ProgramStore() 38 mHal.state.blendDst = destFunc; in ProgramStore() 40 mHal.state.depthWriteEnable = depthMask; in ProgramStore() 41 mHal.state.depthFunc = depthFunc; in ProgramStore() [all …]
|
D | rsFBOCache.cpp | 28 mHal.state.colorTargetsCount = 1; in FBOCache() 29 mHal.state.colorTargets = new Allocation*[mHal.state.colorTargetsCount]; in FBOCache() 30 mColorTargets = new ObjectBaseRef<Allocation>[mHal.state.colorTargetsCount]; in FBOCache() 35 delete[] mHal.state.colorTargets; in ~FBOCache() 40 rsc->mHal.funcs.framebuffer.init(rsc, this); in init() 44 rsc->mHal.funcs.framebuffer.destroy(rsc, this); in deinit() 48 if (slot >= mHal.state.colorTargetsCount) { in bindColorTarget() 53 if (!(a->getIsTexture() || (a->mHal.state.usageFlags & RS_ALLOCATION_USAGE_IO_OUTPUT))) { in bindColorTarget() 59 mHal.state.colorTargets[slot] = a; in bindColorTarget() 71 mHal.state.depthTarget = a; in bindDepthTarget() [all …]
|
D | rsAllocation.cpp | 32 memset(&mHal, 0, sizeof(mHal)); in Allocation() 33 mHal.state.mipmapControl = RS_ALLOCATION_MIPMAP_NONE; in Allocation() 34 mHal.state.usageFlags = usages; in Allocation() 35 mHal.state.mipmapControl = mc; in Allocation() 45 if (!rsc->mHal.funcs.allocation.init(rsc, a, type->getElement()->getHasReferences())) { in createAllocation() 55 const Type *type = mHal.state.type; in updateCache() 56 mHal.state.dimensionX = type->getDimX(); in updateCache() 57 mHal.state.dimensionY = type->getDimY(); in updateCache() 58 mHal.state.dimensionZ = type->getDimZ(); in updateCache() 59 mHal.state.hasFaces = type->getDimFaces(); in updateCache() [all …]
|
D | rsSampler.cpp | 37 mHal.state.magFilter = magFilter; in Sampler() 38 mHal.state.minFilter = minFilter; in Sampler() 39 mHal.state.wrapS = wrapS; in Sampler() 40 mHal.state.wrapT = wrapT; in Sampler() 41 mHal.state.wrapR = wrapR; in Sampler() 42 mHal.state.aniso = aniso; in Sampler() 44 mRSC->mHal.funcs.sampler.init(mRSC, this); in Sampler() 48 mRSC->mHal.funcs.sampler.destroy(mRSC, this); in ~Sampler() 89 if (existing->mHal.state.magFilter != magFilter) continue; in getSampler() 90 if (existing->mHal.state.minFilter != minFilter ) continue; in getSampler() [all …]
|
D | rsType.h | 56 Hal mHal; variable 66 uint32_t getDimX() const {return mHal.state.dimX;} in getDimX() 67 uint32_t getDimY() const {return mHal.state.dimY;} in getDimY() 68 uint32_t getDimZ() const {return mHal.state.dimZ;} in getDimZ() 70 bool getDimFaces() const {return mHal.state.faces;} in getDimFaces() 73 rsAssert(lod < mHal.state.lodCount); in getLODDimX() 74 return mHal.state.lodDimX[lod]; in getLODDimX() 77 rsAssert(lod < mHal.state.lodCount); in getLODDimY() 78 return mHal.state.lodDimY[lod]; in getLODDimY() 81 rsAssert(lod < mHal.state.lodCount); in getLODDimZ() [all …]
|
D | rsScriptC.cpp | 49 mRSC->mHal.funcs.script.invokeFreeChildren(mRSC, this); in ~ScriptC() 50 mRSC->mHal.funcs.script.destroy(mRSC, this); in ~ScriptC() 58 for (uint32_t ct=0; ct < mHal.info.exportedVariableCount; ct++) { in setupScript() 70 rsc->mHal.funcs.script.setGlobalBind(rsc, this, ct, ptr); in setupScript() 79 for (uint32_t ct=0; ct < mHal.info.exportedVariableCount; ct++) { in ptrToAllocation() 106 if (mHal.info.root == NULL) { in run() 117 ALOGV("%p ScriptC::run invoking root, ptr %p", rsc, mHal.info.root); in run() 120 ret = rsc->mHal.funcs.script.invokeRoot(rsc, this); in run() 142 rsc->mHal.funcs.script.invokeForEach(rsc, this, slot, ain, aout, usr, usrBytes, sc); in runForEach() 146 if (slot >= mHal.info.exportedFunctionCount) { in Invoke() [all …]
|
D | rsProgramRaster.cpp | 27 memset(&mHal, 0, sizeof(mHal)); in ProgramRaster() 28 mHal.state.pointSprite = pointSprite; in ProgramRaster() 29 mHal.state.cull = cull; in ProgramRaster() 30 rsc->mHal.funcs.raster.init(rsc, this); in ProgramRaster() 43 mRSC->mHal.funcs.raster.destroy(mRSC, this); in ~ProgramRaster() 53 rsc->mHal.funcs.raster.setActive(rsc, this); in setup() 85 if (existing->mHal.state.pointSprite != pointSprite) continue; in getProgramRaster() 86 if (existing->mHal.state.cull != cull) continue; in getProgramRaster()
|
D | rsProgramVertex.cpp | 30 mRSC->mHal.funcs.vertex.init(mRSC, this, mUserShader.string(), mUserShader.length(), in ProgramVertex() 35 mRSC->mHal.funcs.vertex.destroy(mRSC, this); in ~ProgramVertex() 44 if (mHal.state.constants[0] == NULL) { in setup() 49 float *f = static_cast<float *>(mHal.state.constants[0]->getPtr()); in setup() 62 rsc->mHal.funcs.vertex.setActive(rsc, this); in setup() 71 if (mHal.state.constants[0] == NULL) { in setProjectionMatrix() 76 float *f = static_cast<float *>(mHal.state.constants[0]->getPtr()); in setProjectionMatrix() 87 if (mHal.state.constants[0] == NULL) { in setModelviewMatrix() 92 float *f = static_cast<float *>(mHal.state.constants[0]->getPtr()); in setModelviewMatrix() 103 if (mHal.state.constants[0] == NULL) { in setTextureMatrix() [all …]
|
D | rsElement.cpp | 30 memset(&mHal, 0, sizeof(mHal)); in Element() 52 delete [] mHal.state.fields; in clear() 53 delete [] mHal.state.fieldArraySizes; in clear() 54 delete [] mHal.state.fieldNames; in clear() 55 delete [] mHal.state.fieldNameLengths; in clear() 56 delete [] mHal.state.fieldOffsetBytes; in clear() 167 mHal.state.dataType = mComponent.getType(); in compute() 168 mHal.state.dataKind = mComponent.getKind(); in compute() 169 mHal.state.vectorSize = mComponent.getVectorSize(); in compute() 176 mHal.state.elementSizeBytes = getSizeBytes(); in compute() [all …]
|
D | rsScript.cpp | 25 memset(&mHal, 0, sizeof(mHal)); in Script() 45 if (slot >= mHal.info.exportedVariableCount) { in setSlot() 52 mRSC->mHal.funcs.script.setGlobalBind(mRSC, this, slot, a->getPtr()); in setSlot() 54 mRSC->mHal.funcs.script.setGlobalBind(mRSC, this, slot, NULL); in setSlot() 60 if (slot >= mHal.info.exportedVariableCount) { in setVar() 64 mRSC->mHal.funcs.script.setGlobalVar(mRSC, this, slot, (void *)val, len); in setVar() 69 if (slot >= mHal.info.exportedVariableCount) { in setVar() 73 mRSC->mHal.funcs.script.setGlobalVarWithElemDims(mRSC, this, slot, in setVar() 79 if (slot >= mHal.info.exportedVariableCount) { in setVarObj() 84 mRSC->mHal.funcs.script.setGlobalObj(mRSC, this, slot, val); in setVarObj() [all …]
|
/frameworks/rs/driver/ |
D | rsdShader.cpp | 81 for (uint32_t ct = 0; ct < mRSProgram->mHal.state.texturesCount; ct ++) { in getExistingState() 83 if (mRSProgram->mHal.state.textureTargets[ct] == RS_TEXTURE_2D) { in getExistingState() 84 Allocation *a = mRSProgram->mHal.state.textures[ct]; in getExistingState() 85 if (a && a->mHal.state.surfaceTextureID) { in getExistingState() 121 for (uint32_t ct=0; ct < mRSProgram->mHal.state.inputElementsCount; ct++) { in init() 122 initAddUserElement(mRSProgram->mHal.state.inputElements[ct], mAttribNames, in init() 125 for (uint32_t ct=0; ct < mRSProgram->mHal.state.constantsCount; ct++) { in init() 126 initAddUserElement(mRSProgram->mHal.state.constantTypes[ct]->getElement(), in init() 131 for (uint32_t ct=0; ct < mRSProgram->mHal.state.texturesCount; ct++) { in init() 141 for (uint32_t ct=0; ct < mRSProgram->mHal.state.inputElementsCount; ct++) { in getGLSLInputString() [all …]
|
D | rsdAllocation.cpp | 85 DrvAllocation *drv = (DrvAllocation *)alloc->mHal.drv; in Update2DTexture() 91 if (alloc->mHal.state.hasFaces) { in Update2DTexture() 99 DrvAllocation *drv = (DrvAllocation *)alloc->mHal.drv; in Upload2DTexture() 105 if (alloc->mHal.state.hasFaces) { in Upload2DTexture() 111 for (uint32_t lod = 0; lod < alloc->mHal.state.type->getLODCount(); lod++) { in Upload2DTexture() 112 const uint8_t *p = (const uint8_t *)alloc->mHal.drvState.mallocPtr; in Upload2DTexture() 113 p += alloc->mHal.state.type->getLODFaceOffset(lod, (RsAllocationCubemapFace)face, 0, 0); in Upload2DTexture() 116 if (alloc->mHal.state.hasFaces) { in Upload2DTexture() 122 alloc->mHal.state.type->getLODDimX(lod), in Upload2DTexture() 123 alloc->mHal.state.type->getLODDimY(lod), in Upload2DTexture() [all …]
|
D | rsdFrameBuffer.cpp | 33 RsdFrameBufferObj *fbo = (RsdFrameBufferObj*)fb->mHal.drv; in setDepthAttachment() 36 if (fb->mHal.state.depthTarget != NULL) { in setDepthAttachment() 37 depth = (DrvAllocation *)fb->mHal.state.depthTarget->mHal.drv; in setDepthAttachment() 40 rsdAllocationSyncAll(rsc, fb->mHal.state.depthTarget, in setDepthAttachment() 48 RsdFrameBufferObj *fbo = (RsdFrameBufferObj*)fb->mHal.drv; in setColorAttachment() 50 for (uint32_t i = 0; i < fb->mHal.state.colorTargetsCount; i ++) { in setColorAttachment() 52 if (fb->mHal.state.colorTargets[i] != NULL) { in setColorAttachment() 53 color = (DrvAllocation *)fb->mHal.state.colorTargets[i]->mHal.drv; in setColorAttachment() 56 rsdAllocationSyncAll(rsc, fb->mHal.state.colorTargets[i], in setColorAttachment() 69 fb->mHal.drv = fbo; in rsdFrameBufferInit() [all …]
|
D | rsdMeshObj.cpp | 55 RsDataType dt = elem->mHal.state.fields[fieldIdx]->mHal.state.dataType; in isValidGLComponent() 63 uint32_t arraySize = elem->mHal.state.fieldArraySizes[fieldIdx]; in isValidGLComponent() 77 for (uint32_t ct=0; ct < mRSMesh->mHal.state.vertexBuffersCount; ct++) { in init() 78 const Element *elem = mRSMesh->mHal.state.vertexBuffers[ct]->getType()->getElement(); in init() 79 for (uint32_t ct=0; ct < elem->mHal.state.fieldsCount; ct++) { in init() 100 for (uint32_t ct=0; ct < mRSMesh->mHal.state.vertexBuffersCount; ct++) { in init() 101 const Element *elem = mRSMesh->mHal.state.vertexBuffers[ct]->getType()->getElement(); in init() 102 uint32_t stride = elem->mHal.state.elementSizeBytes; in init() 103 for (uint32_t fieldI=0; fieldI < elem->mHal.state.fieldsCount; fieldI++) { in init() 104 const Element *f = elem->mHal.state.fields[fieldI]; in init() [all …]
|
D | rsdProgram.cpp | 42 pv->mHal.drv = drv; in rsdProgramVertexInit() 48 for (uint32_t ct=0; ct < p->mHal.state.texturesCount; ct++) { in SyncProgramConstants() 49 const Allocation *a = p->mHal.state.textures[ct]; in SyncProgramConstants() 53 DrvAllocation *drvAlloc = (DrvAllocation *)a->mHal.drv; in SyncProgramConstants() 61 RsdHal *dc = (RsdHal *)rsc->mHal.drv; in rsdProgramVertexSetActive() 64 dc->gl.shaderCache->setActiveVertex((RsdShader*)pv->mHal.drv); in rsdProgramVertexSetActive() 68 RsdHal *dc = (RsdHal *)rsc->mHal.drv; in rsdProgramVertexDestroy() 71 if(pv->mHal.drv) { in rsdProgramVertexDestroy() 72 drv = (RsdShader*)pv->mHal.drv; in rsdProgramVertexDestroy() 89 pf->mHal.drv = drv; in rsdProgramFragmentInit() [all …]
|
D | rsdProgramStore.cpp | 46 ps->mHal.drv = drv; in rsdProgramStoreInit() 49 switch (ps->mHal.state.depthFunc) { in rsdProgramStoreInit() 80 if ((ps->mHal.state.blendSrc == RS_BLEND_SRC_ONE) && in rsdProgramStoreInit() 81 (ps->mHal.state.blendDst == RS_BLEND_DST_ZERO)) { in rsdProgramStoreInit() 85 switch (ps->mHal.state.blendSrc) { in rsdProgramStoreInit() 118 switch (ps->mHal.state.blendDst) { in rsdProgramStoreInit() 152 ps->mHal.drv = NULL; in rsdProgramStoreInit() 157 DrvProgramStore *drv = (DrvProgramStore *)ps->mHal.drv; in rsdProgramStoreSetActive() 159 RSD_CALL_GL(glColorMask, ps->mHal.state.colorRWriteEnable, in rsdProgramStoreSetActive() 160 ps->mHal.state.colorGWriteEnable, in rsdProgramStoreSetActive() [all …]
|
D | rsdMesh.cpp | 32 if(m->mHal.drv) { in rsdMeshInit() 33 drv = (RsdMeshObj*)m->mHal.drv; in rsdMeshInit() 37 m->mHal.drv = drv; in rsdMeshInit() 42 if(m->mHal.drv) { in rsdMeshDraw() 43 RsdHal *dc = (RsdHal *)rsc->mHal.drv; in rsdMeshDraw() 48 RsdMeshObj *drv = (RsdMeshObj*)m->mHal.drv; in rsdMeshDraw() 54 if(m->mHal.drv) { in rsdMeshDestroy() 55 RsdMeshObj *drv = (RsdMeshObj*)m->mHal.drv; in rsdMeshDestroy()
|
/frameworks/compile/libbcc/lib/ScriptCRT/ |
D | rs_allocation.c | 9 return alloc->mHal.state.dimensionX; in rsAllocationGetDimX() 15 return alloc->mHal.state.dimensionY; in rsAllocationGetDimY() 21 return alloc->mHal.state.dimensionZ; in rsAllocationGetDimZ() 27 return alloc->mHal.state.hasMipmaps; in rsAllocationGetDimLOD() 33 return alloc->mHal.state.hasFaces; in rsAllocationGetDimFaces() 39 const uint8_t *p = (const uint8_t *)alloc->mHal.drvState.mallocPtr; in rsGetElementAt() 40 const uint32_t eSize = alloc->mHal.state.elementSizeBytes; in rsGetElementAt() 47 const uint8_t *p = (const uint8_t *)alloc->mHal.drvState.mallocPtr; in rsGetElementAt() 48 const uint32_t eSize = alloc->mHal.state.elementSizeBytes; in rsGetElementAt() 49 const uint32_t stride = alloc->mHal.drvState.stride; in rsGetElementAt() [all …]
|
D | rs_element.c | 14 return element->mHal.state.fieldsCount; in rsElementGetSubElementCount() 20 if (element == NULL || index >= element->mHal.state.fieldsCount) { in rsElementGetSubElement() 24 rs_element returnElem = {element->mHal.state.fields[index]}; in rsElementGetSubElement() 31 if (element == NULL || index >= element->mHal.state.fieldsCount) { in rsElementGetSubElementNameLength() 34 return element->mHal.state.fieldNameLengths[index]; in rsElementGetSubElementNameLength() 40 if (element == NULL || index >= element->mHal.state.fieldsCount || in rsElementGetSubElementName() 45 uint32_t numToCopy = element->mHal.state.fieldNameLengths[index]; in rsElementGetSubElementName() 52 const char *nameSource = element->mHal.state.fieldNames[index]; in rsElementGetSubElementName() 62 if (element == NULL || index >= element->mHal.state.fieldsCount) { in rsElementGetSubElementArraySize() 65 return element->mHal.state.fieldArraySizes[index]; in rsElementGetSubElementArraySize() [all …]
|
D | rs_program.c | 14 return prog->mHal.state.depthFunc; in rsgProgramStoreGetDepthFunc() 23 return prog->mHal.state.depthWriteEnable; in rsgProgramStoreIsDepthMaskEnabled() 32 return prog->mHal.state.colorRWriteEnable; in rsgProgramStoreIsColorMaskRedEnabled() 41 return prog->mHal.state.colorGWriteEnable; in rsgProgramStoreIsColorMaskGreenEnabled() 50 return prog->mHal.state.colorBWriteEnable; in rsgProgramStoreIsColorMaskBlueEnabled() 59 return prog->mHal.state.colorAWriteEnable; in rsgProgramStoreIsColorMaskAlphaEnabled() 68 return prog->mHal.state.blendSrc; in rsgProgramStoreGetBlendSrcFunc() 77 return prog->mHal.state.blendDst; in rsgProgramStoreGetBlendDstFunc() 86 return prog->mHal.state.ditherEnable; in rsgProgramStoreIsDitherEnabled() 98 return prog->mHal.state.pointSprite; in rsgProgramRasterIsPointSpriteEnabled() [all …]
|
D | rs_mesh.c | 14 return mesh->mHal.state.vertexBuffersCount; in rsgMeshGetVertexAllocationCount() 23 return mesh->mHal.state.primitivesCount; in rsgMeshGetPrimitiveCount() 29 if (mesh == NULL || index >= mesh->mHal.state.vertexBuffersCount) { in rsgMeshGetVertexAllocation() 33 rs_allocation returnAlloc = {mesh->mHal.state.vertexBuffers[index]}; in rsgMeshGetVertexAllocation() 40 if (mesh == NULL || index >= mesh->mHal.state.primitivesCount) { in rsgMeshGetIndexAllocation() 44 rs_allocation returnAlloc = {mesh->mHal.state.indexBuffers[index]}; in rsgMeshGetIndexAllocation() 51 if (mesh == NULL || index >= mesh->mHal.state.primitivesCount) { in rsgMeshGetPrimitive() 54 return mesh->mHal.state.primitives[index]; in rsgMeshGetPrimitive()
|
D | rs_structs.h | 52 } mHal; member 86 } mHal; member 113 } mHal; member 144 } mHal; member 182 } mHal; member 218 } mHal; member 252 } mHal; member
|