Alexander Galkin wrote:
[...]
seems deals with PCM audio, but there is no documentation about it. Does any
one have any information about how to play raw PCM on Palm OS 5 powered Sony
Clie.
[...]
Yes, I think so:



else if (SonySMLibRefNum)
{
// This structure specifies the PCM data format.
SndPcmFormatType format;
// This structure is passed to the SndPlayPcm function as the value of the selP parameter.
SndPcmOptionsType options;

format.formatTag = 0x20;
format.numOfChan = 1;
format.samplePerSec = 8000;
format.bitPerSample = 4;

if (volume_setting < 0)
options.amplitude = SoundAmp;
else
options.amplitude = volume_setting;
options.pan = 0;
options.interruptible = true;
options.dwStartMilliSec = 0;
options.dwEndMilliSec = sndSmfPlayAllMilliSec;

if ((type == SOUND_TREFFER) && soundTrefferPtr)
{
format.dataSize = soundTrefferSize - 0x2c;
SndPlayPcm(SonySMLibRefNum, NULL, sndPcmCmdPlay, soundTrefferPtr + 0x2c, &format, &options, NULL, true);
bSoundPlayed = true;
}


The sounds are adpcm files with 4 bit and 8 kHz.

Henk


--
-------------------------------------------------------------------------
[EMAIL PROTECTED] www.metaviewsoft.de

<A HREF="http://www.handango.com/PlatformTopSoftware.jsp?authorId=95946";>
<IMG SRC="http://user.cs.tu-berlin.de/~jonash/werbung_palmos.jpg";></A>
-------------------------------------------------------------------------


--
For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/


Reply via email to