Help - Search - Members - Calendar
Full Version: Mplayer Speed Question
OESF Portables Forum > General Forums > General Discussion
hjwind
I've been throwing some different size videos at mplayer (from the oz feed) on my 5500, and it seems to play everything slow unless it's exactly 320x240. It is scaling or doing something weird, that slows it down so much? I would not mind loosing some of the extra pixels if it would run well. I've tried a bunch of mplayer options/filters (scale, crop, etc.) and can't get the videos playing well.

Any thoughts? Am I misinterpreting what i'm seeing, or is there a way to speed up video slightly larger than the screen res?

thanks
adf
scaling is just too much work for the processor. Your best bet would be to re-encode the stuff to 320x240.

I have had some luck with borderless 320xXXX widescreen video,but even there I think most people prefer to encode with black borders to get an exact 32x240. Are you using a full mplayer, or mplayer embedded (not ssure what the diff is)? using mplayer from the prompt with a plain output to framebuffer is your best bet.

the xmms front end and scaling and rotating on the fly are really nice, but seem to invite less efficient use.
there is alot of stuff around here on mplayer and mplayer config files. search around and poke at it till it works
adf
adf
QUOTE(adf @ Jan 23 2005, 07:54 AM)
scaling is just too much work for the processor. Your best bet would be to re-encode the stuff to 320x240.

I have had some luck with borderless 320xXXX widescreen video,but even there I think most people prefer to encode with black borders to get an exact 32x240.  Are you using a full mplayer, or mplayer-embedded-for-xmms-embedded (not ssure what the diff is)? using mplayer from the prompt with a plain output to framebuffer is your best bet.

the xmms front end and scaling and rotating on the fly are really nice, but seem to invite less efficient use.
there is alot of stuff around here on mplayer and mplayer config files.  search around and poke at it till it works
adf
*
hjwind
thanks for your thoughts.

i was just messing with it some more. and discovered that if i turn off the audio (-nosound) the movies i was testing play well. i was looking for a video problem, heh. they appear to be mpeg2. sorta weird. i would not expect mplayer to have trouble with the audio.
kahm
QUOTE(hjwind @ Jan 24 2005, 03:45 PM)
thanks for your thoughts.

i was just messing with it some more. and discovered that if i turn off the audio (-nosound) the movies i was testing play well.  i was looking for a video problem, heh.  they appear to be mpeg2. sorta weird. i would not expect mplayer to have trouble with the audio.
*


In my encoding experience making sure the audio is encoded at 48khz vastly improves performance. I think the internal chip on the Z runs at that encoding rate, and anything else has to be internally re-sampled.

I encoded the same video with 48khz 192 kb/s sound and it played perfectly. The same video with a 22khz audio stream stuttered like mad.

Right now I do my encoding at 320x240, 600kbps DIVX5 video at 24fps and 128kb/s 48khz MP3 audio. I haven't extensively profiled all the options, so I haven't hit optimal settings yet, though.
adf
some stuff that seems to help--
encode at 24kbs audio (from dvd)--1/2 48k works nicely.

set your audio output -ao to something that uses integer rather than floating point--the floating point is what kill you on audio decoding.
on mplayer.config some people have had success popping in ac=mad
or you could try -ao or (ac= in the config) oss

I do that and have ffmpeg integer decoding. it is decent at least.

There has been much success using ogg audio as well. cmisip has a nice script for re-encoding vidio top zaurus sized video w/ ogg audio. You might occasionally have to tweak it, but it wil help you along a great deal, I think.

good luck
-adf
h4rdc0d3
mad.gif

I wish it wasn't so because command-line video-editing and encoding rocks... but I haven't had much success using mencoder, ogmmerge and the like... all my ogm movies do not advance correctly in mplayer and oftentimes trying to advance will stall/crash my Z, so I'm stuck using gui-based tools on windows...

unsure.gif

I have had much success using video files (MPEG-1's) created using the smart ripper, dvd2avi, and tmpgenc tools.

Now, I have a significantly-sized library of converted dvd's and tv shows, down-encoded for exclusive use by my zaurus. I have found it particularly useful for traveling (without a laptop) to burn a bunch to a dvd-r and carry that along with a card reader and borrow somebody's computer or laptop to swap movies or shows for the flight home.

biggrin.gif

Essentially, I take any video file (or seperate AVI and WAV files, as produced by dvd2avi) and run it through tmpgenc with settings:

Resolution: 320x240
Frames per Second: 24 fps
Constant Bit Rate (CBR) (for video): 200 kbps
Layer-2 Audio
Audio Sample Rate: 44100 Hz
Audio Bit Rate: 96 kbps

At least for me, these settings are producing entire movies from dvd with total space used around 200-300 MB... good enough for around 1 movie per 256 MB card and 1-2 movies per 512 card, or about 90 MB per hour of tv (minus the commercials, which leaves about 40-45 minutes). And the quality, of course, isn't perfect, but I would call it very acceptable and not detracting (as was the case with the ogm's IMO).

Also, I would highly suggest running mplayer outside of qtopia!!! I don't know how you'd do that on a 5500, but on a 5600... you would reboot, then wait for when it counts down from 5, hit /, and then a, and then you'll be have a shell outside qtopia and nearly all cpu cycles can be devoted to mplayer. Remember to use -vo fbdev option for mplayer, instead of -vo sdl as you would inside qtopia.

Also, I have noticed that the -playlist option in mplayer is broke... anyone else confirm that? No biggy, I just wrote a script called mplaylist.pl that reads a .m3u playlist, runs mplayer, transfers command line options to mplayer and suppresses mplayer output between playlist items (the cursor just blinks a little bit).

mplaylist.pl:
Note: Another fix: more error correction. This one is current as of Sat Jan 29 14:44 UTC.
Click to view attachment
h4rdc0d3
It just took me some trial and error to arrive at the settings in my post above... but if you're trying to mimick my procedure with tmpgenc, having this file will help...

Here's the .mcf file (MPEG setting template) for tmpgenc (just remove the .txt extension):
Click to view attachment
h4rdc0d3
For your viewing pleasure, here's a 30 second clip from CSI: NY's Tri-Borough episode produced via the above process:

Click to view attachment

P.S. That's 30 seconds... squeezed into 1,177,604 bytes!!!
h4rdc0d3
And for a notion of the performance I'm getting playing these on the zaurus, here's a clip of my 5600 playing the intro to Battlestar Galactica.

SORRY! Had to kill it... too much filespace.
TonyOlsen
QUOTE(h4rdc0d3 @ Jan 26 2005, 07:40 PM)
For your viewing pleasure, here's a 30 second clip from CSI: NY's Tri-Borough episode produced via the above process:

Click to view attachment

P.S. That's 30 seconds... squeezed into 1,177,604 bytes!!!
*


MPEG (MPEG-1) is so... well... 1980's.

MPEG-4 can encode higher quality at half that bitrate, and Windows Media and Real Video can do even better than that (although, last I heard, Zaurus doesn't support Windows Media and Real Video yet, so MPEG-4, DIVX, On2 (did I get that right?), etc is all we can do for the time being.... but that's 80% good enough for now. :-) )
h4rdc0d3
QUOTE
MPEG (MPEG-1) is so... well... 1980's.


I wholeheartily agree... but it was all I knew at the time... luckily I've found a better way.

I have had much recent success with MeWiG on Windows. I highly recommend downloading and installing the windows binary (or compile it yourself) MPlayer / MEncoder from http://www.mplayerhq.hu/ and MeWiG (Mencoder Windows Gui) from http://mewig.sf.net/.

Here are my recommended MeWiG options, YMMV:
- Encode as mp3 (using lame)
- Audio Bitrate 96
- Increase volume by 10dB (optional)
- Encode video using ffmpeg (divx!)
- Codec mpeg4 (divx!)
- Video Bitrate 120
- 2 Pass
- High quality (1) fewest bits (vhq)
- 4 mvs
- trellis quant
- Crop as needed
- Scale to max 320 width or 240 height

This gets an hour of PVR'd TV (commercials cut out) down to 70-75 MB and a movie at around 225-230 MB. I'm still testing... but initial results appear to have a slight noticeable higher quality in both sound and video with a 25% reduction in filesize as compared to their counterparts encoded via my instructions above.

Another cool part about MeWiG is that you can use the GUI to create the command lines and then have a starting point to make your own scripts, or run a bunch as a batch job in a cmd prompt.

Also, I haven't tried any ogg/ogm's with MeWiG yet, but the option is in the GUI.
adf
dvd::rip and transcode provide excellent results as well, btw
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2017 Invision Power Services, Inc.