forked from mikrosimage/avTranscoder
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAudioGenerator.hpp
More file actions
34 lines (24 loc) · 819 Bytes
/
Copy pathAudioGenerator.hpp
File metadata and controls
34 lines (24 loc) · 819 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#ifndef _AV_TRANSCODER_DECODER_AUDIO_GENERATOR_HPP_
#define _AV_TRANSCODER_DECODER_AUDIO_GENERATOR_HPP_
#include "IDecoder.hpp"
#include <AvTranscoder/codec/AudioCodec.hpp>
namespace avtranscoder
{
class AvExport AudioGenerator : public IDecoder
{
public:
AudioGenerator();
~AudioGenerator();
AudioFrameDesc& getAudioFrameDesc() { return _frameDesc; }
void setAudioFrameDesc( const AudioFrameDesc& frameDesc );
void setup() {}
void setFrame( Frame& inputFrame );
bool decodeNextFrame( Frame& frameBuffer );
bool decodeNextFrame( Frame& frameBuffer, const size_t subStreamIndex );
private:
Frame* _inputFrame; ///< Has link (no ownership)
AudioFrame* _silent; ///< The generated silent (has ownership)
AudioFrameDesc _frameDesc; ///< The description of the silent (sample rate...)
};
}
#endif