Lines Matching refs:ch_mode
47 uint8_t ch_mode; /* Channel mode */ member
130 (p_ie->ch_mode & ~A2DP_SBC_IE_CH_MD_MSK) || in A2DP_BuildInfoSbc()
148 *p_result++ = p_ie->samp_freq | p_ie->ch_mode; in A2DP_BuildInfoSbc()
185 p_ie->ch_mode = *p_codec_info & A2DP_SBC_IE_CH_MD_MSK; in A2DP_ParseInfoSbc()
209 if (A2DP_BitsSet(p_ie->ch_mode) == A2DP_SET_ZERO_BIT) in A2DP_ParseInfoSbc()
223 if (A2DP_BitsSet(p_ie->ch_mode) != A2DP_SET_ONE_BIT) return A2DP_BAD_CH_MODE; in A2DP_ParseInfoSbc()
365 cfg_cie.ch_mode, p_cap->ch_mode); in A2DP_CodecInfoMatchesCapabilitySbc()
381 if ((cfg_cie.ch_mode & p_cap->ch_mode) == 0) return A2DP_NS_CH_MODE; in A2DP_CodecInfoMatchesCapabilitySbc()
452 (sbc_cie_a.ch_mode == sbc_cie_b.ch_mode) && in A2DP_CodecEqualsSbc()
507 switch (sbc_cie.ch_mode) { in A2DP_GetTrackChannelCountSbc()
597 switch (sbc_cie.ch_mode) { in A2DP_GetChannelModeCodeSbc()
672 switch (sbc_cie.ch_mode) { in A2DP_GetSinkTrackChannelTypeSbc()
733 AppendField(&field, (sbc_cie.ch_mode == 0), "NONE"); in A2DP_CodecInfoStringSbc()
734 AppendField(&field, (sbc_cie.ch_mode & A2DP_SBC_IE_CH_MD_MONO), "Mono"); in A2DP_CodecInfoStringSbc()
735 AppendField(&field, (sbc_cie.ch_mode & A2DP_SBC_IE_CH_MD_DUAL), "Dual"); in A2DP_CodecInfoStringSbc()
736 AppendField(&field, (sbc_cie.ch_mode & A2DP_SBC_IE_CH_MD_STEREO), "Stereo"); in A2DP_CodecInfoStringSbc()
737 AppendField(&field, (sbc_cie.ch_mode & A2DP_SBC_IE_CH_MD_JOINT), "Joint"); in A2DP_CodecInfoStringSbc()
738 res << "\tch_mode: " << field << " (" << loghex(sbc_cie.ch_mode) << ")\n"; in A2DP_CodecInfoStringSbc()
853 if (config_cie.ch_mode & A2DP_SBC_IE_CH_MD_MONO) in build_codec_config()
856 if (config_cie.ch_mode & (A2DP_SBC_IE_CH_MD_STEREO | A2DP_SBC_IE_CH_MD_JOINT | in build_codec_config()
875 if (a2dp_sbc_source_caps.ch_mode & A2DP_SBC_IE_CH_MD_MONO) { in A2dpCodecConfigSbcSource()
878 if (a2dp_sbc_source_caps.ch_mode & A2DP_SBC_IE_CH_MD_JOINT) { in A2dpCodecConfigSbcSource()
881 if (a2dp_sbc_source_caps.ch_mode & A2DP_SBC_IE_CH_MD_STEREO) { in A2dpCodecConfigSbcSource()
884 if (a2dp_sbc_source_caps.ch_mode & A2DP_SBC_IE_CH_MD_DUAL) { in A2dpCodecConfigSbcSource()
998 static bool select_best_channel_mode(uint8_t ch_mode, tA2DP_SBC_CIE* p_result, in select_best_channel_mode() argument
1000 if (ch_mode & A2DP_SBC_IE_CH_MD_JOINT) { in select_best_channel_mode()
1001 p_result->ch_mode = A2DP_SBC_IE_CH_MD_JOINT; in select_best_channel_mode()
1005 if (ch_mode & A2DP_SBC_IE_CH_MD_STEREO) { in select_best_channel_mode()
1006 p_result->ch_mode = A2DP_SBC_IE_CH_MD_STEREO; in select_best_channel_mode()
1010 if (ch_mode & A2DP_SBC_IE_CH_MD_DUAL) { in select_best_channel_mode()
1011 p_result->ch_mode = A2DP_SBC_IE_CH_MD_DUAL; in select_best_channel_mode()
1015 if (ch_mode & A2DP_SBC_IE_CH_MD_MONO) { in select_best_channel_mode()
1016 p_result->ch_mode = A2DP_SBC_IE_CH_MD_MONO; in select_best_channel_mode()
1030 const btav_a2dp_codec_config_t* p_codec_audio_config, uint8_t ch_mode, in select_audio_channel_mode() argument
1034 if (ch_mode & A2DP_SBC_IE_CH_MD_MONO) { in select_audio_channel_mode()
1035 p_result->ch_mode = A2DP_SBC_IE_CH_MD_MONO; in select_audio_channel_mode()
1041 if (ch_mode & A2DP_SBC_IE_CH_MD_JOINT) { in select_audio_channel_mode()
1042 p_result->ch_mode = A2DP_SBC_IE_CH_MD_JOINT; in select_audio_channel_mode()
1046 if (ch_mode & A2DP_SBC_IE_CH_MD_STEREO) { in select_audio_channel_mode()
1047 p_result->ch_mode = A2DP_SBC_IE_CH_MD_STEREO; in select_audio_channel_mode()
1051 if (ch_mode & A2DP_SBC_IE_CH_MD_DUAL) { in select_audio_channel_mode()
1052 p_result->ch_mode = A2DP_SBC_IE_CH_MD_DUAL; in select_audio_channel_mode()
1071 uint8_t ch_mode; in setCodecConfig() local
1263 ch_mode = p_a2dp_sbc_caps->ch_mode & peer_info_cie.ch_mode; in setCodecConfig()
1267 if (ch_mode & A2DP_SBC_IE_CH_MD_MONO) { in setCodecConfig()
1268 result_config_cie.ch_mode = A2DP_SBC_IE_CH_MD_MONO; in setCodecConfig()
1274 if (ch_mode & A2DP_SBC_IE_CH_MD_JOINT) { in setCodecConfig()
1275 result_config_cie.ch_mode = A2DP_SBC_IE_CH_MD_JOINT; in setCodecConfig()
1280 if (ch_mode & A2DP_SBC_IE_CH_MD_STEREO) { in setCodecConfig()
1281 result_config_cie.ch_mode = A2DP_SBC_IE_CH_MD_STEREO; in setCodecConfig()
1286 if (ch_mode & A2DP_SBC_IE_CH_MD_DUAL) { in setCodecConfig()
1287 result_config_cie.ch_mode = A2DP_SBC_IE_CH_MD_DUAL; in setCodecConfig()
1302 if (ch_mode & A2DP_SBC_IE_CH_MD_MONO) { in setCodecConfig()
1306 if (ch_mode & A2DP_SBC_IE_CH_MD_JOINT) { in setCodecConfig()
1310 if (ch_mode & A2DP_SBC_IE_CH_MD_STEREO) { in setCodecConfig()
1314 if (ch_mode & A2DP_SBC_IE_CH_MD_DUAL) { in setCodecConfig()
1322 if (ch_mode & A2DP_SBC_IE_CH_MD_MONO) in setCodecConfig()
1324 if (ch_mode & (A2DP_SBC_IE_CH_MD_JOINT | A2DP_SBC_IE_CH_MD_STEREO | in setCodecConfig()
1330 if (select_audio_channel_mode(&codec_audio_config_, ch_mode, in setCodecConfig()
1337 a2dp_sbc_default_config.ch_mode & peer_info_cie.ch_mode, in setCodecConfig()
1343 if (select_best_channel_mode(ch_mode, &result_config_cie, &codec_config_)) { in setCodecConfig()
1351 __func__, p_a2dp_sbc_caps->ch_mode, peer_info_cie.ch_mode); in setCodecConfig()
1477 uint8_t ch_mode; in setPeerCodecCapabilities() local
1512 ch_mode = p_a2dp_sbc_caps->ch_mode & peer_info_cie.ch_mode; in setPeerCodecCapabilities()
1513 if (ch_mode & A2DP_SBC_IE_CH_MD_MONO) { in setPeerCodecCapabilities()
1517 if (ch_mode & A2DP_SBC_IE_CH_MD_JOINT) { in setPeerCodecCapabilities()
1521 if (ch_mode & A2DP_SBC_IE_CH_MD_STEREO) { in setPeerCodecCapabilities()
1525 if (ch_mode & A2DP_SBC_IE_CH_MD_DUAL) { in setPeerCodecCapabilities()