Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mark some spammy logs as verbose. #238

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/backend/device_property.rs
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ pub fn get_device_streams(
debug_assert!(devices.contains(&id));
devices.sort();
let next_id = devices.into_iter().skip_while(|&i| i != id).nth(1);
cubeb_log!(
cubeb_logv!(
"Filtering input streams {:?} for device {}. Next device is {:?}.",
device_streams
.iter()
Expand All @@ -279,7 +279,7 @@ pub fn get_device_streams(
} else {
device_streams.retain(|ds| ds.stream > id);
}
cubeb_log!(
cubeb_logv!(
"Input stream filtering for device {} retained {:?}.",
id,
device_streams
Expand Down
12 changes: 6 additions & 6 deletions src/backend/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1712,7 +1712,7 @@ fn get_device_group_id(
debug_assert_running_serially();
match get_device_transport_type(id, devtype) {
Ok(kAudioDeviceTransportTypeBuiltIn) => {
cubeb_log!(
cubeb_logv!(
"The transport type is {:?}",
convert_uint32_into_string(kAudioDeviceTransportTypeBuiltIn)
);
Expand All @@ -1724,7 +1724,7 @@ fn get_device_group_id(
};
}
Ok(trans_type) => {
cubeb_log!(
cubeb_logv!(
"The transport type is {:?}. Getting model UID instead.",
convert_uint32_into_string(trans_type)
);
Expand Down Expand Up @@ -1755,7 +1755,7 @@ fn get_custom_group_id(id: AudioDeviceID, devtype: DeviceType) -> Option<CString
match get_device_source(id, devtype) {
s @ Ok(IMIC) | s @ Ok(ISPK) => {
const GROUP_ID: &str = "builtin-internal-mic|spk";
cubeb_log!(
cubeb_logv!(
"Using hardcode group id: {} when source is: {:?}.",
GROUP_ID,
convert_uint32_into_string(s.unwrap())
Expand All @@ -1764,7 +1764,7 @@ fn get_custom_group_id(id: AudioDeviceID, devtype: DeviceType) -> Option<CString
}
s @ Ok(EMIC) | s @ Ok(HDPN) => {
const GROUP_ID: &str = "builtin-external-mic|hdpn";
cubeb_log!(
cubeb_logv!(
"Using hardcode group id: {} when source is: {:?}.",
GROUP_ID,
convert_uint32_into_string(s.unwrap())
Expand Down Expand Up @@ -2011,7 +2011,7 @@ fn audiounit_get_devices_of_type(devtype: DeviceType) -> Vec<AudioObjectID> {
let info = format!("{} ({})", device, label);

if let Ok(channels) = get_channel_count(device, devtype) {
cubeb_log!("Device {} has {} {:?}-channels", info, channels, devtype);
cubeb_logv!("Device {} has {} {:?}-channels", info, channels, devtype);
if channels > 0 {
devices_in_scope.push(device);
}
Expand Down Expand Up @@ -3271,7 +3271,7 @@ impl<'ctx> CoreStreamData<'ctx> {
debug_assert_running_serially();
match get_device_transport_type(id, DeviceType::INPUT) {
Ok(kAudioDeviceTransportTypeBuiltIn) => {
cubeb_log!(
cubeb_logv!(
"Input device {} is on the VPIO force list because it is built in, \
and its volume is known to be very low without VPIO whenever VPIO \
is hooked up to it elsewhere.",
Expand Down
Loading