vlc | branch: master | Thomas Guillem <[email protected]> | Tue Jun 6 09:28:12 2017 +0200| [694399e23000232708b2d514a6a265cfc023ddde] | committer: Thomas Guillem
vt_utils: use proper structure type for picture context > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=694399e23000232708b2d514a6a265cfc023ddde --- modules/codec/vt_utils.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/modules/codec/vt_utils.c b/modules/codec/vt_utils.c index 2a84618a3c..3f2e79da93 100644 --- a/modules/codec/vt_utils.c +++ b/modules/codec/vt_utils.c @@ -42,14 +42,14 @@ cfdict_set_int32(CFMutableDictionaryRef dict, CFStringRef key, int value) struct cvpxpic_ctx { - void (*pf_destroy)(void *); /* must be first @ref picture_Release() */ + picture_context_t s; CVPixelBufferRef cvpx; }; static void -cvpxpic_destroy_cb(void *opaque) +cvpxpic_destroy_cb(picture_context_t *opaque) { - struct cvpxpic_ctx *ctx = opaque; + struct cvpxpic_ctx *ctx = (struct cvpxpic_ctx *)opaque; CFRelease(ctx->cvpx); free(opaque); @@ -65,9 +65,9 @@ cvpxpic_attach(picture_t *p_pic, CVPixelBufferRef cvpx) picture_Release(p_pic); return VLC_ENOMEM; } - ctx->pf_destroy = cvpxpic_destroy_cb; + ctx->s.destroy = cvpxpic_destroy_cb; ctx->cvpx = CVPixelBufferRetain(cvpx); - p_pic->context = ctx; + p_pic->context = &ctx->s; return VLC_SUCCESS; } _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
