From 117bcfde95058bbc85f7f720a8e1cad40ddc7ca7 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Thu, 26 Nov 2009 00:42:24 +0000 Subject: Remove dependancy on STL. svn-id: r46144 --- engines/scumm/player_sid.cpp | 31 +++++++++++++++---------------- 1 file changed, 15 insertions(+), 16 deletions(-) (limited to 'engines') diff --git a/engines/scumm/player_sid.cpp b/engines/scumm/player_sid.cpp index 2a0a399198..67d5fba7fe 100644 --- a/engines/scumm/player_sid.cpp +++ b/engines/scumm/player_sid.cpp @@ -23,7 +23,6 @@ * */ -#include #include "engines/engine.h" #include "scumm/player_sid.h" #include "scumm/scumm.h" @@ -755,22 +754,22 @@ void Player_SID::stopChannel(int channel) { // channel: 0..6, swapIndex: 0..2 void Player_SID::swapVars(int channel, int swapIndex) { // $51a5 if (channel < 3) { - std::swap(attackReg[channel], swapAttack[swapIndex]); - std::swap(sustainReg[channel], swapSustain[swapIndex]); + SWAP(attackReg[channel], swapAttack[swapIndex]); + SWAP(sustainReg[channel], swapSustain[swapIndex]); } - //std::swap(vec5[channel], swapVec5[swapIndex]); // not used - //std::swap(vec19[channel], swapVec19[swapIndex]); // not used - - std::swap(chanPrio[channel], swapSongPrio[swapIndex]); - std::swap(channelMap[channel], swapVec479C[swapIndex]); - std::swap(songPosUpdateCounter[channel], swapSongPosUpdateCounter[swapIndex]); - std::swap(waveCtrlReg[channel], swapWaveCtrlReg[swapIndex]); - std::swap(songPosPtr[channel], swapSongPosPtr[swapIndex]); - std::swap(freqReg[channel], swapFreqReg[swapIndex]); - std::swap(freqDeltaCounter[channel], swapVec11[swapIndex]); - std::swap(freqDelta[channel], swapVec10[swapIndex]); - std::swap(vec20[channel], swapVec20[swapIndex]); - std::swap(songFileOrChanBufOffset[channel], swapVec8[swapIndex]); + //SWAP(vec5[channel], swapVec5[swapIndex]); // not used + //SWAP(vec19[channel], swapVec19[swapIndex]); // not used + + SWAP(chanPrio[channel], swapSongPrio[swapIndex]); + SWAP(channelMap[channel], swapVec479C[swapIndex]); + SWAP(songPosUpdateCounter[channel], swapSongPosUpdateCounter[swapIndex]); + SWAP(waveCtrlReg[channel], swapWaveCtrlReg[swapIndex]); + SWAP(songPosPtr[channel], swapSongPosPtr[swapIndex]); + SWAP(freqReg[channel], swapFreqReg[swapIndex]); + SWAP(freqDeltaCounter[channel], swapVec11[swapIndex]); + SWAP(freqDelta[channel], swapVec10[swapIndex]); + SWAP(vec20[channel], swapVec20[swapIndex]); + SWAP(songFileOrChanBufOffset[channel], swapVec8[swapIndex]); } void Player_SID::resetSwapVars() { // $52d0 -- cgit v1.2.3