The problem in changing the volume of an audio stream

I found a solution! The volume of our sound code to code play.
Of course, if you want to be the automatic channel selection use the following code:

function \_M.playStream (name, params) if not loadedSounds[name] then loadedSounds[name] = audio.loadStream(sounds[name]) end local currentChannel = audio.findFreeChannel() \_M.setVolume( params.volume, { channel = currentChannel } ) audio.play(loadedSounds[name], { channel = currentChannel, fadein = 1000, loops = params.loops or 0 }) end

Thanks all