[vlc-commits] ci_filters: output BGRA instead of NV12 as intermediate

Thomas Guillem git at videolan.org
Thu Sep 28 13:51:50 CEST 2017


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Thu Sep 28 13:50:36 2017 +0200| [dad30bc37e135e6be2a0d499d668738b6648e615] | committer: Thomas Guillem

ci_filters: output BGRA instead of NV12 as intermediate

When filtering a 1080p YUV2 video, CPU goes from 60% to 40%. Ideally, the vout
should be reconfigured to switch from YUV2 to BGRA to get the best performances
possible.

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

 modules/video_filter/ci_filters.m | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/modules/video_filter/ci_filters.m b/modules/video_filter/ci_filters.m
index 7855d9ca45..e3f81e53a9 100644
--- a/modules/video_filter/ci_filters.m
+++ b/modules/video_filter/ci_filters.m
@@ -446,7 +446,7 @@ static int
 Open_AddConverter(filter_t *filter, struct ci_filters_ctx *ctx)
 {
     ctx->cvpx_pool_fmt = filter->fmt_in.video;
-    ctx->cvpx_pool_fmt.i_chroma = VLC_CODEC_CVPX_NV12;
+    ctx->cvpx_pool_fmt.i_chroma = VLC_CODEC_CVPX_BGRA;
     ctx->cvpx_pool = cvpxpool_create(&ctx->cvpx_pool_fmt, 3);
     if (!ctx->cvpx_pool)
         goto error;
@@ -457,8 +457,8 @@ Open_AddConverter(filter_t *filter, struct ci_filters_ctx *ctx)
 
     ctx->dst_converter->fmt_in = filter->fmt_out;
     ctx->dst_converter->fmt_out = filter->fmt_out;
-    ctx->dst_converter->fmt_in.i_codec = VLC_CODEC_CVPX_NV12;
-    ctx->dst_converter->fmt_in.video.i_chroma = VLC_CODEC_CVPX_NV12;
+    ctx->dst_converter->fmt_in.video.i_chroma =
+    ctx->dst_converter->fmt_in.i_codec = VLC_CODEC_CVPX_BGRA;
 
     ctx->outconv_cvpx_pool =
         cvpxpool_create(&filter->fmt_out.video, 2);



More information about the vlc-commits mailing list