Stay organized with collections
Save and categorize content based on your preferences.
AudioTrack.OnPlaybackPositionUpdateListener
public
static
interface
AudioTrack.OnPlaybackPositionUpdateListener
android.media.AudioTrack.OnPlaybackPositionUpdateListener
|
Interface definition for a callback to be invoked when the playback head position of
an AudioTrack has reached a notification marker or has increased by a certain period.
Summary
Public methods |
abstract
void
|
onMarkerReached(AudioTrack track)
Called on the listener to notify it that the previously set marker has been reached
by the playback head.
|
abstract
void
|
onPeriodicNotification(AudioTrack track)
Called on the listener to periodically notify it that the playback head has reached
a multiple of the notification period.
|
Public methods
public abstract void onMarkerReached (AudioTrack track)
Called on the listener to notify it that the previously set marker has been reached
by the playback head.
Parameters |
track |
AudioTrack |
public abstract void onPeriodicNotification (AudioTrack track)
Called on the listener to periodically notify it that the playback head has reached
a multiple of the notification period.
Parameters |
track |
AudioTrack |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# AudioTrack.OnPlaybackPositionUpdateListener\n\nAdded in [API level 3](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\nAudioTrack.OnPlaybackPositionUpdateListener\n===========================================\n\n*** ** * ** ***\n\n[Kotlin](/reference/kotlin/android/media/AudioTrack.OnPlaybackPositionUpdateListener \"View this page in Kotlin\") \\|Java\n\n\n`\npublic\nstatic\n\n\ninterface\nAudioTrack.OnPlaybackPositionUpdateListener\n`\n\n\n`\n\n\n`\n\n|-----------------------------------------------------------|\n| android.media.AudioTrack.OnPlaybackPositionUpdateListener |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\nInterface definition for a callback to be invoked when the playback head position of\nan AudioTrack has reached a notification marker or has increased by a certain period.\n\nSummary\n-------\n\n| ### Public methods ||\n|------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` abstract void` | ` `[onMarkerReached](/reference/android/media/AudioTrack.OnPlaybackPositionUpdateListener#onMarkerReached(android.media.AudioTrack))`(`[AudioTrack](/reference/android/media/AudioTrack)` track) ` Called on the listener to notify it that the previously set marker has been reached by the playback head. |\n| ` abstract void` | ` `[onPeriodicNotification](/reference/android/media/AudioTrack.OnPlaybackPositionUpdateListener#onPeriodicNotification(android.media.AudioTrack))`(`[AudioTrack](/reference/android/media/AudioTrack)` track) ` Called on the listener to periodically notify it that the playback head has reached a multiple of the notification period. |\n\nPublic methods\n--------------\n\n### onMarkerReached\n\nAdded in [API level 3](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract void onMarkerReached (AudioTrack track)\n```\n\nCalled on the listener to notify it that the previously set marker has been reached\nby the playback head.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|---------|---------------------|\n| `track` | `AudioTrack` \u003cbr /\u003e |\n\n### onPeriodicNotification\n\nAdded in [API level 3](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract void onPeriodicNotification (AudioTrack track)\n```\n\nCalled on the listener to periodically notify it that the playback head has reached\na multiple of the notification period.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|---------|---------------------|\n| `track` | `AudioTrack` \u003cbr /\u003e |"]]