Android - VideoView wont play videos with sound - android

I created a VideoPLayer in a Xamarin project using the android specific videoview. The Problem is that all the videos with play sounds on my samsung a70 (Android 9 API 28), but sometimes completely randomly the sound would not be played on my older Android 5 phone and the emulator. By randomly I mean, that the sound sometimes plays, but sometimes does not. Anyone might have an idea ?

You could try using ExoPlayer. It is developed by google and helped me with an Application i created a time ago. It is much more mature and flexible than the standard videoview-implementation.
Here is the Github:
ExoPlayer Github
And I think there is also an implementation for Xamarin:
ExoPlayer Xamarin Github

Related

Android Audio Streaming is too slow

I'm trying to make a radio app. Everything is ok, except playing radios. I'm getting play link from a page with Jsoup. When i press play, (in real device)it takes 40-50 seconds to start playing. But in genymotion device (Google Nexus 4- 4.4.4- API 19) it takes just 3-4 second. I couldn't find what is wrong.
I'm new on Android and I couldn't find a solution for days. Thanks id advance.
I really recommend you to use google exo player instead of default android player for streaming. its too fast and you will never have problems like this.
https://github.com/google/ExoPlayer
You must try it without emulator, as they themselves are slow.
Also give below links a read.
https://developer.android.com/reference/android/media/AudioManager.html
https://developer.android.com/guide/topics/media/mediaplayer.html
For Best performance native is good:
https://developer.android.com/ndk/guides/audio/index.html

ExoPlayer Video not playing for Android version 4.2.1

I have one issue while using android ExoPlayer for streaming url.
Here I have attached sample URL:
http://epicmediaservice.streaming.mediaservices.windows.net/0bd4f655-00f9-4e36-a638-f8e90d9432c9/Nursery%20Rhymes%20Sample%20Clip.ism
It is working in some device, but not not working for Android version 4.2.1 (Micromax canvas 116)
It shows buffering video, but not playing.
If I select video option as OFF then it plays, but only audio comes no pictures visible.
new Sample("Super speed (PlayReady)",
"http://epicmediaservice.streaming.mediaservices.windows.net/0bd4f655-00f9-4e36-a638-f8e90d9432c9/Nursery%20Rhymes%20Sample%20Clip.ism",
DemoUtil.TYPE_SS),
Looks like you are trying to play DRM-protected content (PlayReady) which probably won't work since Exoplayer doesn't support DRM until Android 4.3 and upwards, also check on your device's documentation that it really supports PlayReady.
Check section Digital Rights Management on ExoPlayer's developer guide.

Issues playing HLS on XBMC for Android

Anyone would have a recomendation on how to improve HLS on Android when running XBMC
I read that native HLS on Android is pretty bad but no recomemnded solution on how to improve.
Not even sure XBMC uses the native HLS decoding
Its just impossible to watch a video..
Cache some of the video, plays, stops to cache, plays,....
Would really apreciate.
I use one of the Android Stick. It works great for everything except when videos are HLS..
(Also use XBMC on tablet, phone,..)
You can use Vitamio for Android to run HLS.
I use it and it works perfectly.

Reliability of videoView in Android

I got a problem when using videoView to play progressive streaming mp4 videos. Sometimes, when I scrub through the video, the view does not change accordingly and just hang there. It's strange because the time on the videoView is still running which mean the player is running.
I test this on an Android 2.2 device. Is this problem caused by videoView ?
Thank you.
Since android emulator plays .mp4 and .3gpp format videos and the android's video view is not that much good to play a video without pixcelet or hanging it. But if you try to run the same application on an android phone the video will play fine without picxeleting and without being hang. I too faced the same problem earlier with emulator but when I ran the code on android phone it worked great.

Flash support in Android

I am planning to port a flash player to Android OS. Presently Android is not supporting the Flash. I have looked into GNash, an open source flash player but the problem with this is that it is not supporting the latest version flash files and we can't open the youtube with GNash.
Are there any open source light-weight flash players which can be ported to Android.
EDIT: I have also tried SwfDec but even this one is not playing the videos from youtube.
Any other open source players which can play youtube videos?
Of course this could be a fun project to hack; however, you'll soon face real competition from Adobe, who are porting their own player as we speak:
http://www.google.se/search?q=flash+android
Just in case you can afford to wait.
I have used ffmpeg to convert the flv to mp4.
According to Google/OHA member engineers the problem you will have is performance on current device hardware specifically G1s..
My impression is that you will not see flash until the Dalvik VM JIT is finished developmentally...probably not until SDK 3.5 probably..
GNash website states (and my own experience confirms) that GNash actually plays most youtube videos OK. See GNash wiki.
Now Android has flash support,
maybe this can help:
http://www.synesthesia.it/playing-flash-flv-videos-in-android-applications
playing FLV on Android using flash player inside a webview

Categories

Resources