# espressif/esp-adf-libs architecture

> Architecture diagram of the GitHub repository espressif/esp-adf-libs, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-15). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/espressif/esp-adf-libs
- Repository: https://github.com/espressif/esp-adf-libs

## Overview

This repository is an ESP-IDF multimedia component suite rather than one end-user application. Its principal workflow is to accept media through an extractor or stream I/O component, expose encoded audio/video or image data for processing, and optionally encode or package results. It also provides independent audio effects, media protocols, MIDI, and platform services. The README is empty, so capability coverage is inferred from the component tree; unsampled implementation details are represented as subsystems without speculative call edges.

Main entry points: [`esp_hls_stream/private_inc/hls_fetcher.h`](https://github.com/espressif/esp-adf-libs/blob/master/esp_hls_stream/private_inc/hls_fetcher.h) (HLS Fetcher), [`esp_extractor/include/esp_extractor.h`](https://github.com/espressif/esp-adf-libs/blob/master/esp_extractor/include/esp_extractor.h) (Media Extractor), [`esp_efc_codec/efc_player/lv_efc.c`](https://github.com/espressif/esp-adf-libs/blob/master/esp_efc_codec/efc_player/lv_efc.c) (EFC Player Widget), [`esp_extractor/src/esp_extractor_id3_parser.c`](https://github.com/espressif/esp-adf-libs/blob/master/esp_extractor/src/esp_extractor_id3_parser.c) (ID3 Parser)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_audio["Audio"]
  node_audio_codec["Audio Codec"]
  node_audio_effects["Audio Effects"]
  node_ambient_led["Ambient LEDs<br/>[esp_ambient_led.h]"]
  node_midi["MIDI and Sound"]
end

subgraph group_video_image["Video and Images"]
  node_video_codec["Video Codec"]
  node_h264_encoder["H.264 Encoder"]
  node_jpeg["JPEG Codec"]
  node_image_effects["Image Effects"]
  node_efc_codec["EFC Codec<br/>[esp_efc_codec.c]"]
  node_efc_widget["EFC Player Widget<br/>[lv_efc.c]"]
end

subgraph group_media_io["Media I/O and Containers"]
  node_extractor["Media Extractor<br/>[esp_extractor.h]"]
  node_id3_parser["ID3 Parser"]
  node_hls_io["HLS I/O<br/>[hls_io.c]"]
  node_hls_fetcher["HLS Fetcher<br/>[hls_fetcher.h]"]
  node_muxer["Media Muxer"]
end

subgraph group_network_protocols["Protocols and Security"]
  node_media_protocols["Media Protocols"]
  node_srtp["SRTP Security<br/>[srtp.c]"]
end

subgraph group_platform_services["Platform Services"]
  node_os_api["OS Abstraction<br/>[media_lib_os.c]"]
  node_os_port["OS Port"]
  node_memory_trace["Memory Tracing"]
end

node_id3_parser -->|"plugs into"| node_extractor
node_hls_io -->|"uses"| node_hls_fetcher
node_hls_fetcher -->|"references"| node_extractor
node_efc_widget -->|"uses codec"| node_efc_codec
node_os_api -->|"delegates"| node_os_port

click node_audio_codec "https://github.com/espressif/esp-adf-libs/tree/master/esp_audio_codec"
click node_audio_effects "https://github.com/espressif/esp-adf-libs/tree/master/esp_audio_effects"
click node_ambient_led "https://github.com/espressif/esp-adf-libs/blob/master/esp_ambient_led/include/esp_ambient_led.h"
click node_midi "https://github.com/espressif/esp-adf-libs/tree/master/esp_midi"
click node_video_codec "https://github.com/espressif/esp-adf-libs/tree/master/esp_video_codec"
click node_h264_encoder "https://github.com/espressif/esp-adf-libs/blob/master/esp_video_codec/src/encoder/esp_video_enc_h264.c"
click node_jpeg "https://github.com/espressif/esp-adf-libs/tree/master/esp_new_jpeg"
click node_image_effects "https://github.com/espressif/esp-adf-libs/tree/master/esp_image_effects"
click node_efc_codec "https://github.com/espressif/esp-adf-libs/blob/master/esp_efc_codec/src/esp_efc_codec.c"
click node_efc_widget "https://github.com/espressif/esp-adf-libs/blob/master/esp_efc_codec/efc_player/lv_efc.c"
click node_extractor "https://github.com/espressif/esp-adf-libs/blob/master/esp_extractor/include/esp_extractor.h"
click node_id3_parser "https://github.com/espressif/esp-adf-libs/blob/master/esp_extractor/src/esp_extractor_id3_parser.c"
click node_hls_io "https://github.com/espressif/esp-adf-libs/blob/master/esp_hls_stream/src/hls_io.c"
click node_hls_fetcher "https://github.com/espressif/esp-adf-libs/blob/master/esp_hls_stream/private_inc/hls_fetcher.h"
click node_muxer "https://github.com/espressif/esp-adf-libs/tree/master/esp_muxer"
click node_media_protocols "https://github.com/espressif/esp-adf-libs/tree/master/esp_media_protocols"
click node_srtp "https://github.com/espressif/esp-adf-libs/blob/master/esp_libsrtp/libsrtp/srtp/srtp.c"
click node_os_api "https://github.com/espressif/esp-adf-libs/blob/master/media_lib_sal/media_lib_os.c"
click node_os_port "https://github.com/espressif/esp-adf-libs/blob/master/media_lib_sal/port/media_lib_os_freertos.c"
click node_memory_trace "https://github.com/espressif/esp-adf-libs/blob/master/media_lib_sal/mem_trace/media_lib_mem_trace.c"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_audio_codec,node_audio_effects,node_ambient_led,node_midi toneBlue
class node_video_codec,node_h264_encoder,node_jpeg,node_image_effects,node_efc_codec,node_efc_widget toneAmber
class node_extractor,node_id3_parser,node_hls_io,node_hls_fetcher,node_muxer toneMint
class node_media_protocols,node_srtp toneRose
class node_os_api,node_os_port,node_memory_trace toneIndigo
```

## Components

### Audio

- [Audio Codec](https://github.com/espressif/esp-adf-libs/tree/master/esp_audio_codec): `esp_audio_codec`
- [Audio Effects](https://github.com/espressif/esp-adf-libs/tree/master/esp_audio_effects): `esp_audio_effects`
- [Ambient LEDs](https://github.com/espressif/esp-adf-libs/blob/master/esp_ambient_led/include/esp_ambient_led.h): `esp_ambient_led/include/esp_ambient_led.h`
- [MIDI and Sound](https://github.com/espressif/esp-adf-libs/tree/master/esp_midi): `esp_midi`

### Video and Images

- [Video Codec](https://github.com/espressif/esp-adf-libs/tree/master/esp_video_codec): `esp_video_codec`
- [H.264 Encoder](https://github.com/espressif/esp-adf-libs/blob/master/esp_video_codec/src/encoder/esp_video_enc_h264.c): `esp_video_codec/src/encoder/esp_video_enc_h264.c`
- [JPEG Codec](https://github.com/espressif/esp-adf-libs/tree/master/esp_new_jpeg): `esp_new_jpeg`
- [Image Effects](https://github.com/espressif/esp-adf-libs/tree/master/esp_image_effects): `esp_image_effects`
- [EFC Codec](https://github.com/espressif/esp-adf-libs/blob/master/esp_efc_codec/src/esp_efc_codec.c): `esp_efc_codec/src/esp_efc_codec.c`
- [EFC Player Widget](https://github.com/espressif/esp-adf-libs/blob/master/esp_efc_codec/efc_player/lv_efc.c): `esp_efc_codec/efc_player/lv_efc.c`

### Media I/O and Containers

- [Media Extractor](https://github.com/espressif/esp-adf-libs/blob/master/esp_extractor/include/esp_extractor.h): `esp_extractor/include/esp_extractor.h`
- [ID3 Parser](https://github.com/espressif/esp-adf-libs/blob/master/esp_extractor/src/esp_extractor_id3_parser.c): `esp_extractor/src/esp_extractor_id3_parser.c`
- [HLS I/O](https://github.com/espressif/esp-adf-libs/blob/master/esp_hls_stream/src/hls_io.c): `esp_hls_stream/src/hls_io.c`
- [HLS Fetcher](https://github.com/espressif/esp-adf-libs/blob/master/esp_hls_stream/private_inc/hls_fetcher.h): `esp_hls_stream/private_inc/hls_fetcher.h`
- [Media Muxer](https://github.com/espressif/esp-adf-libs/tree/master/esp_muxer): `esp_muxer`

### Protocols and Security

- [Media Protocols](https://github.com/espressif/esp-adf-libs/tree/master/esp_media_protocols): `esp_media_protocols`
- [SRTP Security](https://github.com/espressif/esp-adf-libs/blob/master/esp_libsrtp/libsrtp/srtp/srtp.c): `esp_libsrtp/libsrtp/srtp/srtp.c`

### Platform Services

- [OS Abstraction](https://github.com/espressif/esp-adf-libs/blob/master/media_lib_sal/media_lib_os.c): `media_lib_sal/media_lib_os.c`
- [OS Port](https://github.com/espressif/esp-adf-libs/blob/master/media_lib_sal/port/media_lib_os_freertos.c): `media_lib_sal/port/media_lib_os_freertos.c`
- [Memory Tracing](https://github.com/espressif/esp-adf-libs/blob/master/media_lib_sal/mem_trace/media_lib_mem_trace.c): `media_lib_sal/mem_trace/media_lib_mem_trace.c`

## Connections

- ID3 Parser → Media Extractor: plugs into
- HLS I/O → HLS Fetcher: uses (evidence: `esp_hls_stream/src/hls_io.c`)
- HLS Fetcher → Media Extractor: references (evidence: `esp_hls_stream/private_inc/hls_fetcher.h`)
- EFC Player Widget → EFC Codec: uses codec (evidence: `esp_efc_codec/efc_player/lv_efc.c`)
- OS Abstraction → OS Port: delegates (evidence: `media_lib_sal/media_lib_os.c`)
