| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
#include <boca.h> |
| 14 |
#include "dllinterface.h" |
| 15 |
|
| 16 |
BoCA_BEGIN_COMPONENT(EncoderWMA) |
| 17 |
|
| 18 |
namespace BoCA |
| 19 |
{ |
| 20 |
class EncoderWMA : public CS::EncoderComponent |
| 21 |
{ |
| 22 |
private: |
| 23 |
ConfigLayer *configLayer; |
| 24 |
Config *config; |
| 25 |
|
| 26 |
IWMWriter *writer; |
| 27 |
IWMWriterAdvanced *writerAdvanced; |
| 28 |
|
| 29 |
IWMWriterFileSink *writerFileSink; |
| 30 |
|
| 31 |
IWMProfileManager *profileManager; |
| 32 |
IWMProfile *profile; |
| 33 |
|
| 34 |
IWMStreamConfig *streamConfig; |
| 35 |
|
| 36 |
Int64 samplesWritten; |
| 37 |
|
| 38 |
Buffer<signed short> samplesBuffer; |
| 39 |
|
| 40 |
static Int GetDefaultCodec(IWMCodecInfo3 *); |
| 41 |
IWMStreamConfig *GetBestCodecFormat(IWMCodecInfo3 *, DWORD, const Format &) const; |
| 42 |
|
| 43 |
Bool SetInputFormat(IWMWriter *, const Format &); |
| 44 |
|
| 45 |
static Bool ConvertArguments(Config *); |
| 46 |
public: |
| 47 |
static const String &GetComponentSpecs(); |
| 48 |
|
| 49 |
static Void Initialize(); |
| 50 |
static Void Cleanup(); |
| 51 |
|
| 52 |
EncoderWMA(); |
| 53 |
~EncoderWMA(); |
| 54 |
|
| 55 |
Int GetNumberOfPasses() const; |
| 56 |
|
| 57 |
Bool IsLossless() const; |
| 58 |
|
| 59 |
Bool Activate(); |
| 60 |
Bool Deactivate(); |
| 61 |
|
| 62 |
Int WriteData(Buffer<UnsignedByte> &); |
| 63 |
Bool NextPass(); |
| 64 |
|
| 65 |
Bool SetOutputFormat(Int); |
| 66 |
|
| 67 |
ConfigLayer *GetConfigurationLayer(); |
| 68 |
}; |
| 69 |
}; |
| 70 |
|
| 71 |
BoCA_DEFINE_ENCODER_COMPONENT(EncoderWMA) |
| 72 |
|
| 73 |
BoCA_END_COMPONENT(EncoderWMA) |