diff options
author | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
---|---|---|
committer | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
commit | 20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (patch) | |
tree | 12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/Plugins/Encoder/enc_wav/ACMEncoder.h | |
parent | 537bcbc86291b32fc04ae4133ce4d7cac8ebe9a7 (diff) | |
download | winamp-20d28e80a5c861a9d5f449ea911ab75b4f37ad0d.tar.gz |
Initial community commit
Diffstat (limited to 'Src/Plugins/Encoder/enc_wav/ACMEncoder.h')
-rw-r--r-- | Src/Plugins/Encoder/enc_wav/ACMEncoder.h | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/Src/Plugins/Encoder/enc_wav/ACMEncoder.h b/Src/Plugins/Encoder/enc_wav/ACMEncoder.h new file mode 100644 index 00000000..deb95968 --- /dev/null +++ b/Src/Plugins/Encoder/enc_wav/ACMEncoder.h @@ -0,0 +1,47 @@ +#ifndef NULLSOFT_ENC_ACM_ACMENCODER_H +#define NULLSOFT_ENC_ACM_ACMENCODER_H + +#include <windows.h> +#include <mmreg.h> +#include <msacm.h> +#include "../nsv/enc_if.h" +#include "Config.h" +#include "Finisher.h" + +class ACMEncoder : public AudioCommon +{ +public: + ACMEncoder(int srate, int nch, int bps, ACMConfig *config); + virtual ~ACMEncoder(); + + virtual int Encode(int framepos, void *in, int in_avail, int *in_used, void *out, int out_avail); + void FinishAudio(const wchar_t *filename); + + int GetLastError(); + + int m_did_header; + int m_nch, m_srate, m_bps; + int m_bytes_done; + int m_error; + int m_hlen; + int m_nsam; + + EXT_WFX m_convert_wfx; + + WAVEFORMATEX m_wfx_src; + HACMSTREAM hStream, hStreamResample; + + ACMSTREAMHEADER ahd, ahdResample; + + unsigned char *m_acm_buf, *m_acm_outbuf; + int m_bytes_inbuf, m_bytes_outbuf; + unsigned char *m_acm_resample_buf, *m_acm_resample_outbuf; + int m_bytes_inbuf_resample, m_bytes_outbuf_resample; + + bool do_header; + +}; + + + +#endif
\ No newline at end of file |