[vlc-commits] MSW/GDI: simplify pool creation

Rémi Denis-Courmont git at videolan.org
Thu Oct 30 15:04:25 CET 2014


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Oct 30 16:03:59 2014 +0200| [396436191c55a7e9ce6e88f9e6e70fe4a4fbaa40] | committer: Rémi Denis-Courmont

MSW/GDI: simplify pool creation

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=396436191c55a7e9ce6e88f9e6e70fe4a4fbaa40
---

 modules/video_output/msw/wingdi.c |   10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/modules/video_output/msw/wingdi.c b/modules/video_output/msw/wingdi.c
index 761af9a..1886f85 100644
--- a/modules/video_output/msw/wingdi.c
+++ b/modules/video_output/msw/wingdi.c
@@ -290,13 +290,9 @@ static int Init(vout_display_t *vd,
     rsc.p[0].i_pitch  = i_pic_pitch;;
 
     picture_t *picture = picture_NewFromResource(fmt, &rsc);
-    if (picture) {
-        picture_pool_configuration_t cfg;
-        memset(&cfg, 0, sizeof(cfg));
-        cfg.picture_count = 1;
-        cfg.picture = &picture;
-        sys->pool = picture_pool_NewExtended(&cfg);
-    } else
+    if (picture != NULL)
+        sys->pool = picture_pool_New(1, &picture);
+    else
         sys->pool = NULL;
 
     UpdateRects(vd, NULL, NULL, true);



More information about the vlc-commits mailing list