-
Notifications
You must be signed in to change notification settings - Fork 350
topology2: add support form compressed playback #10547
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
26aa40e
2070134
1258333
55c5408
92a8bf5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,63 @@ | ||
| # | ||
| # Decoder widget component definition | ||
| # | ||
| # A generic decoder widget. All attributes defined herein are namespaced | ||
| # by alsatplg to "Object.Widget.decoder.N.attribute_name" | ||
| # | ||
| # Usage: this component can be used by declaring in a parent object. i.e. | ||
| # | ||
| # Object.Widget.decoder."N" { | ||
| # index 1 | ||
| # no_pm "true" | ||
| # } | ||
| # | ||
| # Where N is the unique instance number for decoder widget in the same alsaconf node. | ||
|
|
||
| Class.Widget."decoder" { | ||
| # | ||
| # Pipeline ID for the decoder widget object | ||
| # | ||
| DefineAttribute."index" {} | ||
|
|
||
| # | ||
| # decoder object instance | ||
| # | ||
| DefineAttribute."instance" {} | ||
|
|
||
| #include common component definition | ||
| <include/components/widget-common.conf> | ||
|
|
||
| # Attribute categories | ||
| attributes { | ||
| # | ||
| # The decoder widget name would be constructed using the index and instance attributes. | ||
| # For ex: "decoder.1.1" or "decoder.10.2" etc. | ||
| # | ||
| !constructor [ | ||
| "index" | ||
| "instance" | ||
| ] | ||
|
|
||
| # | ||
| # immutable attributes cannot be modified in the object instance | ||
| # | ||
| !immutable [ | ||
| "type" | ||
| ] | ||
|
|
||
| # | ||
| # decoder widget objects instantiated within the same alsaconf node must have unique | ||
| # instance attribute | ||
| # | ||
| unique "instance" | ||
| } | ||
|
|
||
| # Default attribute values for decoder widget | ||
| type "decoder" | ||
|
|
||
| # cadence codec UUID | ||
| uuid "43:84:21:d8:f3:5f:4c:4a:b3:88:6c:fe:07:b9:56:aa" | ||
| no_pm "true" | ||
| num_output_pins 1 | ||
| num_input_pins 1 | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,63 @@ | ||
| # | ||
| # Encoder widget component definition | ||
| # | ||
| # A generic encoder widget. All attributes defined herein are namespaced | ||
| # by alsatplg to "Object.Widget.encoder.N.attribute_name" | ||
| # | ||
| # Usage: this component can be used by declaring in a parent object. i.e. | ||
| # | ||
| # Object.Widget.encoder."N" { | ||
| # index 1 | ||
| # no_pm "true" | ||
| # } | ||
| # | ||
| # Where N is the unique instance number for encoder widget in the same alsaconf node. | ||
|
|
||
| Class.Widget."encoder" { | ||
| # | ||
| # Pipeline ID for the encoder widget object | ||
| # | ||
| DefineAttribute."index" {} | ||
|
|
||
| # | ||
| # encoder object instance | ||
| # | ||
| DefineAttribute."instance" {} | ||
|
|
||
| #include common component definition | ||
| <include/components/widget-common.conf> | ||
|
|
||
| # Attribute categories | ||
| attributes { | ||
| # | ||
| # The encoder widget name would be constructed using the index and instance attributes. | ||
| # For ex: "encoder.1.1" or "encoder.10.2" etc. | ||
| # | ||
| !constructor [ | ||
| "index" | ||
| "instance" | ||
| ] | ||
|
|
||
| # | ||
| # immutable attributes cannot be modified in the object instance | ||
| # | ||
| !immutable [ | ||
| "type" | ||
| ] | ||
|
|
||
| # | ||
| # encoder widget objects instantiated within the same alsaconf node must have unique | ||
| # instance attribute | ||
| # | ||
| unique "instance" | ||
| } | ||
|
|
||
| # Default attribute values for encoder widget | ||
| type "encoder" | ||
|
|
||
| # cadence codec UUID | ||
| uuid "43:84:21:d8:f3:5f:4c:4a:b3:88:6c:fe:07:b9:56:aa" | ||
| no_pm "true" | ||
| num_output_pins 1 | ||
| num_input_pins 1 | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,94 @@ | ||
| # | ||
| # FE playback pipeline: compr-playback | ||
| # | ||
| # All attributes defined herein are namespaced | ||
| # by alsatplg to "Object.Pipeline.compr-playback.N.attribute_name" | ||
| # | ||
| # Usage: compr-playback pipeline object can be instantiated as: | ||
| # | ||
| # Object.Pipeline.compr-playback."N" { | ||
| # period 1000 | ||
| # time_domain "timer" | ||
| # } | ||
| # | ||
| # Where N is the unique pipeline ID within the same alsaconf node. | ||
| # | ||
|
|
||
| <include/common/input_audio_format.conf> | ||
| <include/common/output_audio_format.conf> | ||
| <include/components/host-copier.conf> | ||
| <include/components/module-copier.conf> | ||
| <include/components/mixin.conf> | ||
| <include/components/pipeline.conf> | ||
| <include/components/gain.conf> | ||
| <include/components/decoder.conf> | ||
|
|
||
| Class.Pipeline."compr-playback" { | ||
|
|
||
| <include/pipelines/pipeline-common.conf> | ||
|
|
||
| attributes { | ||
| !constructor [ | ||
| "index" | ||
| ] | ||
|
|
||
| !immutable [ | ||
| "direction" | ||
| ] | ||
|
|
||
| # | ||
| # compr-playback objects instantiated within the same alsaconf node must have | ||
| # unique pipeline_id attribute | ||
| # | ||
| unique "instance" | ||
| } | ||
|
|
||
| Object.Widget { | ||
| host-copier."1" { | ||
| type "aif_in" | ||
| node_type $HDA_HOST_OUTPUT_CLASS | ||
| num_output_pins 1 | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. With thesofproject/linux#5673 we can add Or use a new define for compress deep buffer. cplay -c0 -d52 -f4 -b 65536 -I MP3 /home/sof/work/samples/Echoplex-10s.mp3 cplay -c0 -d52 -f4 -b 131072 -I MP3 /home/sof/work/samples/Echoplex-10s.mp3 cplay -c0 -d52 -f4 -b 524288 -I MP3 /home/sof/work/samples/Echoplex-10s.mp3
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @ujfalusi I assume this needs to merge first before kernel ? Although, I dont think anything would break today if other way around. |
||
| } | ||
|
|
||
| decoder."1" { | ||
| scheduler_domain "DP" | ||
| } | ||
|
|
||
| module-copier."2" {} | ||
|
|
||
| src."1" {} | ||
|
|
||
| gain."1" {} | ||
|
|
||
| mixin."1" {} | ||
|
|
||
| pipeline."1" { | ||
| priority 0 | ||
| # enable lp mode | ||
| lp_mode 1 | ||
| } | ||
| } | ||
|
|
||
| Object.Base.route [ | ||
| { | ||
| source decoder.$index.1 | ||
| sink module-copier.$index.2 | ||
| } | ||
| { | ||
| source module-copier.$index.2 | ||
| sink src.$index.1 | ||
| } | ||
| { | ||
| source src.$index.1 | ||
| sink gain.$index.1 | ||
| } | ||
| { | ||
| source gain.$index.1 | ||
| sink mixin.$index.1 | ||
| } | ||
| ] | ||
|
|
||
| direction "playback" | ||
| dynamic_pipeline 1 | ||
| time_domain "timer" | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,9 @@ | ||
| # default settings for Compressed Audio Playback | ||
| Define { | ||
| COMPRESSED false | ||
| COMPRESSED_1 true | ||
| COMPRESSED_2 false | ||
|
|
||
| COMPR_PCM_NAME 'Compress Playback' | ||
| COMPR_2_PCM_NAME 'Compress Playback 2' | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a bit unchartered PCM numbering territory. Let me add a link to the old PCM numbers doc #3806 (comment)
But not a blocker, PCM50 is good as anyone.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can move it to 100 base, the probes are in sof-client as separate card.