|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbe.hogent.tarsos.util.AudioTranscoder
public final class AudioTranscoder
Transcodes audio. Uses ffmpeg: a vast number of formats are supported. A compiled ffmpeg binary is provided for Windows and Linux (32bit). If support on another platform is required check the documentation of JAVE or disable transcoding (trough configuration) and perform it manually .
Field Summary | |
---|---|
static be.hogent.tarsos.transcoder.DefaultAttributes |
TARGET_ENCODING
Defines the target codec: signed 16 bit little endian pcm. |
Method Summary | |
---|---|
static void |
transcode(java.lang.String source,
java.lang.String target)
Transcode the source file to target using the requested number of channels and sampling rate. |
static void |
transcode(java.lang.String source,
java.lang.String target,
be.hogent.tarsos.transcoder.Attributes attributes)
Transcode the source file to target using the requested number of channels and sampling rate. |
static boolean |
transcodingRequired(java.lang.String transcodedPath)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final be.hogent.tarsos.transcoder.DefaultAttributes TARGET_ENCODING
Method Detail |
---|
public static void transcode(java.lang.String source, java.lang.String target) throws be.hogent.tarsos.transcoder.ffmpeg.EncoderException
source
- The path of the source file.target
- The path of the target file. A stereo stream can be down mixed
to a mono stream. Converting a mono stream to a stereo stream
results in a file with two channels with the same data.
be.hogent.tarsos.transcoder.ffmpeg.EncoderException
- If FFMPEG fails to transcode the audio an
UnsupportedAudioFileException is generated.
java.lang.IllegalArgumentException
- if the source file can not be read or the target file is not
writable.public static void transcode(java.lang.String source, java.lang.String target, be.hogent.tarsos.transcoder.Attributes attributes) throws be.hogent.tarsos.transcoder.ffmpeg.EncoderException
source
- The path of the source file.target
- The path of the target file.attributes
- Defines the attributes of the audio e.g. The sampling rate the
target file should have; The number of channels target should
have. A stereo stream can be down mixed to a mono stream.
be.hogent.tarsos.transcoder.ffmpeg.EncoderException
- When the transcoder yields an error.public static boolean transcodingRequired(java.lang.String transcodedPath)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |