Merge pull request #105 from est31/master

Update to lewton 0.5
This commit is contained in:
tomaka 2017-02-27 19:53:41 +01:00 committed by GitHub
commit b805d2bbfc
3 changed files with 2 additions and 6 deletions

View file

@ -14,5 +14,4 @@ cpal = "0.4.0"
futures = "0.1.1"
hound = "1.0.0"
lazy_static = "0.1.12"
lewton = "0.4"
ogg = "0.4"
lewton = "0.5"

View file

@ -5,7 +5,6 @@ use std::vec;
use Source;
use lewton::inside_ogg::OggStreamReader;
use ogg;
/// Decoder for an OGG file that contains Vorbis sound format.
pub struct VorbisDecoder<R>
@ -20,8 +19,7 @@ impl<R> VorbisDecoder<R>
{
/// Attempts to decode the data as ogg/vorbis.
pub fn new(data: R) -> Result<VorbisDecoder<R>, ()> {
let packet_reader = ogg::PacketReader::new(data);
let mut stream_reader = match OggStreamReader::new(packet_reader) {
let mut stream_reader = match OggStreamReader::new(data) {
Err(_) => return Err(()),
Ok(r) => r,
};

View file

@ -86,7 +86,6 @@ extern crate hound;
#[macro_use]
extern crate lazy_static;
extern crate lewton;
extern crate ogg;
pub use cpal::{Endpoint, get_endpoints_list, get_default_endpoint};