[vlc-commits] videotoolbox: use new cvpx video context helpers

Thomas Guillem git at videolan.org
Fri Jan 10 13:02:07 CET 2020


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Thu Jan  9 17:23:08 2020 +0100| [e0a0f2a17e38662db1e363f7fc088f82a0003204] | committer: Thomas Guillem

videotoolbox: use new cvpx video context helpers

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

 modules/codec/videotoolbox.m | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/modules/codec/videotoolbox.m b/modules/codec/videotoolbox.m
index 4c95b5d96e..1028ed7c71 100644
--- a/modules/codec/videotoolbox.m
+++ b/modules/codec/videotoolbox.m
@@ -1366,8 +1366,9 @@ CreateVideoContext(decoder_t *p_dec)
         pic_pacer_Destroy,
     };
     p_sys->vctx =
-        vlc_video_context_Create(dec_dev, VLC_VIDEO_CONTEXT_CVPX,
-                                 sizeof(struct pic_pacer), &ops);
+        vlc_video_context_CreateCVPX(dec_dev,
+                                     CVPX_VIDEO_CONTEXT_VIDEOTOOLBOX,
+                                     sizeof(struct pic_pacer), &ops);
     vlc_decoder_device_Release(dec_dev);
 
     if (!p_sys->vctx)
@@ -1377,8 +1378,8 @@ CreateVideoContext(decoder_t *p_dec)
      * good place to place the pic_pacer that need to be valid during the
      * lifetime of all pictures */
     p_sys->pic_pacer =
-        vlc_video_context_GetPrivate(p_sys->vctx,
-                                     VLC_VIDEO_CONTEXT_CVPX);
+        vlc_video_context_GetCVPXPrivate(p_sys->vctx,
+                                         CVPX_VIDEO_CONTEXT_VIDEOTOOLBOX);
     assert(p_sys->pic_pacer);
 
     pic_pacer_Init(p_sys->pic_pacer, p_sys->i_pic_reorder_max);
@@ -2113,7 +2114,7 @@ static void
 video_context_OnPicReleased(vlc_video_context *vctx, unsigned nb_fields)
 {
     struct pic_pacer *pic_pacer =
-        vlc_video_context_GetPrivate(vctx, VLC_VIDEO_CONTEXT_CVPX);
+        vlc_video_context_GetCVPXPrivate(vctx, CVPX_VIDEO_CONTEXT_VIDEOTOOLBOX);
 
     vlc_mutex_lock(&pic_pacer->lock);
     assert((int) pic_pacer->nb_field_out - nb_fields >= 0);



More information about the vlc-commits mailing list