how to show audio equalizer in my android music app? - android

I am working on my first android app which is a music app and I need to provide equalizer for my app on menu options .. just tell how to use android equalizer class in my app ?

To create visualizer :
1. Use canvas
2. Draw rectangular shape according to your sound
3. Change color of your shapes.
You can also use below tutorials:
https://github.com/felixpalmer/android-visualizer
It will help.
And if you want a demo of music player then you can follow below tutorial:
https://github.com/psaravan/JamsMusicPlayer
https://github.com/punker76/simple-music-player
https://github.com/carlosrafaelgn/FPlayAndroid

Related

Is it possible to get the VLC player layout, complete with media player buttons and a seekbar etc..?

How to properly use the VLC video player. I want the video to play with a pause/resume button, Seekbar, and some default features displayed on the player. There is no official documentation. Could you please assist me in locating the correct one?
LibVLC for Android is not like ExoPlayer. It does not come with a companion UI class or anything like that. Therefore, you have to build your very own UI for it.
A very good starting point would be to use ExoPlayer's very own UI and customize it to your need. Then you need to do your own bindings and listeners for the buttons.
LibVLC will be responsible for playing the video and anything related to the task, but it does not have anything that delegates user interaction with it. You have to do it manually.
If you face issues controlling and putting LibVLC to use, then you need to thoroughly inspect the code of VLC for Android. They made everything open-source so that's already a great thing. Check VLC Android - Repository

Properly set Repeat/Shuffle option in MediaControllerCompat.TransportControls

I'm working on a simple audio streaming app based on the Media app architecture from official Android documentation:
By using the MediaControllerCompat I'm trying to achieve the Repeat/Shuffle controls. But most of the options aren't working. E.g:
The following code enables shuffling:
getTransportControls().setShuffleMode(PlaybackStateCompat.SHUFFLE_MODE_ALL);
But if I set the mode to none the player is still shuffling and has no effect for cancelation.
getTransportControls().setShuffleMode(PlaybackStateCompat.SHUFFLE_MODE_NONE);
Also the single/all repeat option isn't working
getTransportControls().setRepeatMode(PlaybackStateCompat.REPEAT_MODE_ONE);
getTransportControls().setRepeatMode(PlaybackStateCompat.REPEAT_MODE_ALL);
Am I missing anything?

floating video player (like youtube player ) in android

In my app i need to implement floating video player ( like youtube player). i gone through the below urls but not able to solve my issue. I don't know where to start and what to use .
Please someone help me
how to create a Floating popup video player in android?
how to create a Floating popup video player in android?
What APIs in Android is Facebook using to create Chat Heads?
Yes, you can achieve this by using service with Window manager, there is an excellent sample application available on github
https://github.com/marshallino16/FloatingView, this will guide you to achieve your requirements which are listed above
To make floating player you need to work on widgets. it is known as picture in picture mode. step is as below
1) add dependency for support media
2) create player layout
3) add player click event (touch & onclick listener)
4) add broadcast receiver to detect event on player view.
5) Start player from activity.
You can find link on github for picture in picture mode android example OR you can get reference here

Android press to record video

I would like to create a video recorder for my Android application. For an easier usage, I'd like to create a Vine like Touch to record.
I don't know where to start, but I've already taken a look at JavaCV which looks to be recomended to handle a custom video component.
I've taken a look at this Github project: https://github.com/sourab-sharma/TouchToRecord but it doesn't work properly.
Is there a way to do that with Android and if yes, how could I achieve that ?

Is there a way to make a custom VideoView progress bar without building a MediaPlayer from scratch?

I am currently making an Android app and I'm going to need to make a custom video player. I just need to change its ProgressBar color. Is there a simple way to do that?
I know I could do that using Commonsguy example. But it's not so good as the native video player and I think it would be making a lot for only a change of color.
Any help appreciated!
I ended up building a media player from scratch based on Commonsguy example. I've tried to use Android source code for a few classes. MediaController looks exactly like what I needed to customize but it uses to many internal resources that we don't have access to.
The native video player will be intrinxically linked to the system theme so changing the color is not possible.
You could try extendingthe native player and using it as a custom activity in your project, you might then be able to change the theme via your manifest.xml or in code.

Categories

Resources