Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dd6da3e1 authored by Mikhail Naganov's avatar Mikhail Naganov
Browse files

Audio Policy: enable surround sound configuration in xml

The surround sound configuration used to be disabled. This patch
enables it, and moves out the surround sound configuration into
a dedicated file.

Bug: 116356348
Test: xmllint --noout --xinclude --schema \
      hardware/interfaces/audio/5.0/config/audio_policy_configuration.xsd \
      frameworks/av/services/audiopolicy/config/audio_policy_configuration.xml

Change-Id: I26eb55b818d813494fc31812d00e33851b79f02b
parent 6b01bf3f
Loading
Loading
Loading
Loading
+5 −22
Original line number Diff line number Diff line
@@ -198,27 +198,10 @@

    <!-- End of Volume section -->

    <?disabledUntilHalV5_0
    <!-- Surround configuration -->

    <surroundSound>
      <!-- Each of the listed formats gets an entry in Surround Settings dialog.
           There must be a corresponding Java ENCODING_... contant defined in AudioFormat.java,
           and a display name defined in AudioFormat.toDisplayName. For the formats that don't
           need a dedicated Surrond Settings dialog entry, a subformats list should be used. -->
      <formats>
        <format name="AUDIO_FORMAT_AC3" />
        <format name="AUDIO_FORMAT_E_AC3" />
        <format name="AUDIO_FORMAT_E_AC3_JOC" />
        <format name="AUDIO_FORMAT_DOLBY_TRUEHD" />
        <format name="AUDIO_FORMAT_DTS" />
        <format name="AUDIO_FORMAT_DTS_HD" />
        <format name="AUDIO_FORMAT_AAC_LC" subformats="AUDIO_FORMAT_AAC_HE_V1 AUDIO_FORMAT_AAC_HE_V2 AUDIO_FORMAT_AAC_ELD AUDIO_FORMAT_AAC_XHE" />
        <format name="AUDIO_FORMAT_AC4" />
      </formats>
    </surroundSound>

    <!-- End of Surround configuration -->
    ?>
    <!-- Surround Sound configuration -->

    <xi:include href="surround_sound_configuration_5_0.xml"/>

    <!-- End of Surround Sound configuration -->

</audioPolicyConfiguration>
+31 −0
Original line number Diff line number Diff line
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!-- Copyright (C) 2018 The Android Open Source Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->
<surroundSound>
  <!-- Each of the listed formats gets an entry in Surround Settings dialog on TV devices.
       There must be a corresponding Java ENCODING_... contant defined in AudioFormat.java,
       and a display name defined in AudioFormat.toDisplayName. For the formats that don't
       need a dedicated Surrond Settings dialog entry, a subformats list has to be used. -->
  <formats>
    <format name="AUDIO_FORMAT_AC3" />
    <format name="AUDIO_FORMAT_E_AC3" />
    <format name="AUDIO_FORMAT_E_AC3_JOC" />
    <format name="AUDIO_FORMAT_DOLBY_TRUEHD" />
    <format name="AUDIO_FORMAT_DTS" />
    <format name="AUDIO_FORMAT_DTS_HD" />
    <format name="AUDIO_FORMAT_AAC_LC" subformats="AUDIO_FORMAT_AAC_HE_V1 AUDIO_FORMAT_AAC_HE_V2 AUDIO_FORMAT_AAC_ELD AUDIO_FORMAT_AAC_XHE" />
    <format name="AUDIO_FORMAT_AC4" />
  </formats>
</surroundSound>