Lines Matching refs:descriptor
62 auto descriptor = std::make_shared<BufferDescriptor>(); in CreateBufferDescriptor() local
63 descriptors_map_.emplace(descriptor->GetId(), descriptor); in CreateBufferDescriptor()
64 *descriptor_id = descriptor->GetId(); in CreateBufferDescriptor()
71 const auto descriptor = descriptors_map_.find(descriptor_id); in DestroyBufferDescriptor() local
72 if (descriptor == descriptors_map_.end()) { in DestroyBufferDescriptor()
75 descriptors_map_.erase(descriptor); in DestroyBufferDescriptor()
108 for (auto &descriptor : descriptors) { in AllocateBuffers() local
109 descriptor->SetColorFormat(allocator_->GetImplDefinedFormat(descriptor->GetProducerUsage(), in AllocateBuffers()
110 descriptor->GetConsumerUsage(), in AllocateBuffers()
111 descriptor->GetFormat())); in AllocateBuffers()
158 void BufferManager::CreateSharedHandle(buffer_handle_t inbuffer, const BufferDescriptor &descriptor, in CreateSharedHandle() argument
165 allocator_->GetAlignedWidthAndHeight(descriptor, &alignedw, &alignedh); in CreateSharedHandle()
168 int flags = GetHandleFlags(descriptor.GetFormat(), descriptor.GetProducerUsage(), in CreateSharedHandle()
169 descriptor.GetConsumerUsage()); in CreateSharedHandle()
170 int buffer_type = GetBufferType(descriptor.GetFormat()); in CreateSharedHandle()
178 descriptor.GetWidth(), in CreateSharedHandle()
179 descriptor.GetHeight(), in CreateSharedHandle()
180 descriptor.GetFormat(), in CreateSharedHandle()
183 descriptor.GetProducerUsage(), in CreateSharedHandle()
184 descriptor.GetConsumerUsage()); in CreateSharedHandle()
440 int BufferManager::AllocateBuffer(const BufferDescriptor &descriptor, buffer_handle_t *handle, in AllocateBuffer() argument
445 int format = descriptor.GetFormat(); in AllocateBuffer()
446 gralloc1_producer_usage_t prod_usage = descriptor.GetProducerUsage(); in AllocateBuffer()
447 gralloc1_consumer_usage_t cons_usage = descriptor.GetConsumerUsage(); in AllocateBuffer()
448 uint32_t layer_count = descriptor.GetLayerCount(); in AllocateBuffer()
456 allocator_->GetBufferSizeAndDimensions(descriptor, &size, &alignedw, &alignedh); in AllocateBuffer()
497 descriptor.GetWidth(), in AllocateBuffer()
498 descriptor.GetHeight(), in AllocateBuffer()
544 BufferDescriptor descriptor(width, height, format); in Perform() local
545 allocator_->GetAlignedWidthAndHeight(descriptor, &alignedw, &alignedh); in Perform()
560 BufferDescriptor descriptor(width, width, format); in Perform() local
561 allocator_->GetAlignedWidthAndHeight(descriptor, &alignedw, &alignedh); in Perform()
614 BufferDescriptor descriptor(width, height, format, prod_usage, cons_usage); in Perform() local
617 allocator_->GetAlignedWidthAndHeight(descriptor, &alignedw, &alignedh); in Perform()
708 auto descriptor = BufferDescriptor(width, height, format, producer_usage, consumer_usage); in Perform() local
709 allocator_->GetBufferSizeAndDimensions(descriptor, size, aligned_width, aligned_height); in Perform()
723 BufferDescriptor descriptor(width, height, format, producer_usage, consumer_usage); in Perform() local
726 allocator_->GetBufferSizeAndDimensions(descriptor, &size, &alignedw, &alignedh); in Perform()
727 AllocateBuffer(descriptor, hnd, size); in Perform()
840 BufferDescriptor descriptor) { in ValidateBufferSize() argument
842 const int format = allocator_->GetImplDefinedFormat(descriptor.GetProducerUsage(), in ValidateBufferSize()
843 descriptor.GetConsumerUsage(), in ValidateBufferSize()
844 descriptor.GetFormat()); in ValidateBufferSize()
845 descriptor.SetColorFormat(format); in ValidateBufferSize()
846 allocator_->GetBufferSizeAndDimensions(descriptor, &size, &alignedw, &alignedh); in ValidateBufferSize()