public final class WaveUtils extends Object
TextToSpeech service.| Modifier and Type | Method and Description |
|---|---|
static InputStream |
reWriteWaveHeader(InputStream is)
Re-writes the data size in the header(bytes 4-8) of the WAVE(.wav) input stream.
It needs to be read in order to calculate the size. |
static byte[] |
toByteArray(InputStream is)
Converts an
InputStream to byte array. |
public static InputStream reWriteWaveHeader(InputStream is) throws IOException
is - the input streamIOException - Signals that an I/O exception has occurred.public static byte[] toByteArray(InputStream is) throws IOException
InputStream to byte array.is - the input streamIOException - If the first byte cannot be read for any reason other than end of file, or
if the input stream has been closed, or if some other I/O error occurs.Copyright © 2022 IBM Cloud. All rights reserved.