HD Video Playback issue with android things - android

Has anyone been able to successfully play a HD video using Android Things on a Raspberry Pi? If so was there anything special you had to do to get it to work? If not does any one know why it isn't working?
I made a simple video player that plays a local video from disk. The app runs fine on a phone but with android things maximum frames are getting dropped.
I am using ExoPlayer for the video playback and the same issue is observed when Media Player is used.Hardware acceleration is also enabled in the manifest file.

Related

Android webview microphone capture issue

I am trying to record audio using an app that runs WebView. For example, I load the app in the URL https://online-voice-recorder.com/ and records some audio over the mic. I have given enough permissions and able to record and replay the audio. On Windows 10, it works perfectly. But on my Android Oreo 8.1.0 running Chrom version 80, this audio is fully distorted. I tested it another device and the audio is partially legible.
Is this a standard behavior?
What I have tried to see what is the problem: I wrote a backend netcore3.1 app to play the audio and it plays the same distorted sound.
I have also tried using default sampling rates and custom and in either case, the audio remains distorted.

Android Media Player Streaming issue on Samsung Devices

I'm streaming the audio file (.mp3) from internet with Android Media Player.
It works quite well except Samsung Devices. As far as I see, it doesn't stream the audio but tries to download. It sometimes pushes Media Player Error (1 -1004). Nothing is getting played.
I also tried to redirect the Application to the Media Player with URL of audio file, it goes to Music Player application, indicating "Preparing..." for a while, but then It shows the message "sorry, player does not support this type of audio" with Toast.
Anybody else had the same error before ? Any advise to find a solution ?
Thanks.
There are some bugs in native sound libraries on Samsung Galaxy S2 for instance (look here). I had those problems (random crashes / freezes) and solved it by using OpenSL library for that specific case.

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.

Android Video Streaming - Device supported?

Ok. So there are a bagillion different Android devices. I have a video streaming service, works wonderfully for iOS. My app has a live video feature and a saved video clip playback feature (which streams to the device too). I've run some tests on different Android devices and get a whole bunch of different playback results. I am using a 640x480 h.264 base profile video. Streaming that video works only on some devices. For other devices, that same video stream can be made to stream at low resolution and that works on some devices, but still not others. The high profile streaming goes through http://www.wowzamedia.com/ (rtsp) and doesn't work on any Android device (but works on iPhone). The lowest and worst option is Motion JPEG, which works on all tested devices so far.
So my question is, how can I figure out (without having to test every device out on the market) if the device will play: 640x480 h.264 base profile - if that wont work then play the low resolution video - if that doesn't work, default to Motion JPEG.
Also, any idea why my rtsp transcoded through wowza works on the iPhone but not on any Android device (not even the Motorola Atrix)?
Streaming on android is an absolute mess. Most devices don't support anything higher than Baseline 3.0. If you encode for iPhone 3, it should generally work via RTSP. Newer versions of android support HLS, but it's hit or miss and largely dependent on specific devices.
I resolved this problem. Check RTP-realization in your streaming service and x264 profile. My RTSP-server works fine on 90% devices.
p.s
Some video frameworks in different Android versions can implement RTP and RTSP protocols with some differences.
These are some of the links/issues which I have come across, while trying to make streaming work in varied devices.
MediaPlayer seekTo doesn't work for streams
MediaPlayer resets position to 0 when started after seek to a different position
MediaPlayer seekTo inconsistently plays songs from beginning
Basic streaming audio works in 2.1 but not in 2.2
MediaPlayer.seekTo() does not work for unbuffered position
Streaming video when seek back buffering start again in videoView/Mediaplayer
Even the big shots in stackoverflow are wondering about this
If you want just streaming without seeking (which is lame), this can be achieved. But then if you receive a call while you are watching, you will end up from the start.

Android VideoView picture doesn't update wile playing

I've coded up apps using VideoView and MediaPlayer and both had the same behavior. I'm currently using the code example here. The problem I'm having is that the video doesn't play back continuously. The slider in the MediaController is moving but the picture doesn't change. If I manually drag the slider the picture will change like it should.
I'm using an mp4 file loaded from the sdcard with a SDK 2.3.1 emulator device.
Any help is appreciated.
You usually cannot test video playback applications on the Android emulator, as it is too slow, except on very powerful host PCs. Please test video playback applications on an Android device.

Categories

Resources