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

Not a supported format error for 32f wav #3

Closed
ismay opened this issue May 1, 2018 · 2 comments
Closed

Not a supported format error for 32f wav #3

ismay opened this issue May 1, 2018 · 2 comments

Comments

@ismay
Copy link

ismay commented May 1, 2018

With the latest version I'm getting a Not a supported format. error when attempting to read a 32f, mono wav.

Build log here
Code that's failing here
Code for failing test here

I didn't see any tests for reading 32f wavs, is this currently supposed to be functional?

@ismay
Copy link
Author

ismay commented May 1, 2018

The wav file was generated with wavefile 5 with this script:

const fs = require('fs');
const path = require('path');
const { fromImage, toWav } = require('./lib');

const imagePath = path.join(__dirname, 'test', 'fixtures', 'image-to-float', 'input.png');
const imageBuffer = fs.readFileSync(imagePath);

fromImage(imageBuffer).then(floats => toWav(floats)).then(wavBuffer => {
  fs.writeFileSync(path.join(__dirname, 'input.wav'), wavBuffer)
});

@ismay
Copy link
Author

ismay commented May 1, 2018

My mistake, I forgot to call toBuffer(). Sorry!

@ismay ismay closed this as completed May 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant