11 #include "cores/AudioEngine/Interfaces/AEEncoder.h"    14 #include <libswresample/swresample.h>    28   void Reset() 
override;
    34   int Encode(uint8_t *in, 
int in_size, uint8_t *out, 
int out_size) 
override;
    35   int GetData(uint8_t **data) 
override;
    36   double GetDelay(
unsigned int bufferSize) 
override;
    38   unsigned int BuildChannelLayout(
const int64_t ffmap, 
CAEChannelInfo& layout);
    40   std::string m_CodecName;
    42   unsigned int m_BitRate = 0;
    44   AVCodecContext *m_CodecCtx;
    47   uint8_t m_Buffer[8 + AV_INPUT_BUFFER_MIN_SIZE];
    50   double m_OutputRatio = 0.0;
    51   double m_SampleRateMul = 0.0;
    52   unsigned int  m_NeededFrames = 0;
    53   bool m_NeedConversion = 
false;
 unsigned int GetBitRate() override
Returns the bitrate of the encoder. 
Definition: AEEncoderFFmpeg.cpp:247
IAEEncoder interface for on the fly audio compression. 
Definition: AEEncoder.h:20
double GetDelay(unsigned int bufferSize) override
Get the delay in seconds. 
Definition: AEEncoderFFmpeg.cpp:351
bool Initialize(AEAudioFormat &format, bool allow_planar_input=false) override
Called to setup the encoder to accept data in the specified format. 
Definition: AEEncoderFFmpeg.cpp:90
void Reset() override
Reset the encoder for new data. 
Definition: AEEncoderFFmpeg.cpp:242
unsigned int GetFrames() override
Return the number of frames needed to encode. 
Definition: AEEncoderFFmpeg.cpp:257
int GetData(uint8_t **data) override
Get the encoded data. 
Definition: AEEncoderFFmpeg.cpp:342
int Encode(uint8_t *in, int in_size, uint8_t *out, int out_size) override
Encodes the supplied samples into a provided buffer. 
Definition: AEEncoderFFmpeg.cpp:262
Definition: AEEncoderFFmpeg.h:20
Definition: AEChannelInfo.h:19
AVCodecID GetCodecID() override
Returns the AVCodecID of the encoder. 
Definition: AEEncoderFFmpeg.cpp:252
bool IsCompatible(const AEAudioFormat &format) override
Return true if the supplied format is compatible with the current open encoder. 
Definition: AEEncoderFFmpeg.cpp:44