diff --git a/include/system/audio.h b/include/system/audio.h old mode 100755 new mode 100644 index 5cfaabbc..2a269e64 --- a/include/system/audio.h +++ b/include/system/audio.h @@ -1,6 +1,6 @@ /* * Copyright (C) 2011 The Android Open Source Project - * Copyright (c) 2012, The Linux Foundation. All rights reserved. + * Copyright (c) 2012-2013, The Linux Foundation. All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -32,15 +32,15 @@ __BEGIN_DECLS * frameworks/base/include/media/AudioSystem.h */ +/* device address used to refer to the standard remote submix */ +#define AUDIO_REMOTE_SUBMIX_DEVICE_ADDRESS "0" + #define AMR_FRAMESIZE 32 #define QCELP_FRAMESIZE 35 #define EVRC_FRAMESIZE 23 #define AMR_WB_FRAMESIZE 61 #define AAC_FRAMESIZE 2048 -/* device address used to refer to the standard remote submix */ -#define AUDIO_REMOTE_SUBMIX_DEVICE_ADDRESS "0" - typedef int audio_io_handle_t; /* Audio stream types */ @@ -80,6 +80,10 @@ typedef enum { /* An example of remote presentation is Wifi Display */ /* where a dongle attached to a TV can be used to */ /* play the mix captured by this audio source. */ +#ifdef QCOM_FM_ENABLED + AUDIO_SOURCE_FM_RX = 9, + AUDIO_SOURCE_FM_RX_A2DP = 10, +#endif AUDIO_SOURCE_CNT, AUDIO_SOURCE_MAX = AUDIO_SOURCE_CNT - 1, AUDIO_SOURCE_HOTWORD = 1999, /* A low-priority, preemptible audio source for @@ -394,8 +398,10 @@ enum { AUDIO_DEVICE_OUT_ANC_HEADSET = 0x10000, AUDIO_DEVICE_OUT_ANC_HEADPHONE = 0x20000, AUDIO_DEVICE_OUT_PROXY = 0x40000, +#ifdef QCOM_FM_ENABLED AUDIO_DEVICE_OUT_FM = 0x80000, AUDIO_DEVICE_OUT_FM_TX = 0x100000, +#endif #endif AUDIO_DEVICE_OUT_DEFAULT = AUDIO_DEVICE_BIT_DEFAULT, AUDIO_DEVICE_OUT_ALL = (AUDIO_DEVICE_OUT_EARPIECE | @@ -418,8 +424,10 @@ enum { AUDIO_DEVICE_OUT_ANC_HEADSET | AUDIO_DEVICE_OUT_ANC_HEADPHONE | AUDIO_DEVICE_OUT_PROXY | +#ifdef QCOM_FM_ENABLED AUDIO_DEVICE_OUT_FM | AUDIO_DEVICE_OUT_FM_TX | +#endif #endif AUDIO_DEVICE_OUT_DEFAULT), AUDIO_DEVICE_OUT_ALL_A2DP = (AUDIO_DEVICE_OUT_BLUETOOTH_A2DP | @@ -464,8 +472,10 @@ enum { #ifdef QCOM_HARDWARE AUDIO_DEVICE_IN_ANC_HEADSET = AUDIO_DEVICE_BIT_IN | 0x2000, AUDIO_DEVICE_IN_PROXY = AUDIO_DEVICE_BIT_IN | 0x4000, +#ifdef QCOM_FM_ENABLED AUDIO_DEVICE_IN_FM_RX = AUDIO_DEVICE_BIT_IN | 0x8000, AUDIO_DEVICE_IN_FM_RX_A2DP = AUDIO_DEVICE_BIT_IN | 0x10000, +#endif #endif AUDIO_DEVICE_IN_DEFAULT = AUDIO_DEVICE_BIT_IN | AUDIO_DEVICE_BIT_DEFAULT, #endif @@ -485,8 +495,10 @@ enum { AUDIO_DEVICE_IN_USB_DEVICE | #ifdef QCOM_HARDWARE AUDIO_DEVICE_IN_ANC_HEADSET | +#ifdef QCOM_FM_ENABLED AUDIO_DEVICE_IN_FM_RX | AUDIO_DEVICE_IN_FM_RX_A2DP | +#endif AUDIO_DEVICE_IN_PROXY | #endif AUDIO_DEVICE_IN_DEFAULT), @@ -520,7 +532,7 @@ typedef enum { // streams to hardware codec AUDIO_OUTPUT_FLAG_NON_BLOCKING = 0x20, // use non-blocking write #ifdef QCOM_HARDWARE - //Qualcomm Flags + //MSM Flags AUDIO_OUTPUT_FLAG_LPA = 0x1000, // use LPA AUDIO_OUTPUT_FLAG_TUNNEL = 0x2000, // use Tunnel AUDIO_OUTPUT_FLAG_VOIP_RX = 0x4000, // use this flag in combination with DIRECT to