From 4d33ccf89ae59103dda5d4c4a0c7f7b8618b8616 Mon Sep 17 00:00:00 2001 From: columbarius Date: Mon, 12 Aug 2024 16:33:43 +0200 Subject: [PATCH] videoconvert: Start dummy plugin in passthrough mode Since the dummy plugin can't process buffers, we should configure the adapter to use passthrough mode for now, instead of requiering the user to do it manually. --- spa/plugins/videoconvert/videoadapter.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/spa/plugins/videoconvert/videoadapter.c b/spa/plugins/videoconvert/videoadapter.c index 57bd8391f..a364a9d36 100644 --- a/spa/plugins/videoconvert/videoadapter.c +++ b/spa/plugins/videoconvert/videoadapter.c @@ -2,7 +2,7 @@ /* SPDX-FileCopyrightText: Copyright © 2019 Wim Taymans */ /* SPDX-License-Identifier: MIT */ -#include "spa/utils/dict.h" +#include #include #include #include @@ -1879,7 +1879,12 @@ impl_init(const struct spa_handle_factory *factory, spa_node_add_listener(this->convert, &this->convert_listener, &convert_node_events, this); - configure_convert(this, SPA_PARAM_PORT_CONFIG_MODE_convert); + if (strcmp(this->convertname, "video.convert.dummy") == 0) { + configure_convert(this, SPA_PARAM_PORT_CONFIG_MODE_none); + reconfigure_mode(this, true, this->direction, NULL); + } else { + configure_convert(this, SPA_PARAM_PORT_CONFIG_MODE_convert); + } } else { reconfigure_mode(this, true, this->direction, NULL); }