public interface AudioEncoder
| Modifier and Type | Method and Description |
|---|---|
AudioClip |
encode(AudioInputStream pcm,
AudioFileFormat.Type outputFileType,
File outputFile)
Encode raw audio data into a single file (mp3 for instance).
|
AudioClip encode(AudioInputStream pcm, AudioFileFormat.Type outputFileType, File outputFile) throws Throwable
pcm - is the raw input audio.outputFileType - the file format the encoder should write inoutputFile - is the output audio file
return AudioClip object to convey a possible offset in the resulting file. Guaranteed
to point to the specified output file and to have the length of the provided audio
stream (apart from any rounding errors due to sampling), but may start at a position
greater than 0.IllegalArgumentException - if this decoder does not support outputFileTypeThrowable - when some other error happensCopyright © 2010–2025 The DAISY Consortium. All rights reserved.