Lines Matching refs:handle
26 IonBuffer::IonBuffer(buffer_handle_t handle, uint32_t width, uint32_t height, in IonBuffer() argument
28 : IonBuffer(handle, width, height, kDefaultGraphicBufferLayerCount, stride, in IonBuffer()
31 IonBuffer::IonBuffer(buffer_handle_t handle, uint32_t width, uint32_t height, in IonBuffer() argument
38 handle, width, height, layer_count, stride, format, usage); in IonBuffer()
39 if (handle != 0) { in IonBuffer()
40 Import(handle, width, height, layer_count, stride, format, usage); in IonBuffer()
48 handle(), width(), height(), stride(), format(), usage()); in ~IonBuffer()
57 ALOGD_IF(TRACE, "IonBuffer::operator=: handle_=%p other.handle_=%p", handle(), in operator =()
58 other.handle()); in operator =()
91 void IonBuffer::Reset(buffer_handle_t handle, uint32_t width, uint32_t height, in Reset() argument
97 handle, width, height, layer_count, stride, format, usage); in Reset()
98 Import(handle, width, height, layer_count, stride, format, usage); in Reset()
101 int IonBuffer::Import(buffer_handle_t handle, uint32_t width, uint32_t height, in Import() argument
108 handle, width, height, layer_count, stride, format, usage); in Import()
111 new GraphicBuffer(handle, GraphicBuffer::TAKE_UNREGISTERED_HANDLE, width, in Import()
138 native_handle_t* handle = native_handle_create(fd_count, int_count); in Import() local
139 if (!handle) { in Import()
146 memcpy(handle->data, fd_array, sizeof(int) * fd_count); in Import()
147 memcpy(handle->data + fd_count, int_array, sizeof(int) * int_count); in Import()
150 Import(handle, width, height, layer_count, stride, format, usage); in Import()
154 native_handle_close(handle); in Import()
155 native_handle_delete(handle); in Import()
162 if (!other->handle()) in Duplicate()
165 const int fd_count = other->handle()->numFds; in Duplicate()
166 const int int_count = other->handle()->numInts; in Duplicate()
171 native_handle_t* handle = native_handle_create(fd_count, int_count); in Duplicate() local
172 if (!handle) { in Duplicate()
179 handle->data[i] = dup(other->handle()->data[i]); in Duplicate()
182 memcpy(handle->data + fd_count, other->handle()->data + fd_count, in Duplicate()
186 Import(handle, other->width(), other->height(), other->layer_count(), in Duplicate()
191 native_handle_close(handle); in Duplicate()
192 native_handle_delete(handle); in Duplicate()
204 handle(), usage, x, y, width, height, address); in Lock()
219 handle(), usage, x, y, width, height); in LockYUV()
231 ALOGD_IF(TRACE, "IonBuffer::Unlock: handle=%p", handle()); in Unlock()