public interface Codec
Codec
processes a Buffer
and stores the result in another
Buffer
.Modifier and Type | Field and Description |
---|---|
static int |
CODEC_FAILED
The codec could not handle the input.
|
static int |
CODEC_INPUT_NOT_CONSUMED
The codec did not fully consume the input buffer.
|
static int |
CODEC_OK
The codec successfully converted the input to output.
|
static int |
CODEC_OUTPUT_NOT_FILLED
The codec did not fully fill the output buffer.
|
Modifier and Type | Method and Description |
---|---|
Format |
getInputFormat() |
Format[] |
getInputFormats()
Lists all of the input formats that this codec accepts.
|
java.lang.String |
getName()
Returns a human readable name of the codec.
|
Format |
getOutputFormat() |
Format[] |
getOutputFormats(Format input)
Lists all of the output formats that this codec can generate
with the provided input format.
|
int |
process(Buffer in,
Buffer out)
Performs the media processing defined by this codec.
|
void |
reset()
Resets the state of the codec.
|
Format |
setInputFormat(Format input)
Sets the input format.
|
Format |
setOutputFormat(Format output)
Sets the output format.
|
static final int CODEC_OK
static final int CODEC_FAILED
static final int CODEC_INPUT_NOT_CONSUMED
static final int CODEC_OUTPUT_NOT_FILLED
Format[] getInputFormats()
Format[] getOutputFormats(Format input)
Format setInputFormat(Format input)
Format getInputFormat()
Format setOutputFormat(Format output)
Format getOutputFormat()
int process(Buffer in, Buffer out)
Copies the data from the input buffer into the output buffer.
java.lang.String getName()
void reset()