Froyo poor performance on playing video: what player/codec to use? can I use mjpeg?

37 views
Skip to first unread message

Zhang Weiwu

unread,
Oct 25, 2011, 11:08:30 AM10/25/11
to android-on-freerunner
Hello. I tried multiple players to play a sample .mp4 file: Following
the recommendation on this project's wiki page, I tried Act 1 video
player, mVideoPlayer. Later from Freeware Lovers I found Arc Media
Player and RealPlayer. They all failed to play: usually show a black
blank screen with sound okay. The sample mp4 file I produced with
ffmpeg myself.

It took me a long while until I figure out this is due to poor
performance, because with similar ffmpeg parameter I can produce .3gp
files at much smaller size: 128x96, and that is playable. I figure
with this performance I can only use mjpeg, the fastest codec that
even Z80 can playback. The difficulty is to find a player that can
actually play mjpeg either contained in AVI or MOV (I guess there are
no other container that can do mjpeg). All previously mentioned player
I tried without luck.

So. Question:

1. Have you ever successfully played video at VGA resolution, a.k.a.
using freerunners full resolution, with more than 10fps? What player
you used and what parameter you used to generate that video?

2. If answers to 1 are no's, then is there a player that can do mjpeg?

Thanks.

ran

unread,
Oct 25, 2011, 1:07:39 PM10/25/11
to android-on-freerunner
Hello
I did some investigation about a your ago and did not find ability to
play
video at VGA resolution, more over than 10fps.
For myself I use one of next examples convertion to get reasonable
media file playing at
freerunner ( you can find it in my previous messages about this
problem).
For playing I use internal media player or ES FileManager player.
#
#Basic Android video player. This application plays video files from
the SD card.
#File should be MPEG4 or 3GPP with H.264 or H.263 and MP3, AAC, or AMR
audio. Videos need to be 480×352 or smaller to play back properly.
#Best 16x9 for old ffmpeg
#ffmpeg -i '/tmp/infile' -s 352x200 -aspect 352:288 -padtop 44 -
padbottom 44 -vcodec h263 -acodec aac -ac 2 -b 339k -r 12.5 -ar 8000 -
ab 12.2k '/tmp/outfile.3gp'
#Best 16x9 for new ffmpeg
# ffmpeg -i '/tmp/infile' -s 352x200 -vf 'pad=0:288:0:44' -vcodec
h263 -acodec aac -ac 2 -b 339k -r 12.5 -ar 8000 -ab 12.2k -strict
experimental '/tmp/outfile.3gp'
#Best 4x3 for old ffmpeg
#ffmpeg -i '/tmp/infile' -s 352x264 -aspect 352:288 -padtop 12 -
padbottom 12 -vcodec h263 -acodec aac -ac 2 -b 339k -r 12.5 -ar 8000 -
ab 12.2k '/tmp/outfile.3gp'
#Best 4x3 for new ffmpeg
#ffmpeg -i '/tmp/infile' -s 352x264 -vf 'pad=0:288:0:12'-vcodec h263 -
acodec aac -ac 2 -b 339k -r 12.5 -ar 8000 -ab 12.2k '/tmp/outfile.3gp'
Alexandre

Zhang Weiwu

unread,
Oct 27, 2011, 12:14:57 AM10/27/11
to android-on-freerunner

On 10月26日, 上午1时07分, ran <r...@mail.wplus.net> wrote:
> I did some investigation about a your ago and did not find ability to
> play video at VGA resolution, more over than 10fps.

But I noticed you only tried 3gp or mp4. Given proper player, their
might be a chance to use mpeg1 codec or mjpeg codec, which takes much
much less CPU power to decode. I just don't know if such player exists
for Android.

> For myself I use one of next examples convertion to get reasonable
> media file playing a freerunner ( you can find it in my previous messages about this
> problem).

Thanks a lot for sharing these commandline options! I really needed
it! Are you sure you must use -b instead of -qscale when the latter
almost always gets better video quality with the same file size?

ran

unread,
Oct 27, 2011, 12:24:48 PM10/27/11
to android-on-freerunner
Hello

> But I noticed you only tried 3gp or mp4. Given proper player, their
> might be a chance to use mpeg1 codec or mjpeg codec, which takes much
> much less CPU power to decode. I just don't know if such player exists
> for Android.

I do not know about such players as well.

> Thanks a lot for sharing these commandline options! I really needed
> it! Are you sure you must use -b instead of -qscale when the latter
> almost always gets better video quality with the same file size?

I have not compare -b vs -qscale. Please, share you result if you
have some.

Alexandre
Reply all
Reply to author
Forward
0 new messages