Mercurial > hg > svcore
diff data/model/ReadOnlyWaveFileModel.cpp @ 1280:c97a28a3baeb 3.0-integration
Trivial loop reordering for sequential index
author | Chris Cannam |
---|---|
date | Wed, 23 Nov 2016 10:34:30 +0000 |
parents | a68d407f9752 |
children | ff9697592bef |
line wrap: on
line diff
--- a/data/model/ReadOnlyWaveFileModel.cpp Tue Nov 22 16:40:41 2016 +0000 +++ b/data/model/ReadOnlyWaveFileModel.cpp Wed Nov 23 10:34:30 2016 +0000 @@ -234,8 +234,8 @@ } } else { // channel == -1, mix down all channels - for (int c = 0; c < channels; ++c) { - for (int i = 0; i < obtained; ++i) { + for (int i = 0; i < obtained; ++i) { + for (int c = 0; c < channels; ++c) { result[i] += interleaved[i * channels + c]; } }