[vlc-commits] interop_cvpx: assert that chroma matches input format
Alexandre Janniaux
git at videolan.org
Mon Feb 15 15:06:11 UTC 2021
vlc | branch: master | Alexandre Janniaux <ajanni at videolabs.io> | Fri Jan 29 10:31:04 2021 +0100| [21eeb380e0cfaa3747de26ee6b81170021aa5ac8] | committer: Alexandre Janniaux
interop_cvpx: assert that chroma matches input format
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=21eeb380e0cfaa3747de26ee6b81170021aa5ac8
---
modules/video_output/opengl/interop_cvpx.m | 3 +++
1 file changed, 3 insertions(+)
diff --git a/modules/video_output/opengl/interop_cvpx.m b/modules/video_output/opengl/interop_cvpx.m
index abe95721d0..8131314863 100644
--- a/modules/video_output/opengl/interop_cvpx.m
+++ b/modules/video_output/opengl/interop_cvpx.m
@@ -57,6 +57,9 @@ tc_cvpx_update(const struct vlc_gl_interop *interop, GLuint *textures,
(void) plane_offset;
struct priv *priv = interop->priv;
+ /* Sanity check, don't change format behind interop's back. */
+ assert(pic->format.i_chroma == interop->fmt_in.i_chroma);
+
CVPixelBufferRef pixelBuffer = cvpxpic_get_ref(pic);
for (unsigned i = 0; i < interop->tex_count; ++i)
More information about the vlc-commits
mailing list