Android.Media.MediaCodec.Flush Method
Flush both input and output ports of the component, all indices previously returned in calls to MediaCodec.DequeueInputBuffer(long) and MediaCodec.DequeueOutputBuffer(.BufferInfo, System.Int64) become invalid.

Syntax

[Android.Runtime.Register("flush", "()V", "")]
public void Flush ()

Exceptions

TypeReason
Java.Lang.IllegalStateExceptionif not in the Executing state.
!:NoType:android/media/MediaCodec$CodecException;Href=../../../reference/android/media/MediaCodec.CodecException.htmlupon codec error.

Remarks

Flush both input and output ports of the component, all indices previously returned in calls to MediaCodec.DequeueInputBuffer(long) and MediaCodec.DequeueOutputBuffer(.BufferInfo, System.Int64) become invalid.

If codec is configured in asynchronous mode, call MediaCodec.Start after flush has returned to resume codec operations. The codec will not request input buffers until this has happened.

If codec is configured in synchronous mode, codec will resume automatically if an input surface was created. Otherwise, it will resume when MediaCodec.DequeueInputBuffer(long) is called.

[Android Documentation]

Requirements

Namespace: Android.Media
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 16