From 5b3705660dd075ed249b3f18ef106e71f259af21 Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Sun, 11 Jan 2015 04:51:07 +0200 Subject: ZVISION: Avoid using floating point math when upscaling subtitle timing Spotted by clone2727 --- engines/zvision/text/subtitles.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'engines/zvision') diff --git a/engines/zvision/text/subtitles.cpp b/engines/zvision/text/subtitles.cpp index d549e2a0c6..ffc9e2b808 100644 --- a/engines/zvision/text/subtitles.cpp +++ b/engines/zvision/text/subtitles.cpp @@ -71,8 +71,8 @@ Subtitle::Subtitle(ZVision *engine, const Common::String &subname, bool upscaleT if (sb <= (int32)_subs.size()) { if (upscaleToHires) { // Convert from 15FPS (AVI) to 29.97FPS (VOB) - st = st * 29.97 / 15; - en = en * 29.97 / 15; + st = st * 2997 / 1500; + en = en * 2997 / 1500; } _subs[sb].start = st; _subs[sb].stop = en; -- cgit v1.2.3