|
From: | Michael Goffioul |
Subject: | Re: Audio playback and classes |
Date: | Fri, 28 Jun 2013 08:16:14 -0400 |
I am a bit confused how to handle variable bit depth audio data. Audio
files come in different variates, like 8 bit, 16 bit, 24 bit, etc.
These bit depths give different value ranges. From what I understand
from matlab documentation it takes in to account the type of values
the array to be played back contains (e.g. int8, int16, uint16, etc).
But in octave I cannot get that type or at least I don't know how (the
numeric arrays are all treated as if they were arrays of doubles
right?) I need this information for correct playback. There are two
options for dealing with this I can think of:
a) Guess the type of array by seeing what values the array elements take.
b) Limit the values to real values in the range (-1.0, 1.0) and make
the user take care of conversion to that format themselves.
Are there any suggestions about this?
[Prev in Thread] | Current Thread | [Next in Thread] |