Loading media/bufferpool/aidl/aidl_api/android.hardware.media.bufferpool2/current/android/hardware/media/bufferpool2/IClientManager.aidl +1 −0 Original line number Original line Diff line number Diff line Loading @@ -35,6 +35,7 @@ package android.hardware.media.bufferpool2; @VintfStability @VintfStability interface IClientManager { interface IClientManager { android.hardware.media.bufferpool2.IClientManager.Registration registerSender(in android.hardware.media.bufferpool2.IAccessor bufferPool); android.hardware.media.bufferpool2.IClientManager.Registration registerSender(in android.hardware.media.bufferpool2.IAccessor bufferPool); android.hardware.media.bufferpool2.IClientManager.Registration registerPassiveSender(in android.hardware.media.bufferpool2.IAccessor bufferPool); @VintfStability @VintfStability parcelable Registration { parcelable Registration { long connectionId; long connectionId; Loading media/bufferpool/aidl/android/hardware/media/bufferpool2/IClientManager.aidl +19 −1 Original line number Original line Diff line number Diff line Loading @@ -40,7 +40,8 @@ interface IClientManager { /** /** * Sets up a buffer receiving communication node for the specified * Sets up a buffer receiving communication node for the specified * buffer pool. A manager must create a IConnection to the buffer * buffer pool. A manager must create a IConnection to the buffer * pool if it does not already have a connection. * pool if it does not already have a connection. To transfer buffers * using the interface, the sender must initiates transfer. * * * @param bufferPool a buffer pool which is specified with the IAccessor. * @param bufferPool a buffer pool which is specified with the IAccessor. * The specified buffer pool is the owner of received buffers. * The specified buffer pool is the owner of received buffers. Loading @@ -52,4 +53,21 @@ interface IClientManager { * ResultStatus::CRITICAL_ERROR - Other errors. * ResultStatus::CRITICAL_ERROR - Other errors. */ */ Registration registerSender(in IAccessor bufferPool); Registration registerSender(in IAccessor bufferPool); /** * Sets up a buffer receiving communication node for the specified * buffer pool. A manager must create a IConnection to the buffer * pool if it does not already have a connection. To transfer buffers * using the interface, the receiver must initiates transfer(on demand). * * @param bufferPool a buffer pool which is specified with the IAccessor. * The specified buffer pool is the owner of received buffers. * @return the Id of the communication node to the buffer pool. * This id is used in FMQ to notify IAccessor that a buffer has been * sent to that connection during transfers. * @throws ServiceSpecificException with one of the following values: * ResultStatus::NO_MEMORY - Memory allocation failure occurred. * ResultStatus::CRITICAL_ERROR - Other errors. */ Registration registerPassiveSender(in IAccessor bufferPool); } } media/bufferpool/aidl/default/ClientManager.cpp +8 −0 Original line number Original line Diff line number Diff line Loading @@ -422,6 +422,14 @@ void ClientManager::Impl::cleanUp(bool clearCache) { return ::ndk::ScopedAStatus::ok(); return ::ndk::ScopedAStatus::ok(); } } ::ndk::ScopedAStatus ClientManager::registerPassiveSender( const std::shared_ptr<IAccessor>& in_bufferPool, Registration* _aidl_return) { // TODO (void) in_bufferPool; (void) _aidl_return; return ::ndk::ScopedAStatus::fromServiceSpecificError(ResultStatus::NOT_FOUND); } // Methods for local use. // Methods for local use. std::shared_ptr<ClientManager> ClientManager::sInstance; std::shared_ptr<ClientManager> ClientManager::sInstance; std::mutex ClientManager::sInstanceLock; std::mutex ClientManager::sInstanceLock; Loading media/bufferpool/aidl/default/include/bufferpool2/ClientManager.h +5 −0 Original line number Original line Diff line number Diff line Loading @@ -34,6 +34,11 @@ struct ClientManager : public BnClientManager { ::aidl::android::hardware::media::bufferpool2::IClientManager::Registration* _aidl_return) ::aidl::android::hardware::media::bufferpool2::IClientManager::Registration* _aidl_return) override; override; ::ndk::ScopedAStatus registerPassiveSender( const std::shared_ptr<IAccessor>& in_bufferPool, ::aidl::android::hardware::media::bufferpool2::IClientManager::Registration* _aidl_return) override; /** Gets an instance. */ /** Gets an instance. */ static std::shared_ptr<ClientManager> getInstance(); static std::shared_ptr<ClientManager> getInstance(); Loading media/c2/aidl/aidl_api/android.hardware.media.c2/current/android/hardware/media/c2/IComponent.aidl +9 −3 Original line number Original line Diff line number Diff line Loading @@ -51,12 +51,18 @@ interface IComponent { long blockPoolId; long blockPoolId; android.hardware.media.c2.IConfigurable configurable; android.hardware.media.c2.IConfigurable configurable; } } parcelable C2AidlGbAllocator { parcelable GbAllocator { ParcelFileDescriptor waitableFd; android.hardware.media.c2.IGraphicBufferAllocator igba; android.hardware.media.c2.IGraphicBufferAllocator igba; } parcelable PooledGbAllocator { ParcelFileDescriptor waitableFd; ParcelFileDescriptor waitableFd; long receiverId; android.hardware.media.c2.IPooledGraphicBufferAllocator ipgba; } } union BlockPoolAllocator { parcelable BlockPoolAllocator { int allocatorId; int allocatorId; android.hardware.media.c2.IComponent.C2AidlGbAllocator allocator; @nullable android.hardware.media.c2.IComponent.GbAllocator gbAllocator; @nullable android.hardware.media.c2.IComponent.PooledGbAllocator pooledGbAllocator; } } } } Loading
media/bufferpool/aidl/aidl_api/android.hardware.media.bufferpool2/current/android/hardware/media/bufferpool2/IClientManager.aidl +1 −0 Original line number Original line Diff line number Diff line Loading @@ -35,6 +35,7 @@ package android.hardware.media.bufferpool2; @VintfStability @VintfStability interface IClientManager { interface IClientManager { android.hardware.media.bufferpool2.IClientManager.Registration registerSender(in android.hardware.media.bufferpool2.IAccessor bufferPool); android.hardware.media.bufferpool2.IClientManager.Registration registerSender(in android.hardware.media.bufferpool2.IAccessor bufferPool); android.hardware.media.bufferpool2.IClientManager.Registration registerPassiveSender(in android.hardware.media.bufferpool2.IAccessor bufferPool); @VintfStability @VintfStability parcelable Registration { parcelable Registration { long connectionId; long connectionId; Loading
media/bufferpool/aidl/android/hardware/media/bufferpool2/IClientManager.aidl +19 −1 Original line number Original line Diff line number Diff line Loading @@ -40,7 +40,8 @@ interface IClientManager { /** /** * Sets up a buffer receiving communication node for the specified * Sets up a buffer receiving communication node for the specified * buffer pool. A manager must create a IConnection to the buffer * buffer pool. A manager must create a IConnection to the buffer * pool if it does not already have a connection. * pool if it does not already have a connection. To transfer buffers * using the interface, the sender must initiates transfer. * * * @param bufferPool a buffer pool which is specified with the IAccessor. * @param bufferPool a buffer pool which is specified with the IAccessor. * The specified buffer pool is the owner of received buffers. * The specified buffer pool is the owner of received buffers. Loading @@ -52,4 +53,21 @@ interface IClientManager { * ResultStatus::CRITICAL_ERROR - Other errors. * ResultStatus::CRITICAL_ERROR - Other errors. */ */ Registration registerSender(in IAccessor bufferPool); Registration registerSender(in IAccessor bufferPool); /** * Sets up a buffer receiving communication node for the specified * buffer pool. A manager must create a IConnection to the buffer * pool if it does not already have a connection. To transfer buffers * using the interface, the receiver must initiates transfer(on demand). * * @param bufferPool a buffer pool which is specified with the IAccessor. * The specified buffer pool is the owner of received buffers. * @return the Id of the communication node to the buffer pool. * This id is used in FMQ to notify IAccessor that a buffer has been * sent to that connection during transfers. * @throws ServiceSpecificException with one of the following values: * ResultStatus::NO_MEMORY - Memory allocation failure occurred. * ResultStatus::CRITICAL_ERROR - Other errors. */ Registration registerPassiveSender(in IAccessor bufferPool); } }
media/bufferpool/aidl/default/ClientManager.cpp +8 −0 Original line number Original line Diff line number Diff line Loading @@ -422,6 +422,14 @@ void ClientManager::Impl::cleanUp(bool clearCache) { return ::ndk::ScopedAStatus::ok(); return ::ndk::ScopedAStatus::ok(); } } ::ndk::ScopedAStatus ClientManager::registerPassiveSender( const std::shared_ptr<IAccessor>& in_bufferPool, Registration* _aidl_return) { // TODO (void) in_bufferPool; (void) _aidl_return; return ::ndk::ScopedAStatus::fromServiceSpecificError(ResultStatus::NOT_FOUND); } // Methods for local use. // Methods for local use. std::shared_ptr<ClientManager> ClientManager::sInstance; std::shared_ptr<ClientManager> ClientManager::sInstance; std::mutex ClientManager::sInstanceLock; std::mutex ClientManager::sInstanceLock; Loading
media/bufferpool/aidl/default/include/bufferpool2/ClientManager.h +5 −0 Original line number Original line Diff line number Diff line Loading @@ -34,6 +34,11 @@ struct ClientManager : public BnClientManager { ::aidl::android::hardware::media::bufferpool2::IClientManager::Registration* _aidl_return) ::aidl::android::hardware::media::bufferpool2::IClientManager::Registration* _aidl_return) override; override; ::ndk::ScopedAStatus registerPassiveSender( const std::shared_ptr<IAccessor>& in_bufferPool, ::aidl::android::hardware::media::bufferpool2::IClientManager::Registration* _aidl_return) override; /** Gets an instance. */ /** Gets an instance. */ static std::shared_ptr<ClientManager> getInstance(); static std::shared_ptr<ClientManager> getInstance(); Loading
media/c2/aidl/aidl_api/android.hardware.media.c2/current/android/hardware/media/c2/IComponent.aidl +9 −3 Original line number Original line Diff line number Diff line Loading @@ -51,12 +51,18 @@ interface IComponent { long blockPoolId; long blockPoolId; android.hardware.media.c2.IConfigurable configurable; android.hardware.media.c2.IConfigurable configurable; } } parcelable C2AidlGbAllocator { parcelable GbAllocator { ParcelFileDescriptor waitableFd; android.hardware.media.c2.IGraphicBufferAllocator igba; android.hardware.media.c2.IGraphicBufferAllocator igba; } parcelable PooledGbAllocator { ParcelFileDescriptor waitableFd; ParcelFileDescriptor waitableFd; long receiverId; android.hardware.media.c2.IPooledGraphicBufferAllocator ipgba; } } union BlockPoolAllocator { parcelable BlockPoolAllocator { int allocatorId; int allocatorId; android.hardware.media.c2.IComponent.C2AidlGbAllocator allocator; @nullable android.hardware.media.c2.IComponent.GbAllocator gbAllocator; @nullable android.hardware.media.c2.IComponent.PooledGbAllocator pooledGbAllocator; } } } }