• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..17-Mar-2025-

engine/H17-Mar-2025-57,65245,155

images/H17-Mar-2025-

interface/H17-Mar-2025-10,5235,989

services/media_monitor/H17-Mar-2025-7,4296,000

src/H17-Mar-2025-12,0379,348

test/H17-Mar-2025-17,08213,409

tests/H17-Mar-2025-12,0958,855

video_processing_engine/H17-Mar-2025-5,8263,772

.gitattributesH A D17-Mar-2025631 1615

.gitignoreH A D17-Mar-2025427 2322

BUILD.gnH A D17-Mar-20253 KiB10299

CMakeLists.txtH A D17-Mar-20251.1 KiB3125

LICENSEH A D17-Mar-20259.9 KiB177150

OAT.xmlH A D17-Mar-20254.4 KiB7419

README.mdH A D17-Mar-20256 KiB8973

README_zh.mdH A D17-Mar-20255.7 KiB8975

bundle.jsonH A D17-Mar-202510.3 KiB256255

config.gniH A D17-Mar-20254.7 KiB135113

README.md

1# HiStreamer<a name="EN-US_TOPIC_0000001148809513"></a>
2
3- [HiStreamer<a name="EN-US_TOPIC_0000001148809513"></a>](#histreamer)
4  - [Introduction<a name="section1158716411637"></a>](#introduction)
5  - [Logical architecture<a name="section1158716411638"></a>](#logical-architecture)
6  - [List of plug-ins<a name="section1158716411639"></a>](#plugin-list)
7  - [Directory Structure<a name="section1158716411640"></a>](#directory-structure)
8  - [Repositories Involved<a name="section1158716411641"></a>](#repositories-involved)
9
10## Introduction<a name="section1158716411637"></a>
11
12HiStreamer is the foundation module of the multimedia subsystem. It provides a processing pipeline and plug-ins required by the media framework, such as the file source, codecs, muxer and demuxer, and audio and video data processor.
13
14## Logical architecture<a name="section1158716411638"></a>
15As a media engine, HiStreamer connects to player_framework (on a Standard device) or media_lite (on a Mini or Small device) and provides application apis externally. It is divided into three layers:
16- Application scenario Encapsulation layer: for example, HiPlayer and HiRecorder.
17- Pipeline framework layer: including Pipeline framework, each Filter node implementation.
18- Plug-in layer: includes plug-in framework, various plug-ins.
19
20![Logical architecture diagram](images/media_foundation_architecture.png)
21
22## Plugin list<a name="section1158716411639"></a>
23The HiStreamer plug-in list is as follows:
24| The plug-in name   | path      |External dependencies | License  | function         | applicable scene |
25| --         | --          | --  | --       | --           | --          |
26| FFMPEG Adapter| plugins/ffmpeg_adapter | FFMPEG | LGPL etc. | Decapsulation: mp3, m4a, mp4, wav<br>Decode: mp3, aac |Small/Standard devices that support dynamic linking |
27| File Source | plugins/source/file_source | FileSystem | Apache | Reading file data | All the device |
28| Minimp3 Adapter | plugins/minimp3_adapter | minimp3 | CC0 | Decapsulation: mp3<br>decode : mp3 | All the device |
29| Minimp4 Demuxer | plugins/demuxer/minimp4_demuxer | minimp4 | CC0 | Decapsulation: m4a | All the device |
30| Aac Demuxer | plugins/demuxer/aac_demuxer | NA | Apache | Decapsulation: aac | All the device |
31| HDI Sink | plugins/hdi_adapter | Audio HDI | Apache | play music  | mini/small device|
32
33
34
35## Directory Structure<a name="section1158716411640"></a>
36
37The structure of the repository directory is as follows:
38
39```
40/foundation/multimedia/media_foundation      # HiStreamer media engine component business code
41├─LICENSE                              # The license file
42├─engine                               # The engine code
43│  ├─foundation                        # Basic tool classes, including OS adaptation
44│  ├─include                           # Expose the necessary header files for calling histreamer in other modules, including calling pipeline/filter or calling plugins.
45│  │  ├─foundation                     # Basic tool library of histreamer, including logging, buffer tools, operating system adaptation, language extensions, etc.
46│  │  ├─pipeline                       # Header files for the pipeline framework, mainly the pipeline/filter interface.
47│  │  └─plugin                         # Header files for the "plugin" subfolder of the engine
48│  │  	├─common                       # Basic type header files required for plugin interfaces
49│  │  	└─interface                    # Plugin interfaces
50│  ├─pipeline                          # pipeline framework
51│  │  ├─core                           # pipeline core implementation
52│  │  ├─factory                        # filter factory
53│  │  └─filters                        # Several filter node implementations
54│  │      ├─codec                      # Codec node implementation
55│  │      ├─common                     # Basic type definitions required by filters
56│  │      ├─demux                      # Decapsulation node implementation
57│  │      ├─muxer                      # Capsulation node implementation
58│  │      ├─sink                       # Output node implementation
59│  │      └─source                     # Data source node implementation
60│  ├─plugin                            # plug-in
61│  │  ├─common                         # The underlying type definitions on which the plug-in interface depends
62│  │  ├─core                           # Plug-in framework
63│  │  └─plugins                        # Several plug-in implementations
64│  │      ├─codec_adapter              # Codec adapter
65│  │      ├─minimp3_adapter            # minimp3 adapter
66│  │      ├─ffmpeg_adapter             # FFMPEG adaption (adaption into encapsulation and decapsulation, codec plug-in)
67│  │      ├─hdi_adapter                # HDI adapter (adapter to output plug-in)
68│  │      ├─lite_aac_decoder           # Lite AAC decoder plugin
69│  │      ├─demuxer                    # Unpack plugin
70│  │      ├─sink                       # Output plug-in
71│  │      └─source                     # Data source plug-in
72│  ├─scene                             # Playback and recording scenes
73│  │  ├─common                         # Common basic type definitions
74│  │  ├─lite                           # interface implementation for integration with lite devices
75│  │  ├─player                         # Playback scene
76│  │  ├─recorder                       # Recording scene
77│  │  └─standard                       # interface implementation for integration with standard devices
78└─interface                            # Engine external interface
79```
80
81## Repositories Involved<a name="section1158716411641"></a>
82
83- [multimedia Subsystem](https://gitee.com/openharmony/docs/blob/master/en/readme/multimedia.md)
84
85- [player_framework](https://gitee.com/openharmony/multimedia_player_framework)
86
87- [media_lite](https://gitee.com/openharmony/multimedia_media_lite)
88
89- **histreamer**

README_zh.md

1# 媒体引擎组件<a name="ZH-CN_TOPIC_0000001148809513"></a>
2
3- [媒体引擎组件<a name="ZH-CN_TOPIC_0000001148809513"></a>](#媒体引擎组件)
4  - [简介<a name="section1158716411637"></a>](#简介)
5  - [逻辑架构<a name="section_histreamer_arch"></a>](#逻辑架构)
6  - [插件列表<a name="section_histreamer_plugins"></a>](#插件列表)
7  - [目录<a name="section161941989596"></a>](#目录)
8  - [相关仓<a name="section1533973044317"></a>](#相关仓)
9
10## 简介<a name="section1158716411637"></a>
11
12HiStreamer是一个轻量级的媒体引擎组件,提供播放、录制等场景的媒体数据流水线处理。
13- 播放场景分为如下几个节点:数据源读取、解封装、解码、输出;
14- 录制场景分为如下几个节点:数据源读取、编码、封装、输出。
15
16这些节点的具体功能,主要在插件中实现。可以插件的形式扩展支持新的数据源、封装格式、编解码格式、输出方式。
17
18## 逻辑架构<a name="section_histreamer_arch"></a>
19HiStreamer作为媒体引擎,向上对接player_framework(standard设备上)或者media_lite(mini/small设备上),再对外提供应用API。它内部分为三层:
20- 应用场景封装层: 比如HiPlayer, HiRecorder。
21- Pipeline框架层: 包括Pipeline框架,各个Filter节点实现。
22- 插件层: 包括插件框架,各种插件。
23
24![逻辑架构图](images/histreamer_architecture.png)
25
26## 插件列表<a name="section_histreamer_plugins"></a>
27HiStreamer插件列表如下:
28| 插件名称    | 路径        | 外部依赖 | License  |  功能        | 适用场景    |
29| --         | --          | --  | --       | --           | --          |
30| FFMPEG Adapter| plugins/ffmpeg_adapter | FFMPEG | LGPL etc. | 解封装:mp3,m4a,mp4,wav<br>解码:mp3,aac | 支持动态链接的<br>small/standard设备 |
31| File Source | plugins/source/file_source | FileSystem | Apache | 读取文件数据 | 所有设备 |
32| Minimp3 Adapter | plugins/minimp3_adapter | minimp3 | CC0 | 解封装: mp3<br>解码: mp3 | 所有设备 |
33| Minimp4 Demuxer | plugins/demuxer/minimp4_demuxer | minimp4 | CC0 | 解封装: m4a | 所有设备 |
34| Aac Demuxer | plugins/demuxer/aac_demuxer | NA | Apache | 解封装: aac | 所有设备 |
35| HDI Sink | plugins/hdi_adapter | Audio HDI | Apache | 播放音乐 | mini/small设备 |
36
37## 目录<a name="section161941989596"></a>
38
39仓目录结构如下:
40
41```
42/foundation/multimedia/histreamer      # HiStreamer媒体引擎组件业务代码
43├─LICENSE                              # 证书文件
44├─engine                               # 引擎代码
45│  ├─foundation                        # 基础工具类, 包括OS适配
46│  ├─include                           # 为其它模块调用histreamer暴露必要的头文件,包括调用pipeline/filter,或者调用插件
47│  │  ├─foundation                     # histreamer基础工具库,包括日志打印、Buffer工具、操作系统适配、语言扩展等
48│  │  ├─pipeline                       # pipeline框架的头文件,主要是pipeline/filter接口
49│  │  └─plugin                         # 插件相关的头文件
50│  │      ├─common                     # 插件接口依赖的基础类型头文件
51│  │      └─interface                  # 插件接口
52│  ├─pipeline                          # pipeline框架
53│  │  ├─core                           # pipeline核心实现
54│  │  ├─factory                        # filter工厂
55│  │  └─filters                        # 若干filter节点实现
56│  │      ├─codec                      # 编解码节点实现
57│  │      ├─common                     # filters依赖的基础类型定义
58│  │      ├─demux                      # 解封装节点实现
59│  │      ├─muxer                      # 封装节点实现
60│  │      ├─sink                       # 输出节点实现
61│  │      └─source                     # 数据源节点实现
62│  ├─plugin                            # 插件
63│  │  ├─common                         # 插件接口依赖的基础类型定义
64│  │  ├─core                           # 插件框架,各个插件的代理类
65│  │  └─plugins                        # 若干插件实现
66│  │      ├─codec_adapter              # 硬件编解码适配
67│  │      ├─minimp3_adapter            # minimp3适配
68│  │      ├─ffmpeg_adapter             # FFMPEG适配(适配成封装解封装、编解码插件)
69│  │      ├─hdi_adapter                # HDI适配(适配成输出插件)
70│  │      ├─lite_aac_decoder           # 轻量级AAC解码器插件
71│  │      ├─demuxer                    # 解封装插件
72│  │      ├─sink                       # 输出插件
73│  │      └─source                     # 数据源插件
74│  └─scene                             # 播放录制等场景的封装实现
75│  │  ├─common                         # 共用的基础类型定义
76│  │  ├─lite                           # 对接到轻量设备的接口实现
77│  │  ├─player                         # 播放场景实现
78│  │  ├─recorder                       # 录制场景实现
79│  │  └─standard                       # 对接到标准设备的接口实现
80└─interface                            # 引擎对外接口
81```
82
83## 相关仓<a name="section1533973044317"></a>
84
85- [媒体子系统](https://gitee.com/openharmony/docs/blob/master/zh-cn/readme/%E5%AA%92%E4%BD%93%E5%AD%90%E7%B3%BB%E7%BB%9F.md)
86
87- [player_framework](https://gitee.com/openharmony/multimedia_player_framework)
88
89- [media_lite](https://gitee.com/openharmony/multimedia_media_lite)