Author Topic: Convert any mplayer playable video for playback on zaurus  (Read 5841 times)

cmisip

  • Sr. Member
  • ****
  • Posts: 256
    • View Profile
    • http://home.mchsi.com/~cmisip/index.htm
Zaurus 5600
Zynergy Rootfs 1.1
Custom zImage

How Do You Do That in Linux

maslovsky

  • Hero Member
  • *****
  • Posts: 1426
    • View Profile
    • http://my-zaurus.narod.ru
Convert any mplayer playable video for playback on zaurus
« Reply #1 on: March 31, 2004, 07:30:19 am »
I wonder why there is so much information? The only real trick is to use convert movies into 320x240, with bit rate up to 1500 Kbs (or so). Play them fullscreen in QVGA mode with no scaling...

cmisip

  • Sr. Member
  • ****
  • Posts: 256
    • View Profile
    • http://home.mchsi.com/~cmisip/index.htm
Convert any mplayer playable video for playback on zaurus
« Reply #2 on: March 31, 2004, 07:29:49 pm »
Information is good.  My goal was high quality, low disk space.  With this I can encode 1 hour (1 gigabyte) to 90 megabytes.  That\'s approximately 11 hours on a 1 GB CF card.  That\'s why there is a long encode script.   Any recommendations you can give is welcome.   In particular, I am interested in knowing how to redraw the Qtopia screen when mplayer quits.   Also, I was wondering how your 1500 kbs movie                                                                                                                                plays on the zaurus 5600 and how much disk space it uses.
Zaurus 5600
Zynergy Rootfs 1.1
Custom zImage

How Do You Do That in Linux

stupkid

  • Hero Member
  • *****
  • Posts: 578
    • View Profile
    • http://
Convert any mplayer playable video for playback on zaurus
« Reply #3 on: March 31, 2004, 11:21:19 pm »
1500kbs seems really high.  I get a good quality with DivX5 320x240@24fps with a bit rate of 320kbs.   I keep most movies under 250MB.  I can\'t imagine 1500kbs.

Zaurus SL-C3200 pdaXii13v2 5.5 / Ambicom WC1100C-CF / Socket Bluetooth Rev G


OpenMoko FreeRunner - Running Tweaked OM2008.x Image

tumnus

  • Hero Member
  • *****
  • Posts: 1176
    • View Profile
    • http://www.cpinkney.org.uk
Convert any mplayer playable video for playback on zaurus
« Reply #4 on: April 01, 2004, 02:35:34 am »
The Mplayer Shell ipk comes with an executable called \'redraw\' which seems to refresh the entire screen. Don\'t know how it works.

1500kbs would produce huge files and even an overclocked 5600 or Cxxx would struggle to play that.
# Search the Zaurus Howtos ## Search the Zaurus FAQs ## Find Z software at ELSI #
--------------------
UK SL5500 with Sharp ROM 3.13, SL5600 with Sharp ROM 1.32 - SuSE 9.0 Pro, Windows XP Home
Qualendar for Calendar and Todo
Socket Bluetooth CF Card (Rev F), Kingmax 512MB MMC Card, Palm Tungsten T Stylus,
Pretec CF->Smartmedia Adapter, Semsons Universal Battery Extender

maslovsky

  • Hero Member
  • *****
  • Posts: 1426
    • View Profile
    • http://my-zaurus.narod.ru
Convert any mplayer playable video for playback on zaurus
« Reply #5 on: April 01, 2004, 04:51:03 am »
If you noticed I wrote \"up to 1500 Kb/s\". Yes, it produces large movie but it still plays nicely on my C750. As I wrote the main trick it the resolution - Zaurus cannot do better than 320x240 wit no scaling. You can play with bit rate to make movies smaller and still keeping quality at decent level.

I\'ve experimented with a sample clip, originaly 640x480 WMV 1500 Kb/s. I\'ve converted it into 4 formats (320x240, 1500 Kb/s): MPEG1, MPEG2 (must be deinterlaced), WMV8 and DivX 5.

All of them play well with tkcVideo and kino2 (via mplayer), except for WMV8 - tkcVideo produces no sound and mplayer does not play it smoothly. Maybe because of high bit rate.

DivX is probably the best choice in terms of quality/size.

tumnus

  • Hero Member
  • *****
  • Posts: 1176
    • View Profile
    • http://www.cpinkney.org.uk
Convert any mplayer playable video for playback on zaurus
« Reply #6 on: April 01, 2004, 05:33:25 am »
Hmm, maybe the ATI acceleration is helping you to play high bitrate movies on your C750 (not jealous at all  ).

I think cmisip has a 5600, so like many of us, he is stuck with 320x240 anyway, without any hardware acceleration.
# Search the Zaurus Howtos ## Search the Zaurus FAQs ## Find Z software at ELSI #
--------------------
UK SL5500 with Sharp ROM 3.13, SL5600 with Sharp ROM 1.32 - SuSE 9.0 Pro, Windows XP Home
Qualendar for Calendar and Todo
Socket Bluetooth CF Card (Rev F), Kingmax 512MB MMC Card, Palm Tungsten T Stylus,
Pretec CF->Smartmedia Adapter, Semsons Universal Battery Extender

cmisip

  • Sr. Member
  • ****
  • Posts: 256
    • View Profile
    • http://home.mchsi.com/~cmisip/index.htm
Convert any mplayer playable video for playback on zaurus
« Reply #7 on: April 01, 2004, 09:22:03 am »
Thanks for the tip tumnus.  I looked at MPlayerShell last night and the redraw function works.  The ipk would install but it doesn\'t work.  I figured out that the mplayer version I use does not have the -menu option compiled in.    A quick change to the source and recompile fixed that.  Windowed playback is slow though because of software scaling.  Maybe I can turn this script into an mplayer launcher for full screen playback ( I like the file navigation feature).  My knowledge of java is nil at this point though.

Some thoughts :
Any insights or recommendations to improve quality, playback performance, file size are welcome.

The status line on mplayer playback shows the cpu is about 50 % busy with the ogm files.  This leads me to believe that it is the display that bogs the playback down.   Wish there was a way to improve fbdev or use some hardware scaler.  

Does anybody know how to cross compile or native compile mplayer with ogg support.  It fails for me with the errors . As such I am stuck with 0.9pre10.  


/usr/local/bin/arm-linux-gcc -c -O4   -pipe -ffast-math
-fomit-frame-pointer -D_REENTRANT
-I/home/cmisip/kernelzaurus/binaries/home/cmisip/kernelzaurus/binaries/include  -I../loader  -I/home/cmisip/kernelzaurus/binaries/home/cmisip/kernelzaurus/binaries/include     -o demux_ogg.o demux_ogg.c
demux_ogg.c: In function `demux_ogg_add_sub\':
demux_ogg.c:217: warning: initialization from incompatible pointer type
demux_ogg.c: In function `demux_ogg_read_packet\':
demux_ogg.c:320: warning: assignment from incompatible pointer type
demux_ogg.c:321: invalid operands to binary &
demux_ogg.c:370: warning: assignment from incompatible pointer type
demux_ogg.c:374: invalid operands to binary &
demux_ogg.c:375: invalid operands to binary &
demux_ogg.c:376: warning: assignment from incompatible pointer type
demux_ogg.c:381: invalid operands to binary &
demux_ogg.c:388: invalid operands to binary |
demux_ogg.c: In function `demux_ogg_add_packet\':
demux_ogg.c:414: invalid operands to binary &
demux_ogg.c:435: invalid operands to binary -
demux_ogg.c:436: invalid operands to binary -
demux_ogg.c: In function `demux_ogg_scan_stream\':
demux_ogg.c:492: warning: initialization makes pointer from integer
without a cast
demux_ogg.c:549: warning: initialization makes pointer from integer
without a cast
demux_ogg.c: In function `demux_ogg_open\':
demux_ogg.c:607: warning: assignment makes pointer from integer without
a cast
demux_ogg.c:646: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:646: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:646: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:646: warning: passing arg 1 of `strcmp\' from incompatible
pointer type
demux_ogg.c:646: warning: passing arg 1 of `strncmp\' from incompatible
pointer type
demux_ogg.c:701: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:701: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:701: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:701: warning: passing arg 1 of `strcmp\' from incompatible
pointer type
demux_ogg.c:701: warning: passing arg 1 of `strncmp\' from incompatible
pointer type
demux_ogg.c:711: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:711: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:711: warning: passing arg 1 of `strlen\' from incompatible
pointer type
demux_ogg.c:711: warning: passing arg 1 of `strcmp\' from incompatible
pointer type
demux_ogg.c:711: warning: passing arg 1 of `strncmp\' from incompatible
pointer type
demux_ogg.c:719: aggregate value used where an integer was expected
demux_ogg.c:719: aggregate value used where an integer was expected
demux_ogg.c:720: aggregate value used where an integer was expected
demux_ogg.c:720: aggregate value used where an integer was expected
demux_ogg.c:759: invalid operands to binary &
demux_ogg.c: In function `demux_ogg_fill_buffer\':
demux_ogg.c:925: warning: assignment makes pointer from integer without
a cast
demux_ogg.c: In function `init_avi_with_ogg\':
demux_ogg.c:1015: warning: assignment makes pointer from integer without
a cast
demux_ogg.c: In function `demux_ogg_seek\':
demux_ogg.c:1142: warning: initialization makes pointer from integer
without a cast
demux_ogg.c:1176: invalid operands to binary &
make[1]: *** [demux_ogg.o] Error 1
make[1]: Leaving directory
`/home/cmisip/kernelzaurus/MPlayerProject/MPlayer-1.0pre3/libmpdemux\'
make: *** [libmpdemux/libmpdemux.a] Error 2


Thanks for your interest in this thread.
Zaurus 5600
Zynergy Rootfs 1.1
Custom zImage

How Do You Do That in Linux

maslovsky

  • Hero Member
  • *****
  • Posts: 1426
    • View Profile
    • http://my-zaurus.narod.ru
Convert any mplayer playable video for playback on zaurus
« Reply #8 on: April 01, 2004, 09:27:37 am »
Quote
Does anybody know how to cross compile or native compile mplayer with ogg support. It fails for me with the errors . As such I am stuck with 0.9pre10.

mplayer that comes with kino2  supports ogg. You can extract it and copy over to your zaurus

cmisip

  • Sr. Member
  • ****
  • Posts: 256
    • View Profile
    • http://home.mchsi.com/~cmisip/index.htm
Convert any mplayer playable video for playback on zaurus
« Reply #9 on: April 01, 2004, 06:05:26 pm »
Thanks maslovsky

Tried it and it works.  I know you said that the trick is to use \"no scaling\"

On playback on the zaurus 5600, I have this output:

VDec: vo config request - 320 x 240 (preferred csp: Planar YV12)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is 1.33:1 - prescaling to correct movie aspect.
No accelerated colorspace conversion found
SwScaler: using unscaled Planar YV12 -] BGR 16-bit special converter
VO: [fbdev] 320x240 =] 320x240 BGR 16-bit


So it seems that it is still using Software Scaler ?

Any ideas on how I might be able to move this step from decode to encode?  Or how do I convert videos to BGR 16 bit with mencoder.



Thanks.
Zaurus 5600
Zynergy Rootfs 1.1
Custom zImage

How Do You Do That in Linux

cmisip

  • Sr. Member
  • ****
  • Posts: 256
    • View Profile
    • http://home.mchsi.com/~cmisip/index.htm
Convert any mplayer playable video for playback on zaurus
« Reply #10 on: April 01, 2004, 10:27:00 pm »
I had the wrong mplayer version.  The one from kino2 did not have to use the SWScaler.  It played YV12.  
Its working well.
Zaurus 5600
Zynergy Rootfs 1.1
Custom zImage

How Do You Do That in Linux

maslovsky

  • Hero Member
  • *****
  • Posts: 1426
    • View Profile
    • http://my-zaurus.narod.ru
Convert any mplayer playable video for playback on zaurus
« Reply #11 on: April 02, 2004, 07:57:57 am »
Quote
I had the wrong mplayer version.  The one from kino2 did not have to use the SWScaler.  It played YV12. 
Its working well.

So, do you get smooth playback with 320x240 movie at 29 fps on your 5600?

cmisip

  • Sr. Member
  • ****
  • Posts: 256
    • View Profile
    • http://home.mchsi.com/~cmisip/index.htm
Convert any mplayer playable video for playback on zaurus
« Reply #12 on: April 03, 2004, 12:14:13 am »
I would say decent playback, not silky smooth and I am encoding only in 15 fps.  


I am trying to make it work with the mplayer shell.  It keeps crashing on play and resume.  I thought initially it was a problem with the mplayer shell but  I found out that its mplayer that crashes in Qtopia if you pause and resume (not if you forward or rewind) which is strange.  Outside qtopia, this doesn\'t happen and mplayer is very stable.
Zaurus 5600
Zynergy Rootfs 1.1
Custom zImage

How Do You Do That in Linux

cmisip

  • Sr. Member
  • ****
  • Posts: 256
    • View Profile
    • http://home.mchsi.com/~cmisip/index.htm
Convert any mplayer playable video for playback on zaurus
« Reply #13 on: April 03, 2004, 11:45:56 am »
Well I narrowed it down to audio being the problem.  If mplayer is run with -nosound in qtopia, it will not crash on pause and resume.  I think it needs to have exclusive use of the audio device.  I wonder how I can make it do that in qtopia.
Zaurus 5600
Zynergy Rootfs 1.1
Custom zImage

How Do You Do That in Linux

hwkeye

  • Newbie
  • *
  • Posts: 39
    • View Profile
    • http://
Convert any mplayer playable video for playback on zaurus
« Reply #14 on: April 04, 2004, 07:00:03 pm »
Hi all,

very disappointed, you talk about using QVGA with no scaling with Mplayer.

I got mplayer 1.0rc3 and looking for  how to enable QVGA mode, I made some Divx5 with 320x240 resolution.

Could somebody help ?

thanks.