summaryrefslogtreecommitdiffstats
path: root/libavformat/utils.c
diff options
context:
space:
mode:
authorMichael Niedermayer <[email protected]>2016-01-09 10:49:23 +0100
committerMichael Niedermayer <[email protected]>2016-01-15 17:23:54 +0100
commitc0315b74e2563f8c3b97e8ff99cd9bd12654c143 (patch)
treea9b4cfc63051018274d207e592cae6d2975d0092 /libavformat/utils.c
parent81bac54ab3cdf1cac32bc0ee84956077c5562589 (diff)
avformat: Add integer fps from 31 to 60 to get_std_framerate()
Fixes Ticket 5106 Signed-off-by: Michael Niedermayer <[email protected]> (cherry picked from commit 2039b3e7511ef183dae206575114e15b6d99c134) Signed-off-by: Michael Niedermayer <[email protected]>
Diffstat (limited to 'libavformat/utils.c')
-rw-r--r--libavformat/utils.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c
index bdcbd72201..0e23c1d4fe 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -2824,10 +2824,14 @@ static int get_std_framerate(int i)
return (i + 1) * 1001;
i -= 30*12;
- if (i < 7)
- return ((const int[]) { 40, 48, 50, 60, 80, 120, 240})[i] * 1001 * 12;
+ if (i < 30)
+ return (i + 31) * 1001 * 12;
+ i -= 30;
- i -= 7;
+ if (i < 3)
+ return ((const int[]) { 80, 120, 240})[i] * 1001 * 12;
+
+ i -= 3;
return ((const int[]) { 24, 30, 60, 12, 15, 48 })[i] * 1000 * 12;
}