[vlc-commits] [Git][videolan/vlc][master] display: fix changing zoom

Jean-Baptiste Kempf (@jbk) gitlab at videolan.org
Tue May 31 16:25:13 UTC 2022



Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC


Commits:
5a48fa1d by Rémi Denis-Courmont at 2022-05-31T16:09:41+00:00
display: fix changing zoom

- - - - -


1 changed file:

- src/video_output/display.c


Changes:

=====================================
src/video_output/display.c
=====================================
@@ -561,13 +561,15 @@ void vout_SetDisplayFitting(vout_display_t *vd, enum vlc_video_fitting fit)
 void vout_SetDisplayZoom(vout_display_t *vd, unsigned num, unsigned den)
 {
     vout_display_priv_t *osys = container_of(vd, vout_display_priv_t, display);
+    unsigned onum = osys->cfg.display.zoom.num;
+    unsigned oden = osys->cfg.display.zoom.den;
 
     osys->cfg.display.zoom.num = num;
     osys->cfg.display.zoom.den = den;
 
     if (osys->cfg.display.fitting != VLC_VIDEO_FIT_NONE)
         return; /* zoom has no effects */
-    if (osys->cfg.display.zoom.num * den == num * osys->cfg.display.zoom.den)
+    if (onum * den == num * oden)
         return; /* zoom has not changed */
     if (vout_display_Control(vd, VOUT_DISPLAY_CHANGE_ZOOM))
         vout_display_Reset(vd);



View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/5a48fa1dbc9a662285c08ab04fb417cb6d3926c7

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/commit/5a48fa1dbc9a662285c08ab04fb417cb6d3926c7
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list