1077{
1079
1083
1084 if (auhdr.fccType == 0x0064732E) {
1085
1088
1090 auhdr.sampleRate =
LE2H_DWORD(auhdr.sampleRate);
1092 }
else if (auhdr.fccType ==
mmioFOURCC(
'.',
's',
'n',
'd')) {
1093
1096
1098 auhdr.sampleRate =
BE2H_DWORD(auhdr.sampleRate);
1100 } else
1102
1103 if (auhdr.channels < 1)
1105
1106
1107 switch(auhdr.encoding) {
1114 WARN(
"unsupported Sun audio format %d\n", auhdr.encoding);
1116 default:
1118 };
1119
1123
1124 This->lpFormat->nChannels = auhdr.channels;
1125 This->lpFormat->nSamplesPerSec = auhdr.sampleRate;
1126 switch(auhdr.encoding) {
1129 This->lpFormat->wBitsPerSample = 8;
1130 break;
1133 This->lpFormat->wBitsPerSample = 8;
1134 break;
1137 This->lpFormat->wBitsPerSample = 16;
1138 break;
1141 This->lpFormat->wBitsPerSample = 24;
1142 break;
1145 This->lpFormat->wBitsPerSample = 32;
1146 break;
1149 This->lpFormat->wBitsPerSample = 8;
1150 break;
1153 This->lpFormat->wBitsPerSample = (3*5*8);
1154 This->lpFormat->nBlockAlign = 15*15*8;
1155 This->lpFormat->cbSize =
sizeof(
WORD);
1157 break;
1160 This->lpFormat->wBitsPerSample = (3*5*8);
1161 This->lpFormat->nBlockAlign = 15*15*8;
1162 This->lpFormat->cbSize = 2*
sizeof(
WORD);
1165 break;
1166 default:
1167 WARN(
"unsupported Sun audio format %d\n", auhdr.encoding);
1169 };
1170
1171 This->lpFormat->nBlockAlign =
1172 (
This->lpFormat->nChannels *
This->lpFormat->wBitsPerSample) / 8;
1173 if (
This->lpFormat->nBlockAlign == 0 &&
This->lpFormat->wBitsPerSample < 8)
1174 This->lpFormat->nBlockAlign++;
1175 This->lpFormat->nAvgBytesPerSec =
1176 This->lpFormat->nBlockAlign *
This->lpFormat->nSamplesPerSec;
1177
1179
1181 This->sInfo.fccHandler = 0;
1182 This->sInfo.dwFlags = 0;
1183 This->sInfo.wPriority = 0;
1184 This->sInfo.wLanguage = 0;
1185 This->sInfo.dwInitialFrames = 0;
1186 This->sInfo.dwScale =
This->lpFormat->nBlockAlign;
1187 This->sInfo.dwRate =
This->lpFormat->nAvgBytesPerSec;
1188 This->sInfo.dwStart = 0;
1189 This->sInfo.dwLength =
1190 This->ckData.cksize /
This->lpFormat->nBlockAlign;
1191 This->sInfo.dwSuggestedBufferSize =
This->sInfo.dwLength;
1192 This->sInfo.dwSampleSize =
This->lpFormat->nBlockAlign;
1193
1194 This->fInfo.dwStreams = 1;
1195 This->fInfo.dwScale = 1;
1196 This->fInfo.dwRate =
This->lpFormat->nSamplesPerSec;
1197 This->fInfo.dwLength =
1199 This->lpFormat->nAvgBytesPerSec);
1200
1202}
#define WAVE_FORMAT_MULAW
struct g721_adpcmwaveformat_tag G721_ADPCMWAVEFORMAT
#define WAVE_FORMAT_G721_ADPCM
G721_ADPCMWAVEFORMAT * LPG721_ADPCMWAVEFORMAT
struct g723_adpcmwaveformat_tag G723_ADPCMWAVEFORMAT
G723_ADPCMWAVEFORMAT * LPG723_ADPCMWAVEFORMAT
#define WAVE_FORMAT_G723_ADPCM
#define mmioFOURCC(c0, c1, c2, c3)
INT WINAPI MulDiv(INT nNumber, INT nNumerator, INT nDenominator)
#define AVIERR_UNSUPPORTED
#define AU_ENCODING_PCM_24
#define AU_ENCODING_PCM_16
#define AU_ENCODING_ALAW_8
#define AU_ENCODING_ADPCM_G721_32
#define AU_ENCODING_ADPCM_G723_24
#define AU_ENCODING_ULAW_8
#define AU_ENCODING_PCM_32
#define AU_ENCODING_ADPCM_G723_5
#define AU_ENCODING_ADPCM_G722
#define AU_ENCODING_PCM_8