<?xml version="1.0" encoding="utf-8"?>
<!--
/*
** Copyright 2021, 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.
*/
-->

<!--
  Overlay resources to configure car service based on each OEM's preference.
  See also packages/services/Car/service/res/values/config.xml
-->
<resources>
    <bool name="audioUseDynamicRouting">true</bool>
    <!--  Configuration to enable muting of individual volume groups. If this is set to
          false, muting of individual volume groups is disabled, instead muting will toggle master
          mute. If this is set to true, car volume group muting is enabled and each individual
          volume group can be muted separately. -->
    <bool name="audioUseCarVolumeGroupMuting">true</bool>
    <!--  Configuration to enable IAudioControl#onDevicesToDuckChange API to inform HAL when to
      duck. If this is set to true, the API will receive signals indicating which output devices
      to duck as well as what usages are currently holding focus. If set to false, the API will
      not be called. -->
    <bool name="audioUseHalDuckingSignals">false</bool>
     <!--  Configuration to enable min/max activation volume. If this is set to true, the volume of
          the volume group with min/max activation volume setting will be set to min activation
          volume or max activation volume if volume during activation is lower than min activation
          volume or higher than max activation volume respectively. If this is set to false, no
          volume level will be changed during activation.-->
    <bool name="audioUseMinMaxActivationVolume">true</bool>

    <!--
    Lists all occupant (= driver + passenger) zones available in the car.
    Some examples are:
    <item>occupantZoneId=0,occupantType=DRIVER,seatRow=1,seatSide=driver</item>
    <item>occupantZoneId=1,occupantType=FRONT_PASSENGER,seatRow=1,seatSide=oppositeDriver</item>
    <item>occupantZoneId=2,occupantType=REAR_PASSENGER,seatRow=2,seatSide=left</item>
    <item>occupantZoneId=3,occupantType=REAR_PASSENGER,seatRow=2,seatSide=right</item>

    occupantZoneId: Unique unsigned integer id to represent each passenger zone. Each zone
                    should have different id.
    occupantType: Occupant type for the display. Use * part from
                   CarOccupantZoneManager.OCCUPANT_TYPE_* like DRIVER, FRONT_PASSENGER,
                   REAR_PASSENGER and etc.
    seatRow: Integer telling which row the seat is located. Row 1 is for front seats.
    seatSide: left/center/right for known side. Or can use driver/center/oppositeDriver to
              handle both right-hand driving and left-hand driving in one place.
              If car's RHD / LHD is not specified, LHD will be assumed and driver side becomes
              left.
    -->
    <string-array translatable="false" name="config_occupant_zones">
        <item>occupantZoneId=0,occupantType=DRIVER,seatRow=1,seatSide=driver</item>
    </string-array>
    <!--
        Specifies configuration of displays in system telling its usage / type and assigned
        occupant.

        Some examples are:
        <item>displayPort=0,displayType=MAIN,occupantZoneId=0,inputTypes=DPAD_KEYS|
            NAVIGATE_KEYS|ROTARY_NAVIGATION|TOUCH_SCREEN</item>
        <item>displayPort=1,displayType=INSTRUMENT_CLUSTER,occupantZoneId=0,
            inputTypes=DPAD_KEYS</item>
        <item>displayPort=2,displayType=MAIN,occupantZoneId=1,
            inputTypes=TOUCH_SCREEN</item>
        <item>displayPort=3,displayType=MAIN,occupantZoneId=2,
            inputTypes=TOUCH_SCREEN</item>
        <item>displayUniqueId=virtual:com.example:MainD,displayType=MAIN,occupantZoneId=3,
            inputTypes=TOUCH_SCREEN</item>

        displayPort: Unique port id for the display.
        displayType: Display type for the display. Use * part from
                       CarOccupantZoneManager.DISPLAY_TYPE_* like MAIN, INSTRUMENT_CLUSTER and
                       etc.
        occupantZoneId: occupantZoneId specified from config_occupant_zones.
        inputTypes: supported input types for the corresponding display.
    -->
    <string-array translatable="false" name="config_occupant_display_mapping">
        <item>displayPort=0,displayType=MAIN,occupantZoneId=0,inputTypes=TOUCH_SCREEN|DPAD_KEYS|NAVIGATE_KEYS|ROTARY_NAVIGATION</item>
        <item>displayPort=1,displayType=INSTRUMENT_CLUSTER,occupantZoneId=0,inputTypes=DPAD_KEYS</item>
    </string-array>

    <!-- A name of a camera device that provides the rearview through EVS service -->
    <string-array name="config_carEvsService" translatable="false">
        <item>serviceType=REARVIEW,cameraId=/dev/video10,activityName=com.android.car/com.google.android.car.evs.CarEvsCameraPreviewActivity</item>
        <item>serviceType=FRONTVIEW,cameraId=/dev/video11</item>
    </string-array>
</resources>
