FM-TOWNS AUDIO: minor fix in cd audio volume setting

svn-id: r52521
This commit is contained in:
Florian Kagerer 2010-09-04 11:40:24 +00:00
parent 7836bb87fd
commit 37d28b2fe5

View File

@ -1406,7 +1406,7 @@ void TownsAudioInterface::updateOutputVolume() {
// CD-AUDIO
uint32 maxVol = MAX(_outputLevel[12], _outputLevel[13]);
int volume = (int)(maxVol * (255.0f / 63.0f));
int volume = (int)(((float)(maxVol * 255) / 63.0f));
int balance = maxVol ? (int)( ( ((int)_outputLevel[13] - _outputLevel[12]) * 127) / (float)maxVol) : 0;
AudioCD.setVolume(volume);