complete CLI for input & output to a different format (MP3 lame is freaky)

This commit is contained in:
brevalferrari 2025-06-20 10:55:48 +02:00
parent 2cf1ec385f
commit e4dddb4aba
Signed by: breval
GPG key ID: 913954DA013FAD4F
6 changed files with 700 additions and 71 deletions

View file

@ -1,6 +1,6 @@
[package]
name = "bingus"
version = "0.5.1"
version = "0.6.0"
edition.workspace = true
license.workspace = true
description.workspace = true
@ -16,7 +16,6 @@ rayon = { version = "1", optional = true }
infer = "0"
thiserror = "2"
derive-new = "0"
strum = { version = "0.27", features = ["derive"] }
derive_wrapper = "0.1"
symphonia = { version = "0.5", features = ["all"], optional = true }
printpdf = { version = "0.8.2", features = [

View file

@ -1,4 +1,4 @@
use std::borrow::Cow;
use std::{borrow::Cow, convert::Infallible};
use super::sample::Sample;
use cfg_if::cfg_if;
@ -17,6 +17,12 @@ pub struct RawSamples<T>(Vec<T>)
where
T: Sample;
impl<T: Sample> RawSamples<T> {
pub fn into_inner(self) -> Vec<T> {
self.0
}
}
impl<T> IntoDataBytes for RawSamples<T>
where
T: Sample + ToBytes,
@ -34,7 +40,7 @@ where
T: Sample + FromBytes + ToBytes + Zero,
<T as FromBytes>::Bytes: Sized + for<'a> TryFrom<&'a [u8]>,
{
type Error = ();
type Error = Infallible;
type Format = ();
fn try_from_data_bytes(
bytes: crate::Bytes,