Questions tagged [android-music-player]
623 questions
7
votes
1 answer
How to create a new Playlist using ContentResolver
I'm attempting to create a new Playlist, using Android's ContentResolver, that will be added to music player's playlists, but when the code runs, the insert into the playlist returns null (for the Uri) and when I check the music player's playlists,…

stuckless
- 6,515
- 2
- 19
- 27
6
votes
2 answers
Where to store sound files in the project and what solution to chose for storing references to them?
I'm making some fancy app which requires lot of short sounds for its use. Got few questions You might be able to answer.
Is there some restriction to the place I store then in the android project? Currently I put those in bin/res/sounds folder.
Is…

Jacek Kwiecień
- 12,397
- 20
- 85
- 157
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
- 141
- 1
- 6
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…

Justin
- 3,322
- 2
- 22
- 37
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

Babin
- 70
- 1
- 1
- 9
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…

Sasan
- 65
- 1
- 7
5
votes
1 answer
Define my app as Google Assistant's default music service
I am developping an Android Music Player application. I'd like to integrate it with Google Assistant to control playback and search songs by voice.
I already implemented a Media Session in my app according to instructions from the official…

Thibault Seisel
- 1,197
- 11
- 23
5
votes
2 answers
How to find a replacement for deprecated method?
I am new to Android programming.
I have been following a tutorial on creating a Music Player from this website
The tutorial calls for a setAudioStreamType method from MediaPlayer Class which is deprecated. Which method replaces this deprecated…

noviceUser
- 115
- 1
- 1
- 8
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…

Максим Бойко
- 51
- 1
- 4
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
- 15,796
- 20
- 79
- 114
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…
user4881271
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
- 261
- 3
- 16
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,103
- 2
- 14
- 42