summaryrefslogtreecommitdiff
path: root/rsAllocation.cpp
diff options
context:
space:
mode:
authorJason Sams <jsams@google.com>2015-05-18 17:28:59 -0700
committerJason Sams <jsams@google.com>2015-05-18 17:28:59 -0700
commitfa578a3a3404bafaae1ac23164a563a70e00fd44 (patch)
tree256e409c31ed15ec3b1747084b450e24b89faeac /rsAllocation.cpp
parent874ed8dee9ab7118efb517f6a8a9c1758818fd4c (diff)
downloadrs-fa578a3a3404bafaae1ac23164a563a70e00fd44.tar.gz
Notify drivers when user get a pointer to allocation
Requested by vendor for driver bring-up. bug 20894664 Change-Id: I7a1540236e557ef42ffde1c832b5d5ef36b91c96
Diffstat (limited to 'rsAllocation.cpp')
-rw-r--r--rsAllocation.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/rsAllocation.cpp b/rsAllocation.cpp
index a7601a46..3bdbf7b9 100644
--- a/rsAllocation.cpp
+++ b/rsAllocation.cpp
@@ -167,8 +167,12 @@ void * Allocation::getPointer(const Context *rsc, uint32_t lod, RsAllocationCube
return nullptr;
}
+ if (mRSC->mHal.funcs.allocation.getPointer != nullptr) {
+ // Notify the driver, if present that the user is mapping the buffer
+ mRSC->mHal.funcs.allocation.getPointer(rsc, this, lod, face, z, array);
+ }
+
size_t s = 0;
- //void *ptr = mRSC->mHal.funcs.allocation.lock1D(rsc, this);
if ((stride != nullptr) && mHal.drvState.lod[0].dimY) {
*stride = mHal.drvState.lod[lod].stride;
}