| 202 | } |
| 203 | |
| 204 | void |
| 205 | SamplerDialog::feedSet(WaveSampleSet const &set) |
| 206 | { |
| 207 | if (this->decider.getDecisionMode() == Decider::MODULUS) { |
| 208 | for (SUSCOUNT i = 0; i < set.len; ++i) { |
| 209 | SUFLOAT amp = SU_C_ABS(set.block[i]); |
| 210 | if (amp > this->maxVal) |
| 211 | this->maxVal = SU_C_ABS(set.block[i]); |
| 212 | if (amp < this->minVal) |
| 213 | this->minVal = SU_C_ABS(set.block[i]); |
| 214 | } |
| 215 | } else { |
| 216 | for (SUSCOUNT i = 0; i < set.len; ++i) { |
| 217 | SUFLOAT arg = SU_C_ARG(set.block[i]); |
| 218 | if (arg > this->maxVal) |
| 219 | this->maxVal = SU_C_ARG(set.block[i]); |
| 220 | if (arg < this->minVal) |
| 221 | this->minVal = SU_C_ARG(set.block[i]); |
| 222 | } |
| 223 | } |
| 224 | |
| 225 | this->ui->histogram->feed(set.block, set.len); |
| 226 | this->ui->symView->feed(set.symbols, set.len); |
| 227 | |
| 228 | this->refreshHScrollBar(); |
| 229 | this->refreshVScrollBar(); |
| 230 | } |
| 231 | |
| 232 | WaveSampler * |
| 233 | SamplerDialog::makeSampler(void) |
no test coverage detected