add DPE and GAPLESS_OFFLOAD and fix mmap-playback

Bug: 259008615
Test: boot up to home and test offload playback
Test: oboe output
Change-Id: Ia8a47510c54bc812a3fcc25e3c94f3fce01c3199
This commit is contained in:
David Li 2022-11-23 11:52:34 +08:00
parent d520623aed
commit cfdd661f85
6 changed files with 12 additions and 6 deletions

View file

@ -5,7 +5,7 @@
<library name="reverb" path="libreverbwrapper.so"/>
<library name="visualizer_sw" path="libvisualizer.so"/>
<library name="downmix" path="libdownmix.so"/>
<library name="dynamics_processing" path="libdynproc.so"/>
<library name="dynamics_processing_sw" path="libdynproc.so"/>
<library name="loudness_enhancer" path="libldnhncr.so"/>
<library name="proxy" path="libeffectproxy.so"/>
<library name="offload_effect" path="liboffloadeffect.so"/>
@ -46,12 +46,15 @@
<libsw library="visualizer_sw" uuid="d069d9e0-8329-11df-9168-0002a5d5c51b"/>
<libhw library="offload_effect" uuid="99fb2ecb-3426-4a0e-8082-1a1da5604b7d"/>
</effectProxy>
<effectProxy name="dynamics_processing" library="proxy" uuid="dcf01474-8982-11ec-a8a3-0242ac120002">
<libsw library="dynamics_processing_sw" uuid="e0e6539b-1781-7261-676f-6d7573696340"/>
<libhw library="offload_effect" uuid="1bf15eb7-8f49-4fd8-8380-0767fd5680f3"/>
</effectProxy>
<effect name="downmix" library="downmix" uuid="93f04452-e4fe-41cc-91f9-e475b6d1d69f"/>
<effect name="loudness_enhancer" library="loudness_enhancer" uuid="fa415329-2034-4bea-b5dc-5b381c8d1e2c"/>
<effect name="aec" library="offload_effect" uuid="28c28780-ec8b-48b6-8590-8c84557d797d"/>
<effect name="ns" library="offload_effect" uuid="62ff2836-d050-43c3-9c2d-94a73dad2c64"/>
<effect name="haptic_generator" library="haptic_generator" uuid="97c4acd1-8b82-4f2f-832e-c2fe5d7a9931"/>
<effect name="dynamics_processing" library="dynamics_processing" uuid="e0e6539b-1781-7261-676f-6d7573696340"/>
<effect name="spatializer" library="spatializer" uuid="cc4677de-ff72-11eb-9a03-0242ac130003"/>
</effects>
<postprocess>

View file

@ -178,7 +178,7 @@
<!-- for output with AUDIO_OUTPUT_FLAG_PRIMARY|AUDIO_OUTPUT_FLAG_FAST, 4 * 10ms buffer -->
<usecase id="UC_LOW_LATENCY_PLAYBACK" dev1="1" dyn_path="true" dsp_vol="false" mmap="false" period="10" period_num="4"/>
<!-- for output with AUDIO_OUTPUT_FLAG_MMAP_NOIRQ, 80 periods * 48 frames/period(=1ms w/ 48k sample rate) * 4 bytes/frame = 15360 bytes -->
<usecase id="UC_MMAP_PLAYBACK" dev1="0" dyn_path="true" dsp_vol="false" mmap="true" period="1" period_num="80"/>
<usecase id="UC_MMAP_PLAYBACK" dev1="0" dyn_path="true" dsp_vol="false" mmap="true" period="1" period_num="40"/>
<!-- for output with AUDIO_OUTPUT_FLAG_DEEP_BUFFER, 4 * 20ms buffer -->
<usecase id="UC_DEEP_BUFFER_PLAYBACK" dev1="5" dyn_path="true" dsp_vol="false" mmap="false" period="20" period_num="4"/>
<!-- dev1: voice-call downlink dev2: voice-clal uplink -->

View file

@ -37,7 +37,7 @@
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="compressed_offload" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD AUDIO_OUTPUT_FLAG_NON_BLOCKING">
flags="AUDIO_OUTPUT_FLAG_DIRECT AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD AUDIO_OUTPUT_FLAG_NON_BLOCKING AUDIO_OUTPUT_FLAG_GAPLESS_OFFLOAD">
<profile name="" format="AUDIO_FORMAT_MP3"
samplingRates="8000 16000 24000 32000 44100 48000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/>

View file

@ -36,7 +36,7 @@
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="compressed_offload" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD AUDIO_OUTPUT_FLAG_NON_BLOCKING">
flags="AUDIO_OUTPUT_FLAG_DIRECT AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD AUDIO_OUTPUT_FLAG_NON_BLOCKING AUDIO_OUTPUT_FLAG_GAPLESS_OFFLOAD">
<profile name="" format="AUDIO_FORMAT_MP3"
samplingRates="8000 16000 24000 32000 44100 48000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/>

View file

@ -36,7 +36,7 @@
samplingRates="48000" channelMasks="AUDIO_CHANNEL_OUT_STEREO"/>
</mixPort>
<mixPort name="compressed_offload" role="source"
flags="AUDIO_OUTPUT_FLAG_DIRECT AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD AUDIO_OUTPUT_FLAG_NON_BLOCKING">
flags="AUDIO_OUTPUT_FLAG_DIRECT AUDIO_OUTPUT_FLAG_COMPRESS_OFFLOAD AUDIO_OUTPUT_FLAG_NON_BLOCKING AUDIO_OUTPUT_FLAG_GAPLESS_OFFLOAD">
<profile name="" format="AUDIO_FORMAT_MP3"
samplingRates="8000 16000 24000 32000 44100 48000"
channelMasks="AUDIO_CHANNEL_OUT_STEREO AUDIO_CHANNEL_OUT_MONO"/>

View file

@ -30,6 +30,9 @@
<ctl name="PCM Stream Wait Time in MSec" value="100"/>
<ctl name="Voice PCM Stream Wait Time in MSec" value="500"/>
<!-- Enable it when AOC is ready to trim delay and padding -->
<ctl name="Gapless Offload Enable" value="1"/>
<!-- TDM 0 setting -->
<ctl name="TDM_0_RX Chan" value="Four"/>
<ctl name="TDM_0_RX Format" value="S32_LE"/>