32#elif defined(HAVE_GSM_H)
52static void *libgsm_handle;
53#define FUNCPTR(f) static typeof(f) * p##f
60#define LOAD_FUNCPTR(f) \
61 if((p##f = wine_dlsym(libgsm_handle, #f, NULL, 0)) == NULL) { \
62 wine_dlclose(libgsm_handle, NULL, 0); \
63 libgsm_handle = NULL; \
70static BOOL GSM_drvLoad(
void)
86 ERR(
"Couldn't load " SONAME_LIBGSM
": %s\n",
error);
160 WARN(
"PCM nAvgBytesPerSec %u/%u\n",
184 WARN(
"GSM wSamplesPerBlock %u\n",
188 if (wfx->nAvgBytesPerSec != wfx->nSamplesPerSec * 65 / 320)
190 WARN(
"GSM nAvgBytesPerSec %d / %d\n",
191 wfx->nAvgBytesPerSec, wfx->nSamplesPerSec * 65 / 320);
209 static const WCHAR szPcm[]={
'P',
'C',
'M',0};
210 static const WCHAR szGsm[]={
'G',
'S',
'M',
' ',
'6',
'.',
'1',
'0',0};
233 WARN(
"Unsupported query %08x\n", dwQuery);
295 WARN(
"Unsupported query %08x\n", dwQuery);
381 if (pgsm_option(
r, GSM_OPT_WAV49, &
used) < 0)
383 FIXME(
"Your libgsm library doesn't support GSM_OPT_WAV49\n");
384 FIXME(
"Please recompile libgsm with WAV49 support\n");
468 FIXME(
"Unsupported fdwConvert (%08x), ignoring it\n", adsh->
fdwConvert);
472 pgsm_option(
r, GSM_OPT_FRAME_INDEX, &
odd);
490 if (pgsm_decode(
r,
src + nsrc, (gsm_signal*)(
dst + ndst)) < 0)
491 FIXME(
"Couldn't decode data\n");
495 if (pgsm_decode(
r,
src + nsrc, (gsm_signal*)(
dst + ndst)) < 0)
496 FIXME(
"Couldn't decode data\n");
519 pgsm_encode(
r, (gsm_signal*)(
src+nsrc),
dst+ndst);
522 pgsm_encode(
r, (gsm_signal*)(
src+nsrc),
dst+ndst);
529 nsrc < adsh->cbSrcLength)
536 pgsm_encode(
r, (gsm_signal*)(
src+nsrc),
dst+ndst);
543 pgsm_encode(
r, (gsm_signal*)emptiness,
dst+ndst);
550 pgsm_encode(
r, (gsm_signal*)emptiness,
dst+ndst);
554 pgsm_encode(
r, (gsm_signal*)emptiness,
dst+ndst);
575 TRACE(
"(%08lx %p %04x %08lx %08lx);\n",
576 dwDevID, hDriv, wMsg, dwParam1, dwParam2);
642 return DefDriverProc(dwDevID, hDriv, wMsg, dwParam1, dwParam2);
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
#define MultiByteToWideChar
LRESULT WINAPI DefDriverProc(DWORD_PTR dwDriverIdentifier, HDRVR hDrv, UINT Msg, LPARAM lParam1, LPARAM lParam2)
GLdouble GLdouble GLdouble r
void * wine_dlopen(const char *filename, int flag, char *error, size_t errorsize)
int wine_dlclose(void *handle, char *error, size_t errorsize)
#define memcpy(s1, s2, n)
#define WAVE_FORMAT_UNKNOWN
struct gsm610waveformat_tag GSM610WAVEFORMAT
#define WAVE_FORMAT_GSM610
#define MM_MSFT_ACM_GSM610
#define DRV_QUERYCONFIGURE
#define MMSYSERR_NOTSUPPORTED
struct pcmwaveformat_tag PCMWAVEFORMAT
#define MMSYSERR_INVALPARAM
#define ACM_STREAMCONVERTF_START
#define ACM_FORMATTAGDETAILSF_FORMATTAG
#define ACM_STREAMCONVERTF_BLOCKALIGN
#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 ACMDRIVERDETAILS_SUPPORTF_CODEC
#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 LRESULT GSM_FormatDetails(PACMFORMATDETAILSW afd, DWORD dwQuery)
static LRESULT GSM_FormatTagDetails(PACMFORMATTAGDETAILSW aftd, DWORD dwQuery)
static LRESULT GSM_DriverDetails(PACMDRIVERDETAILSW add)
static BOOL GSM_FormatValidate(const WAVEFORMATEX *wfx)
static const DWORD gsm_rates[]
static LRESULT GSM_FormatSuggest(PACMDRVFORMATSUGGEST adfs)
static LRESULT GSM_drvFree(void)
LRESULT CALLBACK GSM_DriverProc(DWORD_PTR dwDevID, HDRVR hDriv, UINT wMsg, LPARAM dwParam1, LPARAM dwParam2)
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]
int WINAPI MessageBoxA(_In_opt_ HWND hWnd, _In_opt_ LPCSTR lpText, _In_opt_ LPCSTR lpCaption, _In_ UINT uType)