Share via


AudioTrack.StreamEventCallback.OnDataRequest(AudioTrack, Int32) Method

Definition

Called when more audio data can be written without blocking on an offloaded track.

[Android.Runtime.Register("onDataRequest", "(Landroid/media/AudioTrack;I)V", "GetOnDataRequest_Landroid_media_AudioTrack_IHandler", ApiSince=29)]
public virtual void OnDataRequest (Android.Media.AudioTrack track, int sizeInFrames);
[<Android.Runtime.Register("onDataRequest", "(Landroid/media/AudioTrack;I)V", "GetOnDataRequest_Landroid_media_AudioTrack_IHandler", ApiSince=29)>]
abstract member OnDataRequest : Android.Media.AudioTrack * int -> unit
override this.OnDataRequest : Android.Media.AudioTrack * int -> unit

Parameters

track
AudioTrack

the AudioTrack on which the event happened.

sizeInFrames
Int32

the number of frames available to write without blocking. Note that the frame size of a compressed stream is 1 byte.

Attributes

Remarks

Called when more audio data can be written without blocking on an offloaded track.

Java documentation for android.media.AudioTrack.StreamEventCallback.onDataRequest(android.media.AudioTrack, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to