From 963247b5f36a70f0ea083f5f43356d498fd85c47 Mon Sep 17 00:00:00 2001 From: Michael Niedermayer Date: Sun, 1 Oct 2017 18:10:36 +0200 Subject: avcodec/dvbsubdec: Split best score computation out of loop in compute_default_clut() 3% faster Signed-off-by: Michael Niedermayer --- libavcodec/dvbsubdec.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'libavcodec/dvbsubdec.c') diff --git a/libavcodec/dvbsubdec.c b/libavcodec/dvbsubdec.c index ef581a9a3f..85a59f3ced 100644 --- a/libavcodec/dvbsubdec.c +++ b/libavcodec/dvbsubdec.c @@ -680,14 +680,17 @@ static void compute_default_clut(AVSubtitleRect *rect, int w, int h) int l_r = x+1 bestscore) { bestscore = score; - bestv = v; + bestv = x; } } } -- cgit v1.2.3