
AZJIO, thanks for the back info : I am coding on the 2016 version !!!
(44.1 KHz 16 bits 1 channel. Short note, I prefer let our friend infratec manage high-end : 44.1 KHz 24 bits 2 channels or more ! Maybe ADPCM also... "deutsche Qualität" !)
fixed for LTS version :
Code: Select all
structure wav
array w.w(21)
endStructure
initSound()
*wav.wav = allocateMemory(sizeOf(wav) )
initializeStructure(*wav, wav)
base64decoder("UklGRgAAAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQ", @*wav\w(0), 40)
with *wav
wMax = 62800
reDim \w(wMax + 22)
size = (wMax + 23) * 2
PokeL(@\w(2), size - 8)
PokeL(@\w(20), size - 44)
ampli.d = 800
for i = 0 to wMax
\w(i + 22) = cos(i / (7 - sin(t.d) ) ) * ampli
ampli * 0.999
t + 0.00015
next
snd = catchSound(#pb_any, @\w(0) )
repeat
playSound(snd, #pb_sound_multiChannel)
delay(400)
until inputRequester("", "Just press enter to play", "")
endWith