summaryrefslogtreecommitdiff
path: root/rotord
diff options
context:
space:
mode:
Diffstat (limited to 'rotord')
-rw-r--r--rotord/src/rotor.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/rotord/src/rotor.h b/rotord/src/rotor.h
index b95a7b0..bf54883 100644
--- a/rotord/src/rotor.h
+++ b/rotord/src/rotor.h
@@ -1009,7 +1009,7 @@ namespace Rotor {
if (track_time<start_silence){
amount=0.0f;
}
- else if (track_time<start_peak&&attributes["begin_mode"]->value=="fade peak"){
+ else if (track_time<start_peak&&attributes["begin_mode"]->value=="fade peak"&&start_peak>start_silence){
amount = (track_time-start_silence)/(start_peak-start_silence);
}
}
@@ -1017,7 +1017,7 @@ namespace Rotor {
if (track_time>end_silence){
amount=0.0f;
}
- else if (track_time>end_peak&&attributes["end_mode"]->value=="fade peak"){
+ else if (track_time>end_peak&&attributes["end_mode"]->value=="fade peak"&&end_silence>end_peak){
amount = 1.0f-((track_time-end_peak)/(end_silence-end_peak));
}
}