[vte] sixel: Fix pixel aspect calculation



commit 260416dfc4a93b8e202e09acfcc30e2063d7f37e
Author: Christian Persch <chpe src gnome org>
Date:   Sat Apr 3 16:07:50 2021 +0200

    sixel: Fix pixel aspect calculation

 src/sixel-context.hh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/sixel-context.hh b/src/sixel-context.hh
index 43a01d42..b3adea86 100644
--- a/src/sixel-context.hh
+++ b/src/sixel-context.hh
@@ -507,7 +507,7 @@ private:
                 /* VTE doesn't currently use the pixel aspect ratio */
                 auto const aspect_num = seq.param(0, 1, 1, 1 << 15 /* 32Ki */);
                 auto const aspect_den = seq.param(1, 1, 1, 1 << 15 /* 32Ki */);
-                auto const pixel_aspect = std::clamp(aspect_num / aspect_den, 0.1, 10.0);
+                auto const pixel_aspect = std::clamp(double(aspect_num) / double(aspect_den), 0.1, 10.0);
                 #endif
 
                 m_raster_width = seq.param(2, 0, 0, k_max_width);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]