Skip to main content

Crate libflo_audio

Crate libflo_audio 

Source

Re-exports§

pub use core::compute_crc32;
pub use core::compute_ebu_r128_loudness;
pub use core::extract_spectral_fingerprint;
pub use core::extract_waveform_peaks;
pub use core::rice;
pub use core::ChannelData;
pub use core::FloError;
pub use core::FloErrorExt;
pub use core::FloErrorKind;
pub use core::FloFile;
pub use core::FloResult;
pub use core::FrameType;
pub use core::LoudnessMetrics;
pub use core::ResidualEncoding;
pub use core::HEADER_SIZE;
pub use core::MAGIC;
pub use core::VERSION_MAJOR;
pub use core::VERSION_MINOR;
pub use lossless::lpc;
pub use lossless::Decoder;
pub use lossless::Encoder;
pub use lossy::deserialize_frame;
pub use lossy::serialize_frame;
pub use lossy::BlockSize;
pub use lossy::Mdct;
pub use lossy::PsychoacousticModel;
pub use lossy::QualityPreset;
pub use lossy::TransformDecoder as LossyDecoder;
pub use lossy::TransformEncoder as LossyEncoder;
pub use lossy::TransformFrame;
pub use lossy::WindowType;
pub use lossy::FRAME_COEFFICIENTS;
pub use lossy::LONG_BLOCK_SIZE;
pub use lossy::SHORTS_PER_GROUP;
pub use lossy::SHORT_BLOCK_SIZE;
pub use lossy::SHORT_GROUP_OFFSET;
pub use streaming::DecoderState;
pub use streaming::EncodedFrame;
pub use streaming::StreamingAudioInfo;
pub use streaming::StreamingDecoder;
pub use streaming::StreamingEncoder;
pub use core::metadata::*;

Modules§

core
dsp
DSP primitives
lossless
Lossless encoding for flo
lossy
Transform-based lossy encoder for flo
seeking
streaming
streaming encode/decode for flo audio

Structs§

AudioInfo
info about a flo file
Reader
binary reader for flo format
WasmStreamingDecoder
WasmStreamingEncoder
Encodes samples frame-by-frame as they arrive, returning encoded frames ready for transmission. Use this for low-latency streaming encoding where you push samples and pull frames.
Writer
binary writer for flo format

Functions§

create_metadata
Create metadata from basic fields and serialize to MessagePack
create_metadata_from_object
Create metadata from a JavaScript object
decode
decode flo file to samples
decode_frame_at
Decode a single frame by index without decoding the entire file
encode
encode samples to flo lossless
encode_lossy
encode samples to flo lossy
encode_with_bitrate
encode to flo lossy with target bitrate
extract_dominant_frequencies_to_vec
Extract dominant frequencies from spectral fingerprint
extract_waveform_peaks_to_struct
Extract waveform peaks from audio samples (native version)
extract_waveform_rms_to_struct
Extract waveform RMS from audio samples
format_time
Format time in seconds to MM:SS or H:MM:SS string
format_time_ms
Format time in milliseconds to MM:SS or H:MM:SS string
get_cover_art
Get cover art from a flo file
get_metadata
Extract metadata from a flo file
get_metadata_bytes
Get just the metadata bytes from a flo file
get_metadata_bytes_native
Get just the metadata bytes from a flo file
get_section_markers
Get section markers from a flo file
get_synced_lyrics
Get synced lyrics from a flo file
get_toc
Extract TOC (Table of Contents) entries from a flo file
get_waveform_data
Get waveform data from a flo file for instant visualization
has_metadata
does the file have metadata? (native)
has_metadata_wasm
does the file have metadata? (wasm binding)
info
Get information about a flo file
seek_to_time
Seek to a specific time in milliseconds
set_metadata
Replace just the metadata in a flo file (convenience function)
set_metadata_field
Set a single field in existing metadata bytes
spectral_similarity_score
Compute spectral similarity between two fingerprints
strip_metadata
Remove all metadata from a flo file
strip_metadata_bytes
Remove all metadata from a flo file
update_metadata
update metadata without re-encoding audio
update_metadata_bytes
update metadata without re-encoding (native)
validate
Validate flo file integrity
version
get lib version