58 return (adod ==
NULL) ||
68 TRACE(
"(%d)\n", dwDevID);
73#define NUM_OF(a,b) ((a)/(b))
99 {1, 8, 8000}, {2, 8, 8000}, {1, 16, 8000}, {2, 16, 8000}, {1, 24, 8000}, {2, 24, 8000},
100 {1, 8, 11025}, {2, 8, 11025}, {1, 16, 11025}, {2, 16, 11025}, {1, 24, 11025}, {2, 24, 11025},
101 {1, 8, 22050}, {2, 8, 22050}, {1, 16, 22050}, {2, 16, 22050}, {1, 24, 22050}, {2, 24, 22050},
102 {1, 8, 44100}, {2, 8, 44100}, {1, 16, 44100}, {2, 16, 44100}, {1, 24, 44100}, {2, 24, 44100},
103 {1, 8, 48000}, {2, 8, 48000}, {1, 16, 48000}, {2, 16, 48000}, {1, 24, 48000}, {2, 24, 48000},
104 {1, 8, 96000}, {2, 8, 96000}, {1, 16, 96000}, {2, 16, 96000}, {1, 24, 96000}, {2, 24, 96000},
113 TRACE(
"(%p)\n", wfx);
141static inline short C816(
unsigned char b)
143 return (
b - 128) << 8;
151static inline unsigned char C168(
short s)
161static inline unsigned char C248(
int s)
181static inline short R16(
const unsigned char*
src)
183 return (
short)((
unsigned short)
src[0] | ((
unsigned short)
src[1] << 8));
193static inline int R24(
const unsigned char*
src)
195 return ((
int)
src[0] | (
int)
src[1] << 8 | (
int)
src[2] << 16) << 8;
203static inline void W16(
unsigned char*
dst,
short s)
214static inline void W24(
unsigned char*
dst,
int s)
232 if (
sum > 0x7fffff00)
234 else if (
sum < -0x7fffff00)
246static inline short M16(
short l,
short r)
253 else if (
sum < -32768)
265static inline unsigned char M8(
unsigned char a,
unsigned char b)
269 int sum = (
l +
r) + 128;
550 DWORD maxSrc = *nsrc, maxDst = *ndst;
552 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
554 while (
error > srcRate) {
571 DWORD maxSrc = *nsrc, maxDst = *ndst;
573 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
575 while (
error > srcRate) {
591 DWORD maxSrc = *nsrc, maxDst = *ndst;
593 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
595 while (
error > srcRate) {
612 DWORD maxSrc = *nsrc, maxDst = *ndst;
614 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
616 while (
error > srcRate) {
632 DWORD maxSrc = *nsrc, maxDst = *ndst;
634 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
636 while (
error > srcRate) {
653 DWORD maxSrc = *nsrc, maxDst = *ndst;
655 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
657 while (
error > srcRate) {
673 DWORD maxSrc = *nsrc, maxDst = *ndst;
675 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
677 while (
error > srcRate) {
694 DWORD maxSrc = *nsrc, maxDst = *ndst;
696 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
698 while (
error > srcRate) {
714 DWORD maxSrc = *nsrc, maxDst = *ndst;
716 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
718 while (
error > srcRate) {
735 DWORD maxSrc = *nsrc, maxDst = *ndst;
737 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
739 while (
error > srcRate) {
755 DWORD maxSrc = *nsrc, maxDst = *ndst;
757 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
759 while (
error > srcRate) {
776 DWORD maxSrc = *nsrc, maxDst = *ndst;
778 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
780 while (
error > srcRate) {
796 DWORD maxSrc = *nsrc, maxDst = *ndst;
798 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
800 while (
error > srcRate) {
817 DWORD maxSrc = *nsrc, maxDst = *ndst;
819 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
821 while (
error > srcRate) {
837 DWORD maxSrc = *nsrc, maxDst = *ndst;
839 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
841 while (
error > srcRate) {
858 DWORD maxSrc = *nsrc, maxDst = *ndst;
860 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
862 while (
error > srcRate) {
878 DWORD maxSrc = *nsrc, maxDst = *ndst;
880 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
882 while (
error > srcRate) {
899 DWORD maxSrc = *nsrc, maxDst = *ndst;
901 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
903 while (
error > srcRate) {
919 DWORD maxSrc = *nsrc, maxDst = *ndst;
921 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
923 while (
error > srcRate) {
940 DWORD maxSrc = *nsrc, maxDst = *ndst;
942 for (*nsrc = 0; *nsrc < maxSrc; (*nsrc)++) {
944 while (
error > srcRate) {
974 TRACE(
"(%p)\n", add);
1004 TRACE(
"(%p, %08x)\n", aftd, dwQuery);
1009 WARN(
"not possible\n");
1015 WARN(
"not possible\n");
1022 WARN(
"not possible\n");
1027 WARN(
"Unsupported query %08x\n", dwQuery);
1047 TRACE(
"(%p, %08x)\n", afd, dwQuery);
1052 WARN(
"not possible\n");
1071 WARN(
"Unsupported query %08x\n", dwQuery);
1089 TRACE(
"(%p)\n", adfs);
1095 WARN(
"not possible\n");
1123 WARN(
"not possible\n");
1144 TRACE(
"(%p)\n", adsi);
1157 FIXME(
"Source: 24-bit samples must be packed\n");
1175 FIXME(
"Destination: 24-bit samples must be packed\n");
1202 FIXME(
"Unimplemented conversion from %u -> %u bps\n",
1221 TRACE(
"(%p)\n", adsi);
1235 return ((
double)
a * (
double)
b + (
double)
c - 1) / (
double)
c;
1247 TRACE(
"(%p, %p)\n", adsi, adss);
1279 TRACE(
"(%p, %p)\n", adsi, adsh);
1283 TRACE(
"src [wFormatTag=%u, nChannels=%u, nSamplesPerSec=%u, nAvgBytesPerSec=%u, nBlockAlign=%u, wBitsPerSample=%u, cbSize=%u]\n",
1286 TRACE(
"dst [wFormatTag=%u, nChannels=%u, nSamplesPerSec=%u, nAvgBytesPerSec=%u, nBlockAlign=%u, wBitsPerSample=%u, cbSize=%u]\n",
1294 FIXME(
"Unsupported fdwConvert (%08x), ignoring it\n", adsh->
fdwConvert);
1310 if (nsrc < ndst) ndst = nsrc;
else nsrc = ndst;
1328 TRACE(
"(%08lx %p %u %08lx %08lx);\n",
1329 dwDevID, hDriv, wMsg, dwParam1, dwParam2);
1385 return DefDriverProc(dwDevID, hDriv, wMsg, dwParam1, dwParam2);
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
#define HeapFree(x, y, z)
#define MultiByteToWideChar
unsigned int(__cdecl typeof(jpeg_read_scanlines))(struct jpeg_decompress_struct *
unsigned short(__cdecl typeof(TIFFCurrentDirectory))(struct tiff *)
LRESULT WINAPI DefDriverProc(DWORD_PTR dwDriverIdentifier, HDRVR hDrv, UINT Msg, LPARAM lParam1, LPARAM lParam2)
GLdouble GLdouble GLdouble r
GLboolean GLboolean GLboolean b
GLboolean GLboolean GLboolean GLboolean a
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define memcpy(s1, s2, n)
#define WAVE_FORMAT_UNKNOWN
#define DRV_QUERYCONFIGURE
#define MMSYSERR_NOTSUPPORTED
struct pcmwaveformat_tag PCMWAVEFORMAT
static const char mbstate_t *static wchar_t const char mbstate_t *static const wchar_t int *static double
#define ACMDRIVERDETAILS_SUPPORTF_CONVERTER
#define ACM_STREAMCONVERTF_START
#define ACM_FORMATTAGDETAILSF_FORMATTAG
#define ACM_STREAMCONVERTF_BLOCKALIGN
#define ACM_STREAMOPENF_ASYNC
#define ACMDRIVERDETAILS_FCCCOMP_UNDEFINED
#define ACM_FORMATSUGGESTF_WFORMATTAG
#define ACM_FORMATSUGGESTF_NCHANNELS
#define ACMERR_NOTPOSSIBLE
#define ACM_FORMATDETAILSF_FORMAT
#define ACM_STREAMSIZEF_SOURCE
#define ACM_FORMATTAGDETAILSF_LARGESTSIZE
#define ACM_STREAMSIZEF_DESTINATION
#define ACM_FORMATDETAILSF_INDEX
#define ACM_FORMATTAGDETAILSF_INDEX
#define ACM_FORMATSUGGESTF_WBITSPERSAMPLE
#define ACM_STREAMCONVERTF_END
#define ACMDRIVERDETAILS_FCCTYPE_AUDIOCODEC
#define ACM_FORMATSUGGESTF_NSAMPLESPERSEC
#define ACMDM_STREAM_PREPARE
#define ACMDM_STREAM_CLOSE
#define ACMDM_STREAM_CONVERT
#define ACMDM_FORMAT_SUGGEST
#define ACMDM_FILTER_DETAILS
#define ACMDM_HARDWARE_WAVE_CAPS_INPUT
#define ACMDM_DRIVER_NOTIFY
#define ACMDM_FORMAT_DETAILS
#define ACMDM_STREAM_SIZE
#define ACMDM_FILTERTAG_DETAILS
#define ACMDM_HARDWARE_WAVE_CAPS_OUTPUT
#define ACMDM_FORMATTAG_DETAILS
#define ACMDM_STREAM_UNPREPARE
#define ACMDM_STREAM_OPEN
#define ACMDM_DRIVER_DETAILS
#define ACMDM_STREAM_RESET
static void cvtSS88K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtMS816C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtSS88C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static const PCM_CONVERT_CHANGE_RATE PCM_ConvertChangeRate[]
static void cvtMS168K(const unsigned char *src, int ns, unsigned char *dst)
static int R24(const unsigned char *src)
static void cvtSM816C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtMS88C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static short M16(short l, short r)
void(* PCM_CONVERT_CHANGE_RATE)(const DWORD, const unsigned char *, DWORD *, const DWORD, unsigned char *, DWORD *)
static LRESULT PCM_StreamOpen(PACMDRVSTREAMINSTANCE adsi)
static void cvtMM816K(const unsigned char *src, int ns, unsigned char *dst)
static DWORD PCM_GetFormatIndex(LPWAVEFORMATEX wfx)
static const struct @480 PCM_Formats[]
static unsigned char C248(int s)
static short C816(unsigned char b)
static DWORD PCM_drvOpen(LPCSTR str, PACMDRVOPENDESCW adod)
void(* PCM_CONVERT_KEEP_RATE)(const unsigned char *, int, unsigned char *)
LRESULT CALLBACK PCM_DriverProc(DWORD_PTR dwDevID, HDRVR hDriv, UINT wMsg, LPARAM dwParam1, LPARAM dwParam2)
static void cvtSM2424C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtSM1616K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtSS248K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtSS2416K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtSS2424C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtMM2424C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void W24(unsigned char *dst, int s)
static void cvtMS2416K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtMS168C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtMS1616K(const unsigned char *src, int ns, unsigned char *dst)
static LRESULT PCM_StreamConvert(PACMDRVSTREAMINSTANCE adsi, PACMDRVSTREAMHEADER adsh)
static void cvtSS816C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtSS1616K(const unsigned char *src, int ns, unsigned char *dst)
static LRESULT PCM_DriverDetails(PACMDRIVERDETAILSW add)
static void cvtSM248K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtMM88K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtSS168C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtSM2416K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtMM168K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtSS168K(const unsigned char *src, int ns, unsigned char *dst)
static LRESULT PCM_FormatDetails(PACMFORMATDETAILSW afd, DWORD dwQuery)
static void cvtMM1616C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static unsigned char C168(short s)
static LRESULT PCM_FormatTagDetails(PACMFORMATTAGDETAILSW aftd, DWORD dwQuery)
static void cvtSM168C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static LRESULT PCM_StreamSize(PACMDRVSTREAMINSTANCE adsi, PACMDRVSTREAMSIZE adss)
static void cvtSS1616C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void W16(unsigned char *dst, short s)
static DWORD PCM_drvClose(DWORD dwDevID)
static const PCM_CONVERT_KEEP_RATE PCM_ConvertKeepRate[]
static void cvtMM248K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtSS816K(const unsigned char *src, int ns, unsigned char *dst)
static unsigned char M8(unsigned char a, unsigned char b)
static short C2416(int s)
static int M24(int l, int r)
static void cvtMS88K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtMM168C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtMM2416K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtMM88C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtMS248K(const unsigned char *src, int ns, unsigned char *dst)
struct tagAcmPcmData AcmPcmData
static void cvtSM816K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtSM168K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtMM1616K(const unsigned char *src, int ns, unsigned char *dst)
static LRESULT PCM_FormatSuggest(PACMDRVFORMATSUGGEST adfs)
static void cvtMS2424C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static DWORD PCM_round(DWORD a, DWORD b, DWORD c)
static void cvtMM816C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtMS1616C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtSM88C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtSM88K(const unsigned char *src, int ns, unsigned char *dst)
static void cvtSM1616C(const DWORD srcRate, const unsigned char *src, DWORD *nsrc, const DWORD dstRate, unsigned char *dst, DWORD *ndst)
static void cvtMS816K(const unsigned char *src, int ns, unsigned char *dst)
static short R16(const unsigned char *src)
static LRESULT PCM_StreamClose(PACMDRVSTREAMINSTANCE adsi)
static int sum(int x_, int y_)
WCHAR szCopyright[ACMDRIVERDETAILS_COPYRIGHT_CHARS]
WCHAR szLongName[ACMDRIVERDETAILS_LONGNAME_CHARS]
WCHAR szShortName[ACMDRIVERDETAILS_SHORTNAME_CHARS]
WCHAR szLicensing[ACMDRIVERDETAILS_LICENSING_CHARS]
WCHAR szFeatures[ACMDRIVERDETAILS_FEATURES_CHARS]
PCM_CONVERT_KEEP_RATE cvtKeepRate
PCM_CONVERT_CHANGE_RATE cvtChangeRate
union tagAcmPcmData::@481 cvt
int WINAPI MessageBoxA(_In_opt_ HWND hWnd, _In_opt_ LPCSTR lpText, _In_opt_ LPCSTR lpCaption, _In_ UINT uType)