| Index: media/mojo/interfaces/video_decoder.mojom
|
| diff --git a/media/mojo/interfaces/video_decoder.mojom b/media/mojo/interfaces/video_decoder.mojom
|
| index f0f4ae32b5454c2354725d6554552f3faee51364..b0bcf94b4d6718fd16faa56af3ff2b6f03848ab5 100644
|
| --- a/media/mojo/interfaces/video_decoder.mojom
|
| +++ b/media/mojo/interfaces/video_decoder.mojom
|
| @@ -23,24 +23,29 @@ interface VideoDecoder {
|
| //
|
| // If |low_delay| is true, the decoder must output frames as soon as possible;
|
| // in particular, it must not wait for another Decode() request, except as
|
| - // required for frame reordering.
|
| - Initialize(VideoDecoderConfig config, bool low_delay) => (bool success);
|
| + // required for frame reordering. Implementations must fail initialization if
|
| + // they cannot satisfy this requirement.
|
| + //
|
| + // On completion, the callback also includes |needs_bitstream_conversion|,
|
| + // indicating whether decode buffers need bitstream conversion, and
|
| + // |max_decode_requests|, the maximum number of concurrent Decode() requests
|
| + // the implementation supports.
|
| + Initialize(VideoDecoderConfig config, bool low_delay) =>
|
| + (bool success, bool needs_bitstream_conversion,
|
| + int32 max_decode_requests);
|
|
|
| // Request decoding of exactly one frame or an EOS buffer. This must not be
|
| - // called while there are pending Configure(), Reset(), or Decode() requests.
|
| + // called while there are pending Initialize(), Reset(), or Decode(EOS)
|
| + // requests.
|
| //
|
| // Implementations must eventually execute the callback, even if Decode() is
|
| // not called again. It is not required that the decode status match the
|
| - // actual result of decoding a frame; only that decode errors are eventually
|
| - // reported (such as at EOS). The purpose of the callback is primarily for
|
| - // Decode() rate control.
|
| - //
|
| - // If |buffer| is an EOS buffer, implementations execute all other pending
|
| - // Decode() callbacks and output all pending frames before executing the EOS
|
| - // buffer Decode() callback. (That is, they must flush.)
|
| + // actual result of decoding the buffer, only that decode errors are
|
| + // eventually reported (such as at EOS).
|
| //
|
| - // TODO(sandersd): Plumb GetMaxDecodeRequests() so that parallel Decode()
|
| - // requests can be allowed.
|
| + // If |buffer| is an EOS buffer, implementations must execute all other
|
| + // pending Decode() callbacks and output all pending frames before executing
|
| + // the Decode(EOS) callback. (That is, they must flush.)
|
| Decode(DecoderBuffer buffer) => (DecodeStatus status);
|
|
|
| // Reset the decoder. All ongoing Decode() requests must be completed or
|
|
|