MythTV  master
Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
LameEncoder Class Reference

#include <lameencoder.h>

Inheritance diagram for LameEncoder:
Inheritance graph
[legend]
Collaboration diagram for LameEncoder:
Collaboration graph
[legend]

Public Member Functions

 LameEncoder (const QString &outfile, int qualitylevel, MusicMetadata *metadata, bool vbr=false)
 
 ~LameEncoder () override
 
int addSamples (int16_t *bytes, unsigned int len) override
 
- Public Member Functions inherited from Encoder
 Encoder (QString outfile, int qualitylevel, MusicMetadata *metadata)
 
virtual ~Encoder ()
 
virtual bool isValid ()
 

Private Member Functions

int init_encoder (lame_global_flags *gf, int quality, bool vbr)
 

Static Private Member Functions

static void init_id3tags (lame_global_flags *gf)
 

Private Attributes

int m_bits {16}
 
int m_channels {2}
 
int m_bytesPerSample {m_channels * m_bits / 8}
 
int m_samplesPerChannel {0}
 
int m_mp3BufSize {(int)(1.25 * 16384 + 7200)}
 
char * m_mp3Buf {nullptr}
 
lame_global_flags * m_gf {nullptr}
 

Additional Inherited Members

- Protected Attributes inherited from Encoder
const QString m_outfile
 
FILE * m_out {nullptr}
 
int m_quality
 
MusicMetadatam_metadata {nullptr}
 

Detailed Description

Definition at line 46 of file lameencoder.h.

Constructor & Destructor Documentation

◆ LameEncoder()

LameEncoder::LameEncoder ( const QString &  outfile,
int  qualitylevel,
MusicMetadata metadata,
bool  vbr = false 
)

Definition at line 101 of file lameencoder.cpp.

◆ ~LameEncoder()

LameEncoder::~LameEncoder ( )
override

Definition at line 119 of file lameencoder.cpp.

Member Function Documentation

◆ addSamples()

int LameEncoder::addSamples ( int16_t *  bytes,
unsigned int  len 
)
overridevirtual

Implements Encoder.

Definition at line 143 of file lameencoder.cpp.

Referenced by ~LameEncoder().

◆ init_encoder()

int LameEncoder::init_encoder ( lame_global_flags *  gf,
int  quality,
bool  vbr 
)
private

Definition at line 62 of file lameencoder.cpp.

Referenced by LameEncoder().

◆ init_id3tags()

void LameEncoder::init_id3tags ( lame_global_flags *  gf)
staticprivate

Definition at line 48 of file lameencoder.cpp.

Referenced by LameEncoder().

Member Data Documentation

◆ m_bits

int LameEncoder::m_bits {16}
private

Definition at line 58 of file lameencoder.h.

◆ m_channels

int LameEncoder::m_channels {2}
private

Definition at line 59 of file lameencoder.h.

◆ m_bytesPerSample

int LameEncoder::m_bytesPerSample {m_channels * m_bits / 8}
private

Definition at line 60 of file lameencoder.h.

Referenced by addSamples().

◆ m_samplesPerChannel

int LameEncoder::m_samplesPerChannel {0}
private

Definition at line 61 of file lameencoder.h.

Referenced by addSamples().

◆ m_mp3BufSize

int LameEncoder::m_mp3BufSize {(int)(1.25 * 16384 + 7200)}
private

Definition at line 64 of file lameencoder.h.

Referenced by addSamples().

◆ m_mp3Buf

char* LameEncoder::m_mp3Buf {nullptr}
private

Definition at line 65 of file lameencoder.h.

Referenced by addSamples(), and ~LameEncoder().

◆ m_gf

lame_global_flags* LameEncoder::m_gf {nullptr}
private

Definition at line 67 of file lameencoder.h.

Referenced by addSamples(), LameEncoder(), and ~LameEncoder().


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