blob: 7efcc2f469f915bf371263acbc2f2d65353abbb1 [file] [log] [blame]
Sharad Sangled39232d2017-08-08 20:27:18 +05301#BOARD_USES_GENERIC_AUDIO := true
2#
3#AUDIO_FEATURE_FLAGS
4BOARD_USES_ALSA_AUDIO := true
5
6ifneq ($(TARGET_USES_AOSP_FOR_AUDIO), true)
7USE_CUSTOM_AUDIO_POLICY := 1
8AUDIO_FEATURE_ENABLED_COMPRESS_CAPTURE := false
9AUDIO_FEATURE_ENABLED_COMPRESS_VOIP := true
10AUDIO_FEATURE_ENABLED_EXTN_FORMATS := true
11AUDIO_FEATURE_ENABLED_EXTN_FLAC_DECODER := true
12AUDIO_FEATURE_ENABLED_EXTN_RESAMPLER := true
13AUDIO_FEATURE_ENABLED_FM_POWER_OPT := true
14AUDIO_FEATURE_ENABLED_HDMI_SPK := true
15AUDIO_FEATURE_ENABLED_PCM_OFFLOAD := true
16AUDIO_FEATURE_ENABLED_PCM_OFFLOAD_24 := true
17AUDIO_FEATURE_ENABLED_FLAC_OFFLOAD := true
18AUDIO_FEATURE_ENABLED_VORBIS_OFFLOAD := true
19AUDIO_FEATURE_ENABLED_WMA_OFFLOAD := true
20AUDIO_FEATURE_ENABLED_ALAC_OFFLOAD := true
21AUDIO_FEATURE_ENABLED_APE_OFFLOAD := true
22AUDIO_FEATURE_ENABLED_AAC_ADTS_OFFLOAD := true
23AUDIO_FEATURE_ENABLED_PROXY_DEVICE := true
24AUDIO_FEATURE_ENABLED_SSR := true
25AUDIO_FEATURE_ENABLED_DTS_EAGLE := false
26BOARD_USES_SRS_TRUEMEDIA := false
27DTS_CODEC_M_ := false
28MM_AUDIO_ENABLED_SAFX := true
29AUDIO_FEATURE_ENABLED_HW_ACCELERATED_EFFECTS := false
30AUDIO_FEATURE_ENABLED_AUDIOSPHERE := true
31AUDIO_FEATURE_ENABLED_USB_TUNNEL_AUDIO := true
32AUDIO_FEATURE_ENABLED_SPLIT_A2DP := true
33AUDIO_FEATURE_ENABLED_3D_AUDIO := false
34AUDIO_FEATURE_ENABLED_VOICE_PRINT := false
35USE_LEGACY_AUDIO_DAEMON := false
36USE_LEGACY_AUDIO_MEASUREMENT := false
37DOLBY_ENABLE := false
38endif
39
40USE_XML_AUDIO_POLICY_CONF := 1
41BOARD_SUPPORTS_SOUND_TRIGGER := true
42AUDIO_USE_LL_AS_PRIMARY_OUTPUT := true
43AUDIO_FEATURE_ENABLED_HIFI_AUDIO := true
44AUDIO_FEATURE_ENABLED_VBAT_MONITOR := true
45AUDIO_FEATURE_ENABLED_ANC_HEADSET := true
46AUDIO_FEATURE_ENABLED_CUSTOMSTEREO := true
47AUDIO_FEATURE_ENABLED_FLUENCE := true
48AUDIO_FEATURE_ENABLED_HDMI_EDID := true
49AUDIO_FEATURE_ENABLED_HDMI_PASSTHROUGH := true
50#AUDIO_FEATURE_ENABLED_KEEP_ALIVE := true
51AUDIO_FEATURE_ENABLED_DISPLAY_PORT := true
52AUDIO_FEATURE_ENABLED_DS2_DOLBY_DAP := false
53AUDIO_FEATURE_ENABLED_HFP := true
54AUDIO_FEATURE_ENABLED_INCALL_MUSIC := false
55AUDIO_FEATURE_ENABLED_MULTI_VOICE_SESSIONS := true
56AUDIO_FEATURE_ENABLED_KPI_OPTIMIZE := true
57AUDIO_FEATURE_ENABLED_SPKR_PROTECTION := true
58AUDIO_FEATURE_ENABLED_ACDB_LICENSE := true
59AUDIO_FEATURE_ENABLED_DEV_ARBI := false
60MM_AUDIO_ENABLED_FTM := true
61TARGET_USES_QCOM_MM_AUDIO := true
62AUDIO_FEATURE_ENABLED_SOURCE_TRACKING := true
63AUDIO_FEATURE_ENABLED_GEF_SUPPORT := true
64BOARD_SUPPORTS_QAHW := false
65AUDIO_FEATURE_ENABLED_RAS := true
66AUDIO_FEATURE_ENABLED_SND_MONITOR := true
67##AUDIO_FEATURE_FLAGS
68
69#Audio Specific device overlays
70DEVICE_PACKAGE_OVERLAYS += hardware/qcom/audio/configs/common/overlay
71
72# Audio configuration file
73ifeq ($(TARGET_USES_AOSP_FOR_AUDIO), true)
74PRODUCT_COPY_FILES += \
75 device/qcom/common/media/audio_policy.conf:system/etc/audio_policy.conf
76else
77PRODUCT_COPY_FILES += \
Sharad Sanglef1356842017-09-25 19:15:07 +053078 hardware/qcom/audio/configs/sdm670/audio_policy.conf:system/etc/audio_policy.conf
Sharad Sangled39232d2017-08-08 20:27:18 +053079endif
80
81PRODUCT_COPY_FILES += \
Sharad Sanglef1356842017-09-25 19:15:07 +053082 hardware/qcom/audio/configs/sdm670/audio_output_policy.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_output_policy.conf \
83 hardware/qcom/audio/configs/sdm670/audio_effects.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_effects.conf \
84 hardware/qcom/audio/configs/sdm670/mixer_paths_tavil.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_tavil.xml \
85 hardware/qcom/audio/configs/sdm670/mixer_paths.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths.xml \
86 hardware/qcom/audio/configs/sdm670/mixer_paths_mtp.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_mtp.xml \
87 hardware/qcom/audio/configs/sdm670/mixer_paths_tasha.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_tasha.xml \
88 hardware/qcom/audio/configs/sdm670/mixer_paths_tashalite.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_tashalite.xml \
89 hardware/qcom/audio/configs/sdm670/mixer_paths_i2s.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_i2s.xml \
90 hardware/qcom/audio/configs/sdm670/audio_tuning_mixer.txt:$(TARGET_COPY_OUT_VENDOR)/etc/audio_tuning_mixer.txt \
91 hardware/qcom/audio/configs/sdm670/audio_tuning_mixer_tavil.txt:$(TARGET_COPY_OUT_VENDOR)/etc/audio_tuning_mixer_tavil.txt \
92 hardware/qcom/audio/configs/sdm670/audio_tuning_mixer_tasha.txt:$(TARGET_COPY_OUT_VENDOR)/etc/audio_tuning_mixer_tasha.txt \
93 hardware/qcom/audio/configs/sdm670/audio_platform_info_intcodec.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info_intcodec.xml \
94 hardware/qcom/audio/configs/sdm670/audio_platform_info_i2s.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info_i2s.xml \
95 hardware/qcom/audio/configs/sdm670/audio_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info.xml \
96 hardware/qcom/audio/configs/sdm670/sound_trigger_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_platform_info.xml \
97 hardware/qcom/audio/configs/sdm670/sound_trigger_mixer_paths.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths.xml \
98 hardware/qcom/audio/configs/sdm670/sound_trigger_mixer_paths_wcd9335.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths_wcd9335.xml \
99 hardware/qcom/audio/configs/sdm670/sound_trigger_mixer_paths_wcd9340.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths_wcd9340.xml \
100 hardware/qcom/audio/configs/sdm670/sound_trigger_mixer_paths_wcd9340.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths_wcd9340.xml \
101 hardware/qcom/audio/configs/sdm670/graphite_ipc_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/graphite_ipc_platform_info.xml \
Sharad Sangled39232d2017-08-08 20:27:18 +0530102
103#XML Audio configuration files
104ifeq ($(USE_XML_AUDIO_POLICY_CONF), 1)
105ifneq ($(TARGET_USES_AOSP_FOR_AUDIO), true)
106PRODUCT_COPY_FILES += \
Sharad Sanglef1356842017-09-25 19:15:07 +0530107 $(TOPDIR)hardware/qcom/audio/configs/sdm670/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/audio_policy_configuration.xml
Sharad Sangled39232d2017-08-08 20:27:18 +0530108endif
109PRODUCT_COPY_FILES += \
110 $(TOPDIR)hardware/qcom/audio/configs/common/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_configuration.xml \
111 $(TOPDIR)frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_audio_policy_configuration.xml \
112 $(TOPDIR)frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_volumes.xml \
113 $(TOPDIR)frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \
114 $(TOPDIR)frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml \
115 $(TOPDIR)frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usb_audio_policy_configuration.xml
116endif
117
118# Listen configuration file
119PRODUCT_COPY_FILES += \
Sharad Sanglef1356842017-09-25 19:15:07 +0530120 hardware/qcom/audio/configs/sdm670/listen_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/listen_platform_info.xml
Sharad Sangled39232d2017-08-08 20:27:18 +0530121
122# Reduce client buffer size for fast audio output tracks
123PRODUCT_PROPERTY_OVERRIDES += \
124 af.fast_track_multiplier=1
125
126# Low latency audio buffer size in frames
127PRODUCT_PROPERTY_OVERRIDES += \
128 vendor.audio_hal.period_size=192
129
130##fluencetype can be "fluence" or "fluencepro" or "none"
131PRODUCT_PROPERTY_OVERRIDES += \
132ro.vendor.audio.sdk.fluencetype=none\
133persist.vendor.audio.fluence.voicecall=true\
134persist.vendor.audio.fluence.voicerec=false\
135persist.vendor.audio.fluence.speaker=true
136
137#disable tunnel encoding
138PRODUCT_PROPERTY_OVERRIDES += \
139vendor.audio.tunnel.encode=false
140
141#Disable RAS Feature by default
142PRODUCT_PROPERTY_OVERRIDES += \
143persist.vendor.audio.ras.enabled=false
144
145#Buffer size in kbytes for compress offload playback
146PRODUCT_PROPERTY_OVERRIDES += \
147vendor.audio.offload.buffer.size.kb=64
148
149#Minimum duration for offload playback in secs
150PRODUCT_PROPERTY_OVERRIDES += \
151audio.offload.min.duration.secs=30
152
153#Enable offload audio video playback by default
154PRODUCT_PROPERTY_OVERRIDES += \
155audio.offload.video=true
156
157#Enable audio track offload by default
158PRODUCT_PROPERTY_OVERRIDES += \
159vendor.audio.offload.track.enable=true
160
161#Enable music through deep buffer
162PRODUCT_PROPERTY_OVERRIDES += \
163audio.deep_buffer.media=true
164
165#enable voice path for PCM VoIP by default
166PRODUCT_PROPERTY_OVERRIDES += \
167vendor.voice.path.for.pcm.voip=true
168
169#Enable multi channel aac through offload
170PRODUCT_PROPERTY_OVERRIDES += \
171vendor.audio.offload.multiaac.enable=true
172
173#Enable DS2, Hardbypass feature for Dolby
174PRODUCT_PROPERTY_OVERRIDES += \
175vendor.audio.dolby.ds2.enabled=false\
176vendor.audio.dolby.ds2.hardbypass=false
177
178#Disable Multiple offload sesison
179PRODUCT_PROPERTY_OVERRIDES += \
180vendor.audio.offload.multiple.enabled=false
181
182#Disable Compress passthrough playback
183PRODUCT_PROPERTY_OVERRIDES += \
184vendor.audio.offload.passthrough=false
185
186#Disable surround sound recording
187PRODUCT_PROPERTY_OVERRIDES += \
188ro.vendor.audio.sdk.ssr=false
189
190#enable dsp gapless mode by default
191PRODUCT_PROPERTY_OVERRIDES += \
192vendor.audio.offload.gapless.enabled=true
193
194#enable pbe effects
195PRODUCT_PROPERTY_OVERRIDES += \
196vendor.audio.safx.pbe.enabled=true
197
198#parser input buffer size(256kb) in byte stream mode
199PRODUCT_PROPERTY_OVERRIDES += \
200vendor.audio.parser.ip.buffer.size=262144
201
202#flac sw decoder 24 bit decode capability
203PRODUCT_PROPERTY_OVERRIDES += \
204vendor.audio.flac.sw.decoder.24bit=true
205
206#split a2dp DSP supported encoder list
207PRODUCT_PROPERTY_OVERRIDES += \
208persist.vendor.bt.a2dp_offload_cap=sbc-aptx-aptxhd-aac
209
210#enable software decoders for ALAC and APE
211PRODUCT_PROPERTY_OVERRIDES += \
212vendor.audio.use.sw.alac.decoder=true
213PRODUCT_PROPERTY_OVERRIDES += \
214vendor.audio.use.sw.ape.decoder=true
215
216#enable hw aac encoder by default
217PRODUCT_PROPERTY_OVERRIDES += \
218vendor.audio.hw.aac.encoder=true
219
220#Disable FM a2dp concurrency
221PRODUCT_PROPERTY_OVERRIDES += \
222vendor.fm.a2dp.conc.disabled=true
223
224#audio becoming noisy intent broadcast delay
225PRODUCT_PROPERTY_OVERRIDES += \
226vendor.audio.noisy.broadcast.delay=600
227
228#Enable HIFI audio support for internal codec
229PRODUCT_PROPERTY_OVERRIDES += \
230persist.vendor.audio.hifi.int_codec=true
231
232#offload pausetime out duration to 3 secs to inline with other outputs
233PRODUCT_PROPERTY_OVERRIDES += \
234vendor.audio.offload.pstimeout.secs=3
235
236# for HIDL related packages
237PRODUCT_PACKAGES += \
238 android.hardware.audio@2.0-service \
239 android.hardware.audio@2.0-impl \
240 android.hardware.audio.effect@2.0-impl \
241 android.hardware.soundtrigger@2.0-impl