You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In web-audio-api-rs-main/src/node/channel_merger.rs, the comment indicates code will panic when count <= 2, while the code will panic when count != 1.
/// # Panics////// This function panics if given count is greater than 2///#[track_caller]#[inline(always)]fnassert_valid_channel_count(count:usize){assert!(
count == 1,"InvalidStateError - channel count of ChannelMergerNode must be equal to 1");}
In web-audio-api-rs-main/src/lib.rs
/// # Panics////// This function will panic if:/// - the given sample rate is lower than 4000 or greater than 192000///#[track_caller]#[inline(always)]pub(crate)fnassert_valid_sample_rate(sample_rate:f32){// Arbitrary cutoffs defined as:// min_sample_rate = min_required_in_spec / 4// max_sample_rate = max_required_in_spec * 4let min_sample_rate = 2_000.;let max_sample_rate = 384_000.;assert!(
sample_rate >= min_sample_rate && sample_rate <= max_sample_rate,"NotSupportedError - Invalid sample rate: {:?}, should be in the range [{:?}, {:?}]",
sample_rate,
min_sample_rate,
max_sample_rate,);}
In web-audio-api-rs-new-main/src/node/panner.rs, the comment indicates code will panic when value < 0.0, while the code will panic when value <= 0.0 .
/// # Panics////// Panics if the provided value is negative.pubfnset_max_distance(&mutself,value:f64){assert!(value > 0.,"RangeError - maxDistance must be positive");self.max_distance = value;self.registration.post_message(ControlMessage::MaxDistance(value));}
The text was updated successfully, but these errors were encountered:
In web-audio-api-rs-main/src/node/channel_merger.rs, the comment indicates code will panic when count <= 2, while the code will panic when count != 1.
In web-audio-api-rs-main/src/lib.rs
In web-audio-api-rs-new-main/src/node/panner.rs, the comment indicates code will panic when value < 0.0, while the code will panic when value <= 0.0 .
The text was updated successfully, but these errors were encountered: