blob: c9a9746e77c59d2ce20035277bcb871cb3a8aea8 [file] [log] [blame]
Ashish Jain1221b522016-03-30 15:09:20 +05301##AUDIO_FEATURE_FLAGS
2#BOARD_USES_GENERIC_AUDIO := true
3BOARD_USES_ALSA_AUDIO := true
Sharad Sangle8ecefdc2016-09-26 13:50:41 +05304
vivek mehta02a52022017-01-27 15:36:19 -08005ifneq ($(TARGET_USES_AOSP_FOR_AUDIO), true)
Ashish Jain1221b522016-03-30 15:09:20 +05306USE_CUSTOM_AUDIO_POLICY := 1
Vara Prasad A V S Gbbef79e2016-04-26 21:12:43 +05307#AUDIO_FEATURE_ENABLED_VOICE_CONCURRENCY := true
Ashish Jain1221b522016-03-30 15:09:20 +05308AUDIO_FEATURE_ENABLED_AAC_ADTS_OFFLOAD := true
Ashish Jain1221b522016-03-30 15:09:20 +05309AUDIO_FEATURE_ENABLED_COMPRESS_CAPTURE := false
10AUDIO_FEATURE_ENABLED_COMPRESS_VOIP := true
Ashish Jain1221b522016-03-30 15:09:20 +053011AUDIO_FEATURE_ENABLED_EXTN_FORMATS := true
12AUDIO_FEATURE_ENABLED_EXTN_FLAC_DECODER := true
Mohd Mujahid Pasha4981bea2018-04-11 13:06:18 +053013AUDIO_FEATURE_ENABLED_EXTN_RESAMPLER := false
Ashish Jain1221b522016-03-30 15:09:20 +053014AUDIO_FEATURE_ENABLED_FM_POWER_OPT := true
Ashish Jain1221b522016-03-30 15:09:20 +053015AUDIO_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
Ashish Jainad78edc2016-04-11 12:22:28 +053022AUDIO_FEATURE_ENABLED_PROXY_DEVICE := true
Ashish Jain1221b522016-03-30 15:09:20 +053023AUDIO_FEATURE_ENABLED_SSR := true
Ashish Jain1221b522016-03-30 15:09:20 +053024AUDIO_FEATURE_ENABLED_DTS_EAGLE := false
Divya Narayanan Poojary87cfbd72017-02-15 12:16:58 +053025BOARD_USES_SRS_TRUEMEDIA := false
Ashish Jain1221b522016-03-30 15:09:20 +053026DTS_CODEC_M_ := true
27#AUDIO_FEATURE_ENABLED_MULTIPLE_TUNNEL := true
Ashish Jain1221b522016-03-30 15:09:20 +053028MM_AUDIO_ENABLED_SAFX := true
Ashish Jain1221b522016-03-30 15:09:20 +053029AUDIO_FEATURE_ENABLED_HW_ACCELERATED_EFFECTS := false
Satya Krishna Pindiproli4a72ae62017-07-02 16:08:11 +053030AUDIO_FEATURE_ENABLED_DS2_DOLBY_DAP := false
Ashish Jain1221b522016-03-30 15:09:20 +053031AUDIO_FEATURE_ENABLED_AUDIOSPHERE := true
Dhananjay Kumar29b894e2017-04-05 02:41:14 +053032DOLBY_ENABLE := false
Sharad Sangle8ecefdc2016-09-26 13:50:41 +053033endif
Ashish Jain1221b522016-03-30 15:09:20 +053034
Sharad Sangle8ecefdc2016-09-26 13:50:41 +053035USE_XML_AUDIO_POLICY_CONF := 1
36BOARD_SUPPORTS_SOUND_TRIGGER := true
Dhanalakshmi Siddani57b014e2018-04-23 12:52:02 +053037BOARD_SUPPORTS_SOUND_TRIGGER_ARM := true
38AUDIO_FEATURE_ENABLED_FFV := true
39AUDIO_FEATURE_ENABLED_KEEP_ALIVE_ARM_FFV := true
40AUDIO_FEATURE_ENABLED_KEEP_ALIVE := true
Sharad Sangle8ecefdc2016-09-26 13:50:41 +053041AUDIO_USE_LL_AS_PRIMARY_OUTPUT := true
42AUDIO_FEATURE_ENABLED_HIFI_AUDIO := true
43AUDIO_FEATURE_ENABLED_VBAT_MONITOR := true
44AUDIO_FEATURE_ENABLED_NT_PAUSE_TIMEOUT := true
45AUDIO_FEATURE_ENABLED_ANC_HEADSET := true
46AUDIO_FEATURE_ENABLED_CUSTOMSTEREO := true
47AUDIO_FEATURE_ENABLED_FLUENCE := true
48AUDIO_FEATURE_ENABLED_HDMI_SPK := true
49AUDIO_FEATURE_ENABLED_HDMI_EDID := true
50AUDIO_FEATURE_ENABLED_EXT_HDMI := true
51AUDIO_FEATURE_ENABLED_HFP := true
52AUDIO_FEATURE_ENABLED_INCALL_MUSIC := false
53AUDIO_FEATURE_ENABLED_MULTI_VOICE_SESSIONS := true
54AUDIO_FEATURE_ENABLED_KPI_OPTIMIZE := true
55AUDIO_FEATURE_ENABLED_SPKR_PROTECTION := true
56AUDIO_FEATURE_ENABLED_ACDB_LICENSE := true
57AUDIO_FEATURE_ENABLED_DEV_ARBI := false
58MM_AUDIO_ENABLED_FTM := true
59TARGET_USES_QCOM_MM_AUDIO := true
60AUDIO_FEATURE_ENABLED_SOURCE_TRACKING := true
Dhananjay Kumar23a3bec2017-01-11 18:38:09 +053061BOARD_SUPPORTS_QAHW := true
Revathi Uddaraju1eac8b02017-05-18 17:13:33 +053062AUDIO_FEATURE_ENABLED_DYNAMIC_LOG := true
Dhananjay Kumare6293dd2017-05-25 17:25:30 +053063AUDIO_FEATURE_ENABLED_SND_MONITOR := true
Himanshu Agrawal69e7fe12018-04-17 20:46:37 +053064ifeq ($(TARGET_KERNEL_VERSION), 3.18)
65 AUDIO_FEATURE_ENABLED_DLKM := false
66else
67 AUDIO_FEATURE_ENABLED_DLKM := true
68endif
Ashish Jain1221b522016-03-30 15:09:20 +053069##AUDIO_FEATURE_FLAGS
70
Ashish Jain440a4d92016-04-06 23:03:56 +053071#Audio Specific device overlays
72DEVICE_PACKAGE_OVERLAYS += hardware/qcom/audio/configs/common/overlay
73
Sharad Sangle8ecefdc2016-09-26 13:50:41 +053074# Audio configuration file
vivek mehta02a52022017-01-27 15:36:19 -080075ifeq ($(TARGET_USES_AOSP_FOR_AUDIO), true)
Sharad Sangle8ecefdc2016-09-26 13:50:41 +053076PRODUCT_COPY_FILES += \
Divya Narayanan Poojary2c5f13a2017-07-05 16:54:41 +053077 device/qcom/common/media/audio_policy.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy.conf
Sharad Sangle8ecefdc2016-09-26 13:50:41 +053078else
79PRODUCT_COPY_FILES += \
Divya Narayanan Poojary2c5f13a2017-07-05 16:54:41 +053080 hardware/qcom/audio/configs/msm8953/audio_policy.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy.conf
Sharad Sangle8ecefdc2016-09-26 13:50:41 +053081endif
Ashish Jain1221b522016-03-30 15:09:20 +053082
83PRODUCT_COPY_FILES += \
David Ng06ccd872017-03-15 11:39:33 -070084hardware/qcom/audio/configs/msm8953/audio_output_policy.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_output_policy.conf \
85hardware/qcom/audio/configs/msm8953/audio_effects.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_effects.conf \
Divya Narayanan Poojary2c5f13a2017-07-05 16:54:41 +053086hardware/qcom/audio/configs/msm8953/mixer_paths_mtp.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_mtp.xml \
87hardware/qcom/audio/configs/msm8953/mixer_paths_qrd_skuh.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_qrd_skuh.xml \
88hardware/qcom/audio/configs/msm8953/mixer_paths_qrd_skui.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_qrd_skui.xml \
89hardware/qcom/audio/configs/msm8953/mixer_paths_qrd_skuhf.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_qrd_skuhf.xml \
90hardware/qcom/audio/configs/msm8953/mixer_paths_qrd_skum.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_qrd_skum.xml \
91hardware/qcom/audio/configs/msm8953/mixer_paths_qrd_sku3.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_qrd_sku3.xml \
92hardware/qcom/audio/configs/msm8953/mixer_paths_wcd9330.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_wcd9330.xml \
93hardware/qcom/audio/configs/msm8953/mixer_paths_wcd9306.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_wcd9306.xml \
94hardware/qcom/audio/configs/msm8953/mixer_paths_wcd9335.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_wcd9335.xml \
95hardware/qcom/audio/configs/msm8953/mixer_paths_wcd9326.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_wcd9326.xml \
96hardware/qcom/audio/configs/msm8953/mixer_paths_qrd_skun.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_qrd_skun.xml \
97hardware/qcom/audio/configs/msm8953/mixer_paths_skuk.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_skuk.xml \
98hardware/qcom/audio/configs/msm8953/mixer_paths.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths.xml \
99hardware/qcom/audio/configs/msm8953/sound_trigger_mixer_paths.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths.xml \
100hardware/qcom/audio/configs/msm8953/sound_trigger_mixer_paths_wcd9306.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths_wcd9306.xml \
101hardware/qcom/audio/configs/msm8953/sound_trigger_mixer_paths_wcd9330.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths_wcd9330.xml \
102hardware/qcom/audio/configs/msm8953/sound_trigger_mixer_paths_wcd9335.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_mixer_paths_wcd9335.xml \
103hardware/qcom/audio/configs/msm8953/sound_trigger_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/sound_trigger_platform_info.xml \
104hardware/qcom/audio/configs/msm8953/audio_platform_info.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info.xml \
105hardware/qcom/audio/configs/msm8953/audio_platform_info_extcodec.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_platform_info_extcodec.xml \
Revathi Uddarajufdaeee22017-10-20 12:29:32 +0530106hardware/qcom/audio/configs/msm8953/audio_tuning_mixer.txt:$(TARGET_COPY_OUT_VENDOR)/etc/audio_tuning_mixer.txt
Ashish Jain1221b522016-03-30 15:09:20 +0530107
Satya Krishna Pindiproli013c3e42016-04-13 17:41:15 +0530108#XML Audio configuration files
109ifeq ($(USE_XML_AUDIO_POLICY_CONF), 1)
Dhananjay Kumaraeb58fd2017-07-14 22:45:34 +0530110ifneq ($(TARGET_USES_AOSP_FOR_AUDIO), true)
Satya Krishna Pindiproli013c3e42016-04-13 17:41:15 +0530111PRODUCT_COPY_FILES += \
Dhananjay Kumaraeb58fd2017-07-14 22:45:34 +0530112 $(TOPDIR)hardware/qcom/audio/configs/msm8953/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio/audio_policy_configuration.xml
Satya Krishna Pindiproli87a95f92016-05-09 19:58:33 +0530113endif
114PRODUCT_COPY_FILES += \
Dhananjay Kumaraeb58fd2017-07-14 22:45:34 +0530115 $(TOPDIR)hardware/qcom/audio/configs/common/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_configuration.xml \
Divya Narayanan Poojary2c5f13a2017-07-05 16:54:41 +0530116 $(TOPDIR)frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_audio_policy_configuration.xml \
117 $(TOPDIR)frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_volumes.xml \
118 $(TOPDIR)frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \
119 $(TOPDIR)frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml \
120 $(TOPDIR)frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/usb_audio_policy_configuration.xml
Satya Krishna Pindiproli013c3e42016-04-13 17:41:15 +0530121endif
122
Ashish Jain1221b522016-03-30 15:09:20 +0530123# Reduce client buffer size for fast audio output tracks
124PRODUCT_PROPERTY_OVERRIDES += \
125af.fast_track_multiplier=1
126
127#Low latency audio buffer size in frames
128PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530129vendor.audio_hal.period_size=192
Ashish Jain1221b522016-03-30 15:09:20 +0530130
Dhanalakshmi Siddani30e06a22018-03-27 23:11:34 +0530131PRODUCT_PROPERTY_OVERRIDES += \
132ro.vendor.audio.sdk.ffv=false
133
134##fluencetype can be "fluence" or "fluencepro" or "fluenceffv" or "none"
Ashish Jain1221b522016-03-30 15:09:20 +0530135PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530136ro.vendor.audio.sdk.fluencetype=none\
137persist.vendor.audio.fluence.voicecall=true\
138persist.vendor.audio.fluence.voicerec=false\
139persist.vendor.audio.fluence.speaker=true
Ashish Jain1221b522016-03-30 15:09:20 +0530140
141#disable tunnel encoding
142PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530143vendor.audio.tunnel.encode=false
Ashish Jain1221b522016-03-30 15:09:20 +0530144
145#Buffer size in kbytes for compress offload playback
146PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530147vendor.audio.offload.buffer.size.kb=64
Ashish Jain1221b522016-03-30 15:09:20 +0530148
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
Ashish Jain1221b522016-03-30 15:09:20 +0530157#Enable audio track offload by default
158PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530159vendor.audio.offload.track.enable=true
Ashish Jain1221b522016-03-30 15:09:20 +0530160
161#Enable music through deep buffer
162PRODUCT_PROPERTY_OVERRIDES += \
163audio.deep_buffer.media=true
164
Ashish Jain1221b522016-03-30 15:09:20 +0530165#enable voice path for PCM VoIP by default
166PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530167vendor.voice.path.for.pcm.voip=true
Ashish Jain1221b522016-03-30 15:09:20 +0530168
169#Enable multi channel aac through offload
170PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530171vendor.audio.offload.multiaac.enable=true
Ashish Jain1221b522016-03-30 15:09:20 +0530172
173#Enable DS2, Hardbypass feature for Dolby
174PRODUCT_PROPERTY_OVERRIDES += \
Satya Krishna Pindiproli4a72ae62017-07-02 16:08:11 +0530175vendor.audio.dolby.ds2.enabled=false\
176vendor.audio.dolby.ds2.hardbypass=false
Ashish Jain1221b522016-03-30 15:09:20 +0530177
178#Disable Multiple offload sesison
179PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530180vendor.audio.offload.multiple.enabled=false
Ashish Jain1221b522016-03-30 15:09:20 +0530181
182#Disable Compress passthrough playback
183PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530184vendor.audio.offload.passthrough=false
Ashish Jain1221b522016-03-30 15:09:20 +0530185
186#Disable surround sound recording
187PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530188ro.vendor.audio.sdk.ssr=false
Ashish Jain1221b522016-03-30 15:09:20 +0530189
190#enable dsp gapless mode by default
191PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530192vendor.audio.offload.gapless.enabled=true
Ashish Jain1221b522016-03-30 15:09:20 +0530193
194#enable pbe effects
195PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530196vendor.audio.safx.pbe.enabled=true
Ashish Jain1221b522016-03-30 15:09:20 +0530197
198#parser input buffer size(256kb) in byte stream mode
199PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530200vendor.audio.parser.ip.buffer.size=262144
Ashish Jain1221b522016-03-30 15:09:20 +0530201
202#enable downsampling for multi-channel content > 48Khz
203PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530204vendor.audio.playback.mch.downsample=true
Ashish Jain1221b522016-03-30 15:09:20 +0530205
206#enable software decoders for ALAC and APE.
207PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530208vendor.audio.use.sw.alac.decoder=true\
209vendor.audio.use.sw.ape.decoder=true
Ashish Jain1221b522016-03-30 15:09:20 +0530210
211#property for AudioSphere Post processing
212PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530213vendor.audio.pp.asphere.enabled=false
Ashish Jain1221b522016-03-30 15:09:20 +0530214
215#Audio voice concurrency related flags
216PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530217vendor.voice.playback.conc.disabled=true\
218vendor.voice.record.conc.disabled=false\
219vendor.voice.voip.conc.disabled=true
Ashish Jain1221b522016-03-30 15:09:20 +0530220
221#Decides the audio fallback path during voice call,
222#deep-buffer and fast are the two allowed fallback paths now.
223PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530224vendor.voice.conc.fallbackpath=deep-buffer
Ashish Jain1221b522016-03-30 15:09:20 +0530225
226#Disable speaker protection by default
227PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530228persist.vendor.audio.speaker.prot.enable=false
Ashish Jain1221b522016-03-30 15:09:20 +0530229
230#Enable HW AAC Encoder by default
231PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530232vendor.audio.hw.aac.encoder=true
Satya Krishna Pindiprolid2837402016-08-01 14:16:34 +0530233
234#flac sw decoder 24 bit decode capability
235PRODUCT_PROPERTY_OVERRIDES += \
Ramjee Singh63839662017-05-10 15:27:22 +0530236vendor.audio.flac.sw.decoder.24bit=true
Bharat Pawar50185962017-03-30 14:39:22 +0530237
Satya Krishna Pindiproli650ea152017-09-13 17:10:38 +0530238#Set AudioFlinger client heap size
239PRODUCT_PROPERTY_OVERRIDES += \
240ro.af.client_heap_size_kbyte=7168
241
yidongh2280fb32018-03-30 17:12:42 +0800242#Disable split a2dp
243PRODUCT_PROPERTY_OVERRIDES += \
244persist.vendor.bt.enable.splita2dp=false
245
Bharat Pawar50185962017-03-30 14:39:22 +0530246# for HIDL related packages
247PRODUCT_PACKAGES += \
248 android.hardware.audio@2.0-service \
249 android.hardware.audio@2.0-impl \
250 android.hardware.audio.effect@2.0-impl \
251 android.hardware.soundtrigger@2.0-impl