Questions tagged [android-music-player]

598 questions
6
votes
1 answer

MediaMetadata.getString java.lang.RuntimeException: Could not read bitmap from parcel blob

Call MediaMetadata.getString, have below crash in report, but not always repro: java.lang.RuntimeException: Could not read bitmap from parcel blob. at android.graphics.Bitmap.nativeCreateFromParcel(Native Method) at…
Sarah Ma
  • 121
  • 1
  • 5
6
votes
1 answer

How To Add Media To MediaStore on Android 4.4 KitKat SD Card With Metadata

Background: In Android 4.4, Google decided that apps should not have write access to SD cards. However, apps can write to /SDCard/Android/data/App Package Name. So this is what I've done. I have written an MP3 file to /Android/data/. I then want…
6
votes
1 answer

Notification for android music player

How to control a music player from buttons in notification, and how to listen button action from the notification
6
votes
1 answer

Update MusicPlayer SeekBar in Service

I'm trying to update music player SeekBar in service, but nothing happens. The service start ok in my activity and bind correctly (because I can use some of the methods in my service and music play fine). Here is my service code: public class…
5
votes
3 answers

How to update metadata of audio file in Android Q media store?

Updating metadata of audio file in media store is not working in Android Q OS, it works in all other OS. I am using content provider with uri specified as MediaStore.Audio.Media.EXTERNAL_CONTENT_URI. It is working fine in all below Android Q device.…
5
votes
2 answers

Android MediaPlayer is preparing too long

Hey, I'm using MediaPlayer to play a regular ShoutCast stream. The code is straightforward with prepareAsync() and a handler to start the playback. While it works flawlessly with some streams like DI.FM or ETN.FM…
Sergei
  • 63
  • 1
  • 4
5
votes
1 answer

Unity app stops background music

My android app made with unity 5.3.4p1 pausing background music. I start play music with some player on my android device, but when I launch my app, after splash screen that music stops, and only music from the game starts and continue playing. This…
5
votes
7 answers

How to debug Android native code on a real device

I've got some trouble with the media backend (mostly Stagefrightplayer) in Android, and I'd like to understand why it throws the errors it does. The errors are usually device spesific, so debugging on an emulator wouldn't be…
neu242
  • 14,861
  • 13
  • 69
  • 107
5
votes
1 answer

Android music player in UI thread or background

I am trying to create simple Android application to play audio files from sd card. I have some problems with understanding Services. I will be concrete, here are my questions. Service by default runs on UI thread, isn't it ? Only if it runs in…
5
votes
0 answers

How to I achieve ViewPager (next/previous) in Music player App

I want to know how I can achieve next and previous using swipe via a view pager. The final result I want is the one that Google Play Music has. I have uploaded a picture of what my app is behaving like and also what I expect. I basically cannot get…
KudzieChase
  • 251
  • 2
  • 14
5
votes
1 answer

How to check if music is being played from which music app?

How do i check from which music app the music is getting played in android device? Using AudioManager, we can check if the music is being played or no. But it doesn provide the details of the music app from which it is being played. AudioManager am…
user1554336
5
votes
2 answers

control play pause button in fragment from musicplayer service

i create a musicplayer service class in android and have a play pause button in a fragment. I am running a radio stream in musicplayer service. The service is running on background. When the app is open service can control by play pause button. but…
Kishor datta gupta
  • 1,083
  • 2
  • 13
  • 41
5
votes
3 answers

Music service killed even when startForground

is it possible to prevent Service(startForground) from being killed by os? I use it to play audio but it's killed when I use another app which requires more resources(Angry birds go) for a while. In logs I see app process being killed by…
Martin Vandzura
  • 2,979
  • 1
  • 27
  • 56
4
votes
1 answer

MediaPlayer plays the music files only in debug mode ( Android )

I have written an Android application ( in eclipse) that plays a music file as follows: MediaPlayer mediaPlayer = new MediaPlayer(); try { mediaPlayer.setDataSource(fileName); mediaPlayer.prepare(); …
Farid Ala
  • 668
  • 1
  • 11
  • 29
4
votes
1 answer

How to set preset eq in android?

I want to develop a preset equalizer(not graphical) and set like a classical,jazz,normal,rock(these are represented in spinner). Can anbody help me regarding this.
Ramesh Akula
  • 5,542
  • 4
  • 38
  • 65
1 2
3
39 40