2 |
* * |
* * |
3 |
* LinuxSampler - modular, streaming capable sampler * |
* LinuxSampler - modular, streaming capable sampler * |
4 |
* * |
* * |
5 |
* Copyright (C) 2010 Andreas Persson * |
* Copyright (C) 2010 - 2012 Andreas Persson * |
6 |
* * |
* * |
7 |
* This program is free software; you can redistribute it and/or modify * |
* This program is free software; you can redistribute it and/or modify * |
8 |
* it under the terms of the GNU General Public License as published by * |
* it under the terms of the GNU General Public License as published by * |
279 |
if (nbDimensions) { |
if (nbDimensions) { |
280 |
int c = len[nbDimensions - 1]; |
int c = len[nbDimensions - 1]; |
281 |
for (dim = nbDimensions - 2 ; dim >= 0 ; dim--) { |
for (dim = nbDimensions - 2 ; dim >= 0 ; dim--) { |
282 |
for (int i = 0 ; i < 128 ; i++) mapArr[dim][i] *= c; |
const DimDef& dimDef = dimDefs[dims[dim]]; |
283 |
|
int max = dimDef.max == -1 ? 127 : dimDef.max; |
284 |
|
for (int i = dimDef.min ; i <= max ; i++) mapArr[dim][i] *= c; |
285 |
c *= len[dim]; |
c *= len[dim]; |
286 |
} |
} |
287 |
} |
} |