arduino-audio-tools
Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
audio_tools::FLACEncoder Class Reference

FLACEncoder. More...

#include <CodecFLAC.h>

Inheritance diagram for audio_tools::FLACEncoder:
audio_tools::AudioEncoder audio_tools::AudioWriter

Public Member Functions

virtual void begin () override
 starts the processing using the actual AudioInfo
 
virtual void begin (AudioBaseInfo from)
 
void begin (Print &out)
 starts the processing
 
int blockSize ()
 
int compressionLevel ()
 
void end () override
 stops the processing
 
bool isOgg ()
 
bool isOpen ()
 
const char * mime () override
 Provides "audio/pcm".
 
 operator bool () override
 
virtual void setAudioInfo (AudioBaseInfo from) override
 We update the audio information which will be used in the begin method.
 
void setBlockSize (int size)
 
void setCompressionLevel (int level)
 
void setOgg (bool isOgg)
 
void setOutputStream (Print &out_stream) override
 Defines the output Stream.
 
virtual size_t write (const void *in_ptr, size_t in_size) override
 Writes FLAC Packet.
 

Protected Member Functions

void writeBuffer (int16_t *data, size_t samples)
 

Static Protected Member Functions

static FLAC__StreamEncoderWriteStatus write_callback (const FLAC__StreamEncoder *encoder, const FLAC__byte buffer[], size_t bytes, uint32_t samples, uint32_t current_frame, void *client_data)
 

Protected Attributes

Vector< FLAC__int32 > buffer
 
AudioBaseInfo cfg
 
int flac_block_size = 512
 
int flac_compression_level = 8
 
bool is_ogg
 
bool is_open
 
FLAC__StreamEncoder * p_encoder =nullptr
 
Printp_print = nullptr
 

Detailed Description

FLACEncoder.

Author
Phil Schatzmann

The documentation for this class was generated from the following file: