Home
last modified time | relevance | path

Searched refs:channelMask (Results 1 – 25 of 151) sorted by relevance

1234567

/frameworks/av/media/libaaudio/src/utility/
DAAudioUtilities.cpp317 aaudio_channel_mask_t channelMask, bool isInput) { in AAudioConvert_aaudioToAndroidChannelLayoutMask() argument
319 switch (channelMask) { in AAudioConvert_aaudioToAndroidChannelLayoutMask()
337 ALOGE("%s() %#x unrecognized", __func__, channelMask); in AAudioConvert_aaudioToAndroidChannelLayoutMask()
341 switch (channelMask) { in AAudioConvert_aaudioToAndroidChannelLayoutMask()
391 ALOGE("%s() %#x unrecognized", __func__, channelMask); in AAudioConvert_aaudioToAndroidChannelLayoutMask()
398 audio_channel_mask_t channelMask, bool isInput) { in AAudioConvert_androidToAAudioChannelLayoutMask() argument
400 switch (channelMask) { in AAudioConvert_androidToAAudioChannelLayoutMask()
418 ALOGE("%s() %#x unrecognized", __func__, channelMask); in AAudioConvert_androidToAAudioChannelLayoutMask()
422 switch (channelMask) { in AAudioConvert_androidToAAudioChannelLayoutMask()
472 ALOGE("%s() %#x unrecognized", __func__, channelMask); in AAudioConvert_androidToAAudioChannelLayoutMask()
[all …]
DAAudioUtilities.h107 aaudio_channel_mask_t channelMask, bool isInput);
110 audio_channel_mask_t channelMask, bool isInput);
113 audio_channel_mask_t channelMask);
116 aaudio_channel_mask_t channelMask);
119 audio_channel_mask_t channelMask, bool isInput, bool indexMaskRequired);
122 aaudio_channel_mask_t channelMask, bool isInput);
124 bool AAudio_isChannelIndexMask(aaudio_channel_mask_t channelMask);
126 int32_t AAudioConvert_channelMaskToCount(aaudio_channel_mask_t channelMask);
131 aaudio_channel_mask_t channelMask, int32_t samplesPerFrame, bool isInput);
/frameworks/av/media/libmediahelper/tests/
Dtypeconverter_tests.cpp35 audio_channel_mask_t channelMask = channelMaskFromString(stringVal); in TEST() local
37 audio_channel_mask_is_valid(channelMask)) in TEST()
45 audio_channel_mask_t channelMask, channelMaskBack; in TEST() local
48 EXPECT_TRUE(InputChannelConverter::fromString(stringVal, channelMask)) in TEST()
50 EXPECT_TRUE(InputChannelConverter::toString(channelMask, stringValBack)) in TEST()
51 << "Conversion of input channel mask " << channelMask << " failed"; in TEST()
56 EXPECT_EQ(channelMask, channelMaskBack); in TEST()
58 EXPECT_TRUE(OutputChannelConverter::fromString(stringVal, channelMask)) in TEST()
60 EXPECT_TRUE(OutputChannelConverter::toString(channelMask, stringValBack)) in TEST()
61 << "Conversion of output channel mask " << channelMask << " failed"; in TEST()
[all …]
/frameworks/av/media/libeffects/downmix/aidl/
DDownmixContext.cpp32 inline bool isChannelMaskValid(const AudioChannelLayout& channelMask) { in isChannelMaskValid() argument
33 if (channelMask.getTag() != AudioChannelLayout::layoutMask) return false; in isChannelMaskValid()
34 int chMask = channelMask.get<AudioChannelLayout::layoutMask>(); in isChannelMaskValid()
46 inline bool isStereoChannelMask(const AudioChannelLayout& channelMask) { in isStereoChannelMask() argument
47 if (channelMask.getTag() != AudioChannelLayout::layoutMask) return false; in isStereoChannelMask()
49 return channelMask.get<AudioChannelLayout::layoutMask>() == AudioChannelLayout::LAYOUT_STEREO; in isStereoChannelMask()
63 if (!isStereoChannelMask(output.base.channelMask)) { in validateCommonConfig()
65 << output.base.channelMask.toString(); in validateCommonConfig()
69 if (!isChannelMaskValid(input.base.channelMask)) { in validateCommonConfig()
70 LOG(ERROR) << __func__ << ": invalid input channel, " << input.base.channelMask.toString(); in validateCommonConfig()
[all …]
/frameworks/av/services/audiopolicy/common/managerdefinitions/src/
DAudioProfileVectorHelper.cpp182 audio_channel_mask_t channelMask, in checkExact() argument
186 audioProfile->supportsChannels(channelMask) && in checkExact()
195 audio_channel_mask_t channelMask, in checkIdentical() argument
198 audioProfile->supportsChannels(channelMask) && in checkIdentical()
242 audio_channel_mask_t channelMask, in checkCompatibleChannelMask() argument
249 updatedChannelMask = channelMask; in checkCompatibleChannelMask()
253 const bool isIndex = audio_channel_mask_get_representation(channelMask) in checkCompatibleChannelMask()
255 const uint32_t channelCount = audio_channel_count_from_in_mask(channelMask); in checkCompatibleChannelMask()
258 if (supported == channelMask) { in checkCompatibleChannelMask()
260 updatedChannelMask = channelMask; in checkCompatibleChannelMask()
[all …]
DPolicyAudioPort.cpp117 for (const auto channelMask : channelMasks) { in pickChannelMask() local
120 cnlCount = audio_channel_count_from_in_mask(channelMask); in pickChannelMask()
122 cnlCount = audio_channel_count_from_out_mask(channelMask); in pickChannelMask()
125 pickedChannelMask = channelMask; in pickChannelMask()
138 for (const auto channelMask : channelMasks) { in pickChannelMask() local
141 cnlCount = audio_channel_count_from_in_mask(channelMask); in pickChannelMask()
143 cnlCount = audio_channel_count_from_out_mask(channelMask); in pickChannelMask()
146 pickedChannelMask = channelMask; in pickChannelMask()
215 audio_channel_mask_t &channelMask, in pickAudioProfile() argument
220 channelMask = AUDIO_CHANNEL_NONE; in pickAudioProfile()
[all …]
DIOProfile.cpp42 audio_channel_mask_t channelMask, in getCompatibilityScore() argument
58 (isPlaybackThread && (samplingRate == 0 || !audio_is_output_channel(channelMask))) || in getCompatibilityScore()
59 (isRecordThread && (!audio_is_input_channel(channelMask)))) { in getCompatibilityScore()
64 audio_channel_mask_t myUpdatedChannelMask = channelMask; in getCompatibilityScore()
69 .channel_mask = channelMask, in getCompatibilityScore()
171 for (const auto channelMask : profile->getChannels()) { in toSupportedMixerAttributes() local
174 .channel_mask = channelMask, in toSupportedMixerAttributes()
/frameworks/av/media/libaudioprocessing/
DAudioMixer.cpp66 bool AudioMixer::isValidChannelMask(audio_channel_mask_t channelMask) const { in isValidChannelMask()
67 return audio_channel_mask_is_valid(channelMask); // the RemixBufferProvider is flexible. in isValidChannelMask()
78 if (trackChannelMask == (track->channelMask | track->mHapticChannelMask) in setChannelMasks()
100 track->channelMask = trackChannelMask; in setChannelMasks()
127 status, track->channelMask, track->mMixerChannelMask); in setChannelMasks()
162 this, channelMask); in prepareForDownmix()
168 if (channelMask == mMixerChannelMask in prepareForDownmix()
169 || (channelMask == AUDIO_CHANNEL_OUT_MONO in prepareForDownmix()
174 if (audio_channel_mask_get_representation(channelMask) in prepareForDownmix()
181 channelMask, mMixerChannelMask, in prepareForDownmix()
[all …]
/frameworks/base/media/java/android/media/
DAudioGain.java76 AudioGain(int index, int mode, int channelMask, in AudioGain() argument
81 mChannelMask = channelMask; in AudioGain()
101 public int channelMask() { in channelMask() method in AudioGain
158 public AudioGainConfig buildConfig(int mode, int channelMask, in buildConfig() argument
161 return new AudioGainConfig(mIndex, this, mode, channelMask, values, rampDurationMs); in buildConfig()
DAudioDevicePortConfig.java33 AudioDevicePortConfig(AudioDevicePort devicePort, int samplingRate, int channelMask, in AudioDevicePortConfig() argument
35 super((AudioPort)devicePort, samplingRate, channelMask, format, gain); in AudioDevicePortConfig() local
39 this(config.port(), config.samplingRate(), config.channelMask(), config.format(), in AudioDevicePortConfig()
DAudioGainConfig.java43 AudioGainConfig(int index, AudioGain gain, int mode, int channelMask, in AudioGainConfig() argument
48 mChannelMask = channelMask; in AudioGainConfig()
73 public int channelMask() { in channelMask() method in AudioGainConfig
DAudioPortConfig.java58 AudioPortConfig(AudioPort port, int samplingRate, int channelMask, int format, in AudioPortConfig() argument
62 mChannelMask = channelMask; in AudioPortConfig()
86 public int channelMask() { in channelMask() method in AudioPortConfig
DAudioMixPortConfig.java33 AudioMixPortConfig(AudioMixPort mixPort, int samplingRate, int channelMask, int format, in AudioMixPortConfig() argument
35 super((AudioPort)mixPort, samplingRate, channelMask, format, gain); in AudioMixPortConfig() local
/frameworks/base/core/jni/
Dandroid_media_AudioFormat.h233 static inline audio_channel_mask_t outChannelMaskToNative(int channelMask) in outChannelMaskToNative() argument
235 switch (channelMask) { in outChannelMaskToNative()
240 return (audio_channel_mask_t)(channelMask>>2); in outChannelMaskToNative()
254 static inline audio_channel_mask_t inChannelMaskToNative(int channelMask) in inChannelMaskToNative() argument
256 switch (channelMask) { in inChannelMaskToNative()
260 return (audio_channel_mask_t)channelMask; in inChannelMaskToNative()
/frameworks/av/media/libeffects/downmix/tests/
Ddownmix_tests.cpp153 void testBalance(int sampleRate, audio_channel_mask_t channelMask) { in testBalance() argument
158 unsigned inChannels = audio_channel_count_from_out_mask(channelMask); in testBalance()
163 for (unsigned i = 0, channel = channelMask; channel != 0; ++i) { in testBalance()
178 run(sampleRate, channelMask, input, output, frames); in testBalance()
213 if (channelMask & AUDIO_CHANNEL_OUT_LOW_FREQUENCY_2) { in testBalance()
232 void run(int sampleRate, audio_channel_mask_t channelMask, in run() argument
234 reconfig(sampleRate, channelMask); in run()
285 void reconfig(int sampleRate, audio_channel_mask_t channelMask) { in reconfig() argument
301 config_.inputCfg.channels = channelMask; in reconfig()
353 const audio_channel_mask_t channelMask = kChannelPositionMasks[index]; in __anon89f60d5e0102() local
[all …]
/frameworks/av/media/libaudioclient/tests/
Dtest_create_audiotrack.cpp61 audio_channel_mask_t channelMask; in testTrack() local
78 if (sscanf(line, " %u %x %x %zu %d %u %x %u %u %u", &sampleRate, &format, &channelMask, in testTrack()
88 size_t heapSize = audio_channel_count_from_out_mask(channelMask) * in testTrack()
97 offloadInfo.channel_mask = channelMask; in testTrack()
110 track->set(AUDIO_STREAM_DEFAULT, sampleRate, format, channelMask, frameCount, flags, in testTrack()
Dtest_create_audiorecord.cpp69 audio_channel_mask_t channelMask; in testRecord() local
80 if (sscanf(line, " %u %x %x %zu %d %x %u %u", &sampleRate, &format, &channelMask, in testRecord()
99 record->set(AUDIO_SOURCE_DEFAULT, sampleRate, format, channelMask, frameCount, in testRecord()
/frameworks/av/media/libeffects/downmix/benchmark/
Ddownmix_benchmark.cpp95 const audio_channel_mask_t channelMask = kChannelPositionMasks[state.range(0)]; in BM_Downmix() local
96 const size_t channelCount = audio_channel_count_from_out_mask(channelMask); in BM_Downmix()
100 std::minstd_rand gen(channelMask); in BM_Downmix()
131 config.inputCfg.channels = channelMask; in BM_Downmix()
166 state.SetLabel(audio_channel_out_mask_to_string(channelMask)); in BM_Downmix()
/frameworks/av/services/audiopolicy/common/managerdefinitions/include/
DAudioProfileVectorHelper.h55 audio_channel_mask_t channelMask,
72 audio_channel_mask_t channelMask,
77 audio_channel_mask_t &channelMask,
DPolicyAudioPort.h70 audio_channel_mask_t &channelMask, in checkCompatibleAudioProfile() argument
74 asAudioPort()->getAudioProfiles(), samplingRate, channelMask, format, in checkCompatibleAudioProfile()
79 audio_channel_mask_t &channelMask,
104 void pickChannelMask(audio_channel_mask_t &channelMask,
/frameworks/av/media/audioaidlconversion/
DAidlConversionNdk.cpp90 aidl2legacy_AudioChannelLayout_audio_channel_mask_t(aidl.base.channelMask, isInput)); in aidl2legacy_AudioConfig_buffer_config_t()
110 aidl.base.channelMask = VALUE_OR_RETURN(legacy2aidl_audio_channel_mask_t_AudioChannelLayout( in legacy2aidl_buffer_config_t_AudioConfig()
146 aidl.channelMask, false /*isInput*/)); in aidl2legacy_PlaybackTrackMetadata_playback_track_metadata_v7()
159 aidl.channelMask = VALUE_OR_RETURN(legacy2aidl_audio_channel_mask_t_AudioChannelLayout( in legacy2aidl_playback_track_metadata_v7_PlaybackTrackMetadata()
177 aidl.channelMask, true /*isInput*/)); in aidl2legacy_RecordTrackMetadata_record_track_metadata_v7()
191 aidl.channelMask = VALUE_OR_RETURN(legacy2aidl_audio_channel_mask_t_AudioChannelLayout( in legacy2aidl_record_track_metadata_v7_RecordTrackMetadata()
/frameworks/base/media/jni/soundpool/
DSound.cpp50 audio_channel_mask_t *channelMask, const sp<MemoryHeapBase>& heap, in decode() argument
187 *channelMask = audio_channel_mask_from_media_format_mask(mediaFormatChannelMask); in decode()
189 *channelMask = AUDIO_CHANNEL_NONE; in decode()
209 audio_channel_mask_t channelMask; in doLoad() local
211 &channelMask, mHeap, &mSizeInBytes); in doLoad()
231 mChannelMask = channelMask; in doLoad()
/frameworks/wilhelm/tests/sandbox/
Dsrcsink.c48 format_pcm.channelMask = SL_SPEAKER_FRONT_LEFT | SL_SPEAKER_FRONT_RIGHT; in main()
161 format_pcm.channelMask = 0; in main()
167 format_pcm.channelMask = SL_SPEAKER_FRONT_CENTER; in main()
172 format_pcm.channelMask = SL_SPEAKER_FRONT_LEFT | SL_SPEAKER_FRONT_RIGHT | in main()
179 format_pcm.channelMask = 0; in main()
185 format_pcm.channelMask = SL_SPEAKER_FRONT_LEFT | SL_SPEAKER_FRONT_RIGHT; in main()
/frameworks/av/media/libaudioprocessing/include/media/
DAudioMixerBase.h102 virtual bool isValidChannelMask(audio_channel_mask_t channelMask) const;
117 int name, audio_channel_mask_t channelMask, audio_format_t format, int sessionId);
204 static bool isAudioChannelPositionMask(audio_channel_mask_t channelMask) { in isAudioChannelPositionMask() argument
205 return audio_channel_mask_get_representation(channelMask) in isAudioChannelPositionMask()
233 bool useStereoVolume() const { return channelMask == AUDIO_CHANNEL_OUT_STEREO in useStereoVolume()
264 audio_channel_mask_t channelMask; member
/frameworks/wilhelm/src/android/
DAudioRecorder_to_android.cpp630 df_pcm->channelMask, in android_audioRecorder_realize()
635 audio_channel_mask_t channelMask = sles_to_audio_input_channel_mask(df_pcm->channelMask); in android_audioRecorder_realize() local
639 if (channelMask == AUDIO_CHANNEL_INVALID in android_audioRecorder_realize()
640 || audio_channel_mask_get_representation(channelMask) in android_audioRecorder_realize()
642 channelMask = audio_channel_in_mask_from_count(df_pcm->numChannels); in android_audioRecorder_realize()
645 "channel count of %d)", df_pcm->channelMask, channelMask, in android_audioRecorder_realize()
648 SL_LOGV("SLES channel mask %#x converted to Android mask %#x", df_pcm->channelMask, in android_audioRecorder_realize()
649 channelMask); in android_audioRecorder_realize()
662 channelMask, // channel mask in android_audioRecorder_realize()

1234567