LCOV - code coverage report
Current view: top level - media/client/main/include - MediaPipelineCapabilities.h (source / functions) Coverage Total Hit
Test: coverage.info Lines: 100.0 % 2 2
Test Date: 2025-02-18 13:13:53 Functions: 100.0 % 2 2

            Line data    Source code
       1              : /*
       2              :  * If not stated otherwise in this file or this component's LICENSE file the
       3              :  * following copyright and licenses apply:
       4              :  *
       5              :  * Copyright 2022 Sky UK
       6              :  *
       7              :  * Licensed under the Apache License, Version 2.0 (the "License");
       8              :  * you may not use this file except in compliance with the License.
       9              :  * You may obtain a copy of the License at
      10              :  *
      11              :  * http://www.apache.org/licenses/LICENSE-2.0
      12              :  *
      13              :  * Unless required by applicable law or agreed to in writing, software
      14              :  * distributed under the License is distributed on an "AS IS" BASIS,
      15              :  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
      16              :  * See the License for the specific language governing permissions and
      17              :  * limitations under the License.
      18              :  */
      19              : 
      20              : #ifndef FIREBOLT_RIALTO_CLIENT_MEDIA_PIPELINE_CAPABILITIES_H_
      21              : #define FIREBOLT_RIALTO_CLIENT_MEDIA_PIPELINE_CAPABILITIES_H_
      22              : 
      23              : #include "IMediaPipelineCapabilities.h"
      24              : #include "IMediaPipelineCapabilitiesIpcFactory.h"
      25              : #include <memory>
      26              : #include <string>
      27              : #include <vector>
      28              : 
      29              : namespace firebolt::rialto
      30              : {
      31              : /**
      32              :  * @brief IMediaPipelineCapabilitiesFactory factory class definition.
      33              :  */
      34              : class MediaPipelineCapabilitiesFactory : public IMediaPipelineCapabilitiesFactory
      35              : {
      36              : public:
      37            1 :     MediaPipelineCapabilitiesFactory() = default;
      38            1 :     ~MediaPipelineCapabilitiesFactory() override = default;
      39              : 
      40              :     std::unique_ptr<IMediaPipelineCapabilities> createMediaPipelineCapabilities() const override;
      41              : };
      42              : 
      43              : }; // namespace firebolt::rialto
      44              : 
      45              : namespace firebolt::rialto::client
      46              : {
      47              : /**
      48              :  * @brief The definition of the MediaPipelineCapabilities.
      49              :  */
      50              : class MediaPipelineCapabilities : public IMediaPipelineCapabilities
      51              : {
      52              : public:
      53              :     /**
      54              :      * @brief The constructor.
      55              :      *
      56              :      * @param[in] mediaPipelineCapabilitiesIpcFactory : The media pipeline capabilities ipc factory.
      57              :      */
      58              :     explicit MediaPipelineCapabilities(
      59              :         const std::shared_ptr<IMediaPipelineCapabilitiesIpcFactory> &MediaPipelineCapabilitiesIpcFactory);
      60              : 
      61              :     /**
      62              :      * @brief Virtual destructor.
      63              :      */
      64              :     virtual ~MediaPipelineCapabilities();
      65              : 
      66              :     /**
      67              :      * @brief Returns the MSE mime types supported by Rialto for \a sourceType
      68              :      *
      69              :      * @param[in] sourceType : source type
      70              :      *
      71              :      * @retval The supported mime types.
      72              :      */
      73              :     std::vector<std::string> getSupportedMimeTypes(MediaSourceType sourceType) override;
      74              : 
      75              :     /**
      76              :      * @brief Indicates if the specified mime type is supported.
      77              :      *
      78              :      * This method should be called to ensure that the specified mime
      79              :      * type is supported by Rialto.
      80              :      *
      81              :      * @param[in] mimeType : The mime type to check.
      82              :      *
      83              :      * @retval true if supported.
      84              :      */
      85              :     bool isMimeTypeSupported(const std::string &mimeTypee) override;
      86              : 
      87              :     /**
      88              :      * @brief  Check sinks and decoders for supported properties
      89              :      *
      90              :      * @param[in] mediaType     : The media type to search. If set to UNKNOWN then both AUDIO and VIDEO are searched
      91              :      * @param[in] propertyNames : A vector of property names to look for
      92              :      *
      93              :      * @retval Returns the subset of propertyNames that are supported by the mediaType
      94              :      */
      95              :     std::vector<std::string> getSupportedProperties(MediaSourceType mediaType,
      96              :                                                     const std::vector<std::string> &propertyNames) override;
      97              : 
      98              : private:
      99              :     /**
     100              :      * @brief The media pipeline capabilities ipc object.
     101              :      */
     102              :     std::unique_ptr<IMediaPipelineCapabilities> m_mediaPipelineCapabilitiesIpc;
     103              : };
     104              : 
     105              : }; // namespace firebolt::rialto::client
     106              : 
     107              : #endif // FIREBOLT_RIALTO_CLIENT_MEDIA_PIPELINE_CAPABILITIES_H_
        

Generated by: LCOV version 2.0-1