aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2019-06-21 22:08:27 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2020-07-01 12:11:55 +0200
commit18beff17099fbb840f7744e890b2d6c09922c957 (patch)
treebb72e8377e21fc8a8679beaa8be1bd9b03df49da
parent5e5577ff87e14a4ac3c5c97bab76f2737e739201 (diff)
downloadffmpeg-18beff17099fbb840f7744e890b2d6c09922c957.tar.gz
avcodec/ffwavesynth: Fix backward lcg_seek()
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit cf2bd3ce79b12256d7d129b2ada5ee649b9a27eb) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavcodec/ffwavesynth.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/ffwavesynth.c b/libavcodec/ffwavesynth.c
index a66113972b..cf8c780f3e 100644
--- a/libavcodec/ffwavesynth.c
+++ b/libavcodec/ffwavesynth.c
@@ -122,7 +122,7 @@ static void lcg_seek(uint32_t *s, int64_t dt)
c = LCG_C;
} else { /* coefficients for a step backward */
a = LCG_AI;
- c = (uint32_t)(LCG_AI * LCG_C);
+ c = (uint32_t)(-LCG_AI * LCG_C);
dt = -dt;
}
while (dt) {