diff --git a/src/software/resampling/extensions.rs b/src/software/resampling/extensions.rs index dee5d92..4feaeb5 100644 --- a/src/software/resampling/extensions.rs +++ b/src/software/resampling/extensions.rs @@ -1,7 +1,14 @@ use util::format; -use ::{decoder, Error, ChannelLayout}; +use ::{decoder, Error, ChannelLayout, frame}; use super::Context; +impl frame::Audio { + pub fn resampler(&self, format: format::Sample, channel_layout: ChannelLayout, rate: u32) -> Result { + Context::get(self.format(), self.channel_layout(), self.rate(), + format, channel_layout, rate) + } +} + impl decoder::Audio { pub fn resampler(&self, format: format::Sample, channel_layout: ChannelLayout, rate: u32) -> Result { Context::get(self.format(), self.channel_layout(), self.rate(),