Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7686523
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T19:30:01+00:00 2026-05-31T19:30:01+00:00

I am streaming live audio and wish to have the functionality to pause the

  • 0

I am streaming live audio and wish to have the functionality to pause the mediaplayer and then start from the current live position. The default Pause() and Start() just starts from where it was stopped. Any ideas on how to keep the current position updated so that Start() is instant?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T19:30:02+00:00Added an answer on May 31, 2026 at 7:30 pm

    Did you try calling seekTo()?

    You could keep it pemanently updated by calling seekTo() every half a second or so with TimerTask, But i don’t know how i feel about this.

    EDIT: If you call seekTo() every 500 milliseconds, in order to keep it moving forward you would call it with the currentPosition + time ellapsed since last call(500 milliseconds in this case). But again I don’t know if this is the best aproach. Another way is to create a OnSeekCompleteListener that preforms a new seekTo(currentPosition + timeEllapsed). In this case you need to calculate timeEllapsed like so: currentSystemTime – systemTimeOnLastCall

    From http://developer.android.com/reference/android/media/MediaPlayer.html:

    The playback position can be adjusted with a call to seekTo(int).

    Although the asynchronuous seekTo(int) call returns right way, the actual seek operation may take a while to finish, especially for audio/video being streamed. When the actual seek operation completes, the internal player engine calls a user supplied
    OnSeekComplete.onSeekComplete() if an OnSeekCompleteListener has been registered beforehand via setOnSeekCompleteListener(OnSeekCompleteListener).

    Please note that seekTo(int) can also be called in the other states, such as Prepared, Paused and PlaybackCompleted state.

    Furthermore, the actual current playback position can be retrieved with a call to getCurrentPosition(), which is helpful for applications such as a Music player that need to keep track of the playback progress.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Where to get streaming (live) video and audio from camera example for Nokia (5800
I have a HTTP Live streaming server setup that serves segmented mp3 audio content
Where to get live video + audio streaming examples ( GStreamer )? So for
Live streaming video in html 5 - what is required from server to stream
I would like to set up a live streaming video demonstration. I have a
hope you can help. I am recording audio from a microphone and streaming it
What technology is used for live streaming of video from iPhone cam to a
I'm trying to do http live streaming from VLC to an android app using
If streaming video to an iOS device, do I have to use HTTP Live
I wonder if you could share your thoughts / resources about live audio streaming

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.