We are seeing noticeable frame drops using the Media for Mobile Camera Streaming Sample on multiple Android devices. We are streaming to a WOWZA server from various Android devices and receiving the stream on VLC player on PC and native player on Android phones. The frame drops are readily visible on both the preview screen on the capture side (after streaming starts) as well as the playback side, although typically worst on the playback side. The framerate is set to 30fps. The issue is visible at both 640x480 and 320x240. We have tried using a fairly recent LG G4 with a strong processor and good media acceleration, but still see this issue.
I would like to know if this is a known issue or if there are settings/configurations that we can play with to improve encode/streaming performance.
We confirm that performance\fps differs from device to device in capturing/playback scenario. Our assumption is that SW codec is used instead of HW by some reason. Our tests show that this is a device problem, not Media for Mobile or CameraCapturing in particular. Most of devices give normal FPS, but there are several exceptions.
Is there a way to determine if HW acceleration is being used or not using the provided source code/sample app?
Can you please provide a list of Android devices that are certain to have HW acceleration with Media for Mobile?
Do you know if the Media for Mobile code uses media acceleration on LG G4 in particular?
Is there a way to turn on/off HW acceleration in the code or configuration files?
After experiments and discussions on this issue, let me answer your questions one by one, so we do not miss any.
1)Is there a way to determine if HW acceleration is being used or not using the provided source code/sample app? -> In our Media for mobile source code/sample app, we do not control acceleration path. This is completely depended and managed by the device. So we do not have a way to determine the acceleration path taken as it is determined by the device in use.
2) Can you please provide a list of Android devices that are certain to have HW acceleration with Media for Mobile? -> Good question. As, I mentioned above we do not control the acceleration path and the path taken is determined by the device. Sorry, we do not have such list as each device behaviour from Original equipment manufacturer's (OEM's) differs from device to device specifically.
3) Do you know if the Media for Mobile code uses media acceleration on LG G4 in particular? -> In particular, with acceleration path used by the device, no, as this is managed by OEMs device in use.
4) Is there a way to turn on/off HW acceleration in the code or configuration files? -> Again, as we do not control the acceleration path in code or via config files, we do not have a way to control this via code for a device as generally device in use decides and manages the acceleration path.