351 |
bend_up = 200; |
bend_up = 200; |
352 |
bend_down = -200; |
bend_down = -200; |
353 |
bend_step = 1; |
bend_step = 1; |
354 |
|
|
355 |
|
pitch_oncc.clear(); |
356 |
|
pitch_smoothcc.clear(); |
357 |
|
pitch_curvecc.clear(); |
358 |
|
pitch_stepcc.clear(); |
359 |
|
|
360 |
// filter |
// filter |
361 |
fil_type = LPF_2P; |
fil_type = LPF_2P; |
678 |
region->bend_up = bend_up; |
region->bend_up = bend_up; |
679 |
region->bend_down = bend_down; |
region->bend_down = bend_down; |
680 |
region->bend_step = bend_step; |
region->bend_step = bend_step; |
681 |
|
|
682 |
|
region->pitch_oncc = pitch_oncc; |
683 |
|
region->pitch_smoothcc = pitch_smoothcc; |
684 |
|
region->pitch_curvecc = pitch_curvecc; |
685 |
|
region->pitch_stepcc = pitch_stepcc; |
686 |
|
|
687 |
// filter |
// filter |
688 |
region->fil_type = fil_type; |
region->fil_type = fil_type; |
1040 |
copySmoothValues(r->volume_smoothcc, r->volume_oncc); |
copySmoothValues(r->volume_smoothcc, r->volume_oncc); |
1041 |
r->volume_smoothcc.clear(); |
r->volume_smoothcc.clear(); |
1042 |
|
|
1043 |
|
copyCurves(r->pitch_curvecc, r->pitch_oncc); |
1044 |
|
r->pitch_curvecc.clear(); |
1045 |
|
|
1046 |
|
copySmoothValues(r->pitch_smoothcc, r->pitch_oncc); |
1047 |
|
r->pitch_smoothcc.clear(); |
1048 |
|
|
1049 |
|
copyStepValues(r->pitch_stepcc, r->pitch_oncc); |
1050 |
|
r->pitch_stepcc.clear(); |
1051 |
|
|
1052 |
copyCurves(r->pan_curvecc, r->pan_oncc); |
copyCurves(r->pan_curvecc, r->pan_oncc); |
1053 |
r->pan_curvecc.clear(); |
r->pan_curvecc.clear(); |
1054 |
|
|
1138 |
} |
} |
1139 |
} |
} |
1140 |
|
|
1141 |
|
void File::copyStepValues(LinuxSampler::ArrayList<CC>& steps, LinuxSampler::ArrayList<CC>& dest) { |
1142 |
|
for (int i = 0; i < steps.size(); i++) { |
1143 |
|
for (int j = 0; j < dest.size(); j++) { |
1144 |
|
if (steps[i].Controller == dest[j].Controller) { |
1145 |
|
dest[j].Step = steps[i].Step; |
1146 |
|
} |
1147 |
|
} |
1148 |
|
} |
1149 |
|
} |
1150 |
|
|
1151 |
int File::ToInt(const std::string& s) throw(LinuxSampler::Exception) { |
int File::ToInt(const std::string& s) throw(LinuxSampler::Exception) { |
1152 |
int i; |
int i; |
1153 |
std::istringstream iss(s); |
std::istringstream iss(s); |
1632 |
else if ("xfin_hi" == key_cc) pCurDef->xfin_hicc.set(num_cc, ToInt(value)); |
else if ("xfin_hi" == key_cc) pCurDef->xfin_hicc.set(num_cc, ToInt(value)); |
1633 |
else if ("xfout_lo" == key_cc) pCurDef->xfout_locc.set(num_cc, ToInt(value)); |
else if ("xfout_lo" == key_cc) pCurDef->xfout_locc.set(num_cc, ToInt(value)); |
1634 |
else if ("xfout_hi" == key_cc) pCurDef->xfout_hicc.set(num_cc, ToInt(value)); |
else if ("xfout_hi" == key_cc) pCurDef->xfout_hicc.set(num_cc, ToInt(value)); |
1635 |
|
|
1636 |
|
// pitch |
1637 |
|
else if ("pitch" == key_cc) pCurDef->pitch_oncc.add( CC(num_cc, check(key, -9600, 9600, ToInt(value))) ); |
1638 |
|
else if ("pitch_smooth" == key_cc) pCurDef->pitch_smoothcc.add( CC(num_cc, 0, -1, check(key, 0.0f, 100000.0f /* max? */, ToFloat(value))) ); |
1639 |
|
else if ("pitch_curve" == key_cc) pCurDef->pitch_curvecc.add( CC(num_cc, 0, check(key, 0, 30000, ToInt(value))) ); |
1640 |
|
else if ("pitch_step" == key_cc) pCurDef->pitch_stepcc.add( CC(num_cc, 0, -1, 0, check(key, 0, 1200, ToInt(value))) ); |
1641 |
|
|
1642 |
// filter |
// filter |
1643 |
else if ("cutoff" == key_cc || "cutoff_" == key_cc) { |
else if ("cutoff" == key_cc || "cutoff_" == key_cc) { |