How to play Multiple channels from a audio Device having 8 maximum output using dsp.Audioplayer..
10 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
I have a soundcard with 8 max output channels.
>>info=dspAudioDeviceInfo
info =
15x1 struct array with fields:
name
maxInputs
maxOutputs
>> info(12,1)
ans =
name: 'Haut-parleurs (4- USB Multi-Channel Audio Device) (Windows DirectSound)'
maxInputs: 0
maxOutputs: 8
The code I`m using to play is as following
hafr = dsp.AudioFileReader('sig8.wav');
hap = dsp.AudioPlayer('SampleRate',44100);
hap.DeviceName='Haut-parleurs (4- USB Multi-Channel Audio Device)';
while ~isDone(hafr)
audio = step(hafr);
step(hap,audio);
end
pause(hap.QueueDuration); % Wait until audio plays to the end
release(hafr); % close input file, release resources
release(hap); % close audio output device, release resources
The output comes from only two channels and all the 8 channels sound is there in those two channels...
0 Commenti
Risposte (0)
Vedere anche
Categorie
Scopri di più su Audio and Video Data in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!