Mercurial > hg > beaglert
comparison core/RTAudio.cpp @ 375:768acdeea362 prerelease
Merge
author | Giulio Moro <giuliomoro@yahoo.it> |
---|---|
date | Fri, 10 Jun 2016 00:35:18 +0100 |
parents | 3bed6b09223c |
children | a0698d523a6a |
comparison
equal
deleted
inserted
replaced
374:ecad1ea0382a | 375:768acdeea362 |
---|---|
150 return -1; | 150 return -1; |
151 } | 151 } |
152 } | 152 } |
153 | 153 |
154 // Limit the analog channels to sane values | 154 // Limit the analog channels to sane values |
155 if(settings->numAnalogChannels >= 8) | 155 if(settings->numAnalogChannels != 2 |
156 settings->numAnalogChannels = 8; | 156 && settings->numAnalogChannels != 4 |
157 else if(settings->numAnalogChannels >= 4) | 157 && settings->numAnalogChannels != 8) { |
158 settings->numAnalogChannels = 4; | 158 cout << "Invalid number of analog channels: " << settings->numAnalogChannels << ". Valid values are 2, 4, 8.\n"; |
159 else | 159 return -1; |
160 settings->numAnalogChannels = 2; | 160 } |
161 | 161 |
162 // Initialise the rendering environment: sample rates, frame counts, numbers of channels | 162 // Initialise the rendering environment: sample rates, frame counts, numbers of channels |
163 gContext.audioSampleRate = 44100.0; | 163 gContext.audioSampleRate = 44100.0; |
164 gContext.audioChannels = 2; | 164 gContext.audioChannels = 2; |
165 | 165 |