TB2026-YDS Firmware
Toggle main menu visibility
Loading...
Searching...
No Matches
mp3_frame.h
Go to the documentation of this file.
1
16
#pragma once
17
18
#include <stdint.h>
19
#include <stdbool.h>
20
#include <stddef.h>
21
23
typedef
struct
{
24
uint32_t
rate_hz
;
25
uint32_t
bitrate_bps
;
26
uint16_t
samples_per_frame
;
27
uint8_t
channels
;
28
uint8_t
side_info_bytes
;
29
}
mp3_frame_hdr_t
;
30
39
bool
mp3_frame_parse
(
const
uint8_t *p,
size_t
len,
mp3_frame_hdr_t
*out);
40
49
uint32_t
mp3_xing_duration_ms
(
const
uint8_t *frame,
size_t
len,
const
mp3_frame_hdr_t
*hdr);
mp3_frame_parse
bool mp3_frame_parse(const uint8_t *p, size_t len, mp3_frame_hdr_t *out)
Parse a 4-byte MPEG Layer III frame header at p.
Definition
mp3_frame.c:23
mp3_xing_duration_ms
uint32_t mp3_xing_duration_ms(const uint8_t *frame, size_t len, const mp3_frame_hdr_t *hdr)
Track duration from a Xing/Info/VBRI tag in the first frame, if present.
Definition
mp3_frame.c:57
mp3_frame_hdr_t
Decoded fields of one MPEG Layer III frame header.
Definition
mp3_frame.h:23
mp3_frame_hdr_t::side_info_bytes
uint8_t side_info_bytes
Definition
mp3_frame.h:28
mp3_frame_hdr_t::bitrate_bps
uint32_t bitrate_bps
Definition
mp3_frame.h:25
mp3_frame_hdr_t::samples_per_frame
uint16_t samples_per_frame
Definition
mp3_frame.h:26
mp3_frame_hdr_t::channels
uint8_t channels
Definition
mp3_frame.h:27
mp3_frame_hdr_t::rate_hz
uint32_t rate_hz
Definition
mp3_frame.h:24
components
services
audio
mp3_frame.h
Generated by
1.17.0