From b32de25fc1e2c1e98c86cb53a3f83793c2d86e1d Mon Sep 17 00:00:00 2001 From: Ranjani Sridharan Date: Wed, 7 Aug 2024 11:43:50 -0700 Subject: [PATCH] topology2: pipelines: Add a new pipeline Add a new pipeline, mixout-gain-eqiir-eqfir, that uses the new alsa-utils topology feature to allow extending existing pipeline definitions. This new class extends the base class mixout-gain-dai-copier-playback class by adding the eqiir & eqfir widgets along with the new routes. Signed-off-by: Ranjani Sridharan --- .../mixout-gain-eqiir-eqfir-playback.conf | 102 ++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 tools/topology/topology2/include/pipelines/cavs/mixout-gain-eqiir-eqfir-playback.conf diff --git a/tools/topology/topology2/include/pipelines/cavs/mixout-gain-eqiir-eqfir-playback.conf b/tools/topology/topology2/include/pipelines/cavs/mixout-gain-eqiir-eqfir-playback.conf new file mode 100644 index 000000000..22562b87b --- /dev/null +++ b/tools/topology/topology2/include/pipelines/cavs/mixout-gain-eqiir-eqfir-playback.conf @@ -0,0 +1,102 @@ +# +# BE playback pipeline: mixout-gain-eqiir-eqfir. +# This pipeline is an extension of the mixout-gain-dai-copier-playback pipeline class +# +# All attributes defined herein are namespaced +# by alsatplg to "Object.Pipeline.mixout-gain-eqiir-eqfir.N.attribute_name" +# +# Usage: mixout-gain-efx-dai-copier-playback pipeline object can be instantiated as: +# +# Object.Pipeline.mixout-gain-eqiir-eqfir."N" { +# period 1000 +# time_domain "timer" +# } +# +# Where N is the unique pipeline ID within the same alsaconf node. +# + + + + + + +Class.Pipeline."mixout-gain-eqiir-eqfir" { + SubTreeCopy.baseclass { + + # this class extends the mixout-gain-dai-copier-playback class definition + source "Class.Pipeline.mixout-gain-dai-copier-playback" + + # target node is not defined which means that the new subtree will be copied to + # the parent node containing the SubTreeCopy node i.e in this case the + # Class.Pipeline.mixout-gain-eqiir-eqfir {} node. + + # default copy type is to extend the base class ie the widgets and routes + # will be added to the existing list of widgets/routes in the base class + + tree { + Object.Widget { + eqiir."1" { + num_input_audio_formats 1 + num_output_audio_formats 1 + + # 32-bit 48KHz 2ch + Object.Base.input_audio_format [ + { + in_bit_depth 32 + in_valid_bit_depth 32 + } + ] + Object.Base.output_audio_format [ + { + out_bit_depth 32 + out_valid_bit_depth 32 + } + ] + + Object.Control.bytes."1" { + IncludeByKey.EFX_IIR_PARAMS { + "passthrough" "include/components/eqiir/passthrough.conf" + } + } + } + eqfir."1" { + num_input_audio_formats 1 + num_output_audio_formats 1 + + # 32-bit 48KHz 2ch + Object.Base.input_audio_format [ + { + in_bit_depth 32 + in_valid_bit_depth 32 + } + ] + Object.Base.output_audio_format [ + { + out_bit_depth 32 + out_valid_bit_depth 32 + } + ] + + Object.Control.bytes."1" { + IncludeByKey.EFX_FIR_PARAMS { + "passthrough" "include/components/eqfir/passthrough.conf" + } + } + } + } + + Object.Base { + !route [ + { + source gain.$index.1 + sink eqiir.$index.1 + } + { + source eqiir.$index.1 + sink eqfir.$index.1 + } + ] + } + } + } +}