ChapterForge
Loading...
Searching...
No Matches
chapterforge Namespace Reference

Classes

struct  ReadResult
 Parse an existing M4A/MP4 file and return its chapter data. More...
 
struct  Status
 Result object with success flag and optional error message. More...
 

Enumerations

enum class  LogVerbosity { LogVerbosity::Error = 0 , LogVerbosity::Warn = 1 , LogVerbosity::Info = 2 , LogVerbosity::Debug = 3 }
 

Functions

std::string version_string ()
 Return the ChapterForge library version string.
 
Status mux_file_to_m4a (const std::string &input_audio_path, const std::string &chapter_json_path, const std::string &output_path, bool fast_start=true)
 Mux AAC input + chapter/text/image metadata into an M4A file (JSON driven).
 
Status mux_file_to_m4a (const std::string &input_audio_path, const std::vector< ChapterTextSample > &text_chapters, const std::vector< ChapterImageSample > &image_chapters, const MetadataSet &metadata, const std::string &output_path, bool fast_start=true)
 Mux AAC input + in-memory chapter data (titles + images + metadata).
 
Status mux_file_to_m4a (const std::string &input_audio_path, const std::vector< ChapterTextSample > &text_chapters, const MetadataSet &metadata, const std::string &output_path, bool fast_start=true)
 
Status mux_file_to_m4a (const std::string &input_audio_path, const std::vector< ChapterTextSample > &text_chapters, const std::vector< ChapterImageSample > &image_chapters, const std::string &output_path, bool fast_start=true)
 
Status mux_file_to_m4a (const std::string &input_audio_path, const std::vector< ChapterTextSample > &text_chapters, const std::vector< ChapterTextSample > &url_chapters, const std::vector< ChapterImageSample > &image_chapters, const std::string &output_path, bool fast_start=true)
 Mux AAC input + in-memory chapter data (with optional URL track).
 
Status mux_file_to_m4a (const std::string &input_audio_path, const std::vector< ChapterTextSample > &text_chapters, const std::vector< ChapterTextSample > &url_chapters, const std::vector< ChapterImageSample > &image_chapters, const MetadataSet &metadata, const std::string &output_path, bool fast_start=true)
 Variant with explicit metadata; otherwise identical to the overload above.
 
ReadResult read_m4a (const std::string &path)
 
void set_log_verbosity (LogVerbosity level)
 Set global logging verbosity.
 
LogVerbosity get_log_verbosity ()
 Get current logging verbosity.
 
std::string hex_prefix (const std::vector< uint8_t > &data, size_t max_len=kHexPreviewBytes)
 

Variables

constexpr size_t kHexPreviewBytes = 8
 

Function Documentation

◆ get_log_verbosity()

LogVerbosity chapterforge::get_log_verbosity ( )

Get current logging verbosity.

◆ hex_prefix()

std::string chapterforge::hex_prefix ( const std::vector< uint8_t > &  data,
size_t  max_len = kHexPreviewBytes 
)
inline

◆ set_log_verbosity()

void chapterforge::set_log_verbosity ( LogVerbosity  level)

Set global logging verbosity.

Variable Documentation

◆ kHexPreviewBytes

constexpr size_t chapterforge::kHexPreviewBytes = 8
inlineconstexpr