I tried encoding http://home.tange.dk/theora/stream.dump with http://home.tange.dk/theora/optag-dvd 4. From that I got http://home.tange.dk/theora/dvd-4.theora.ogg. mplayer stream.dump works fine, but when playing the theora encoded file on my 2 GHz computer both mplayer and xine take 85% of my CPU while X takes the remaining 15% (i.e. 0% idle time) and the playback is no way near smooth. Using: mplayer -vo null dvd-4.theora.ogg I get peaks around 94% CPU. I tried the player_example from -mmx but it gave: $ ./player_example /tmp/dvd-4.theora.ogg Ogg logical stream 63b1a60 is Theora 1024x576 25.00 fps 4:2:0 video Encoded by Xiph.Org libTheora I 20040317 3 2 0 Ogg logical stream 24d0ed52 is Vorbis 2 channel 48000 Hz audio. X Error of failed request: BadMatch (invalid parameter attributes) Major opcode of failed request: 141 (XVideo) Minor opcode of failed request: 19 () Serial number of failed request: 19 Current serial number in output stream: 20 Reading http://lists.xiph.org/pipermail/theora/2005-March/000777.html it comes to me as a surprise that playback is that hard. I would naively assume that playback was much easier than encoding. Do you have ideas for getting it to work? /Ole
Hi Ole, you may want to try mplayer.theora-mmx from konvalo.org (see http://lists.xiph.org/pipermail/theora-dev/2005-March/002742.html) On Tue, Mar 29, 2005 at 02:39:25AM +0200, Ole Tange wrote:> $ ./player_example /tmp/dvd-4.theora.ogg > Ogg logical stream 63b1a60 is Theora 1024x576 25.00 fps 4:2:0 video > Encoded by Xiph.Org libTheora I 20040317 3 2 0 > Ogg logical stream 24d0ed52 is Vorbis 2 channel 48000 Hz audio. > X Error of failed request: BadMatch (invalid parameter attributes) > Major opcode of failed request: 141 (XVideo) > Minor opcode of failed request: 19 () > Serial number of failed request: 19 > Current serial number in output stream: 20I get similar errors if I try to play a high resolution movie on a screen which has lower resolution (or it just coincides with the properties of my hardware). Try the same on another hardware. You may even test with starting a big vnc virtual screen and running the decoder there. You will not be able to see the actual frame rate, but at least you may be able to see the picture.> Reading http://lists.xiph.org/pipermail/theora/2005-March/000777.html it > comes to me as a surprise that playback is that hard. I would naively > assume that playback was much easier than encoding.It _is_ much easier. I play movies in real time on a 800MHz Athlon, while I encode the same data [approximately] in real time on a 3GHz P4.> Do you have ideas for getting it to work?To reduce the resolution is the most certain way... Cheers, -- Ivan
Hi Ole, On Tue, Mar 29, 2005 at 09:21:07AM +0200, Ivan Popov wrote:> you may want to try mplayer.theora-mmx from konvalo.org > (see http://lists.xiph.org/pipermail/theora-dev/2005-March/002742.html)on a 3GHz P4 I can play this sample without problems, it takes about 50% of CPU with some peaks up to about 80%. I think you will be able to watch it on a 2GHz, with -framedrop option, without a noticable quality loss. Of course it depends also on your graphics card, though mine is rather old. Regards, -- Ivan
On Tue, 29 Mar 2005, Ivan Popov wrote:> you may want to try mplayer.theora-mmx from konvalo.org > (see http://lists.xiph.org/pipermail/theora-dev/2005-March/002742.html)That screwed up my X. So instead on a 2.4 GHz machine I tried: time mplayer.theora-mmx -vo null tmp/m021_300_1_70.ogg real 0m17.257s Not good when it should have been 10.1s. However, the dvd-4.theora.ogg worked fine with 75% cpu-usage of a 2.4 GHz (which is around 1.8 GHz - on a 2 GHz machine that will leave 10% for X-display)> > Reading http://lists.xiph.org/pipermail/theora/2005-March/000777.html it > > comes to me as a surprise that playback is that hard. I would naively > > assume that playback was much easier than encoding. > > It _is_ much easier. I play movies in real time on a 800MHz Athlon, > while I encode the same data [approximately] in real time on a 3GHz P4.What is the resolution of your source material? As a user of Theora I would appreciate a collection of statistics: How fast must a machine be to encode/decode a given resolution in real-time? The figures should based on worst-case (which I believe my example is pretty close to). /Ole
On Tue, Mar 29, 2005 at 01:24:22PM +0200, Ole Tange wrote:> > It _is_ much easier. I play movies in real time on a 800MHz Athlon, > > while I encode the same data [approximately] in real time on a 3GHz P4. > > What is the resolution of your source material?An excerpt from http://lists.xiph.org/pipermail/theora/2004-December/000735.html -------------------------------------------------------------------------- ... I encode like that: theora-encoder -va -vf -va crop=704:424,scale=528:320,hqdn3d=4:3:6 \ -s 64 -S 45 \ -a 0 -v 5.4 -o 528-320-5.4-0-436.ogg \ dvd://1 ... That test transformed 122 minutes of DVD 1001x424 (really 720x424=>1024x424) into 670 MB of 750x320 (really 528x320) which my 800 MHz Athlon can play without frame drops. ... -------------------------------------------------------------------------- Regards, -- Ivan
--- Ivan Popov <pin@medic.chalmers.se> wrote:> I encode like that: > > theora-encoder -va -vf -va > crop=704:424,scale=528:320,hqdn3d=4:3:6 \ > -s 64 -S 45 \ > -a 0 -v 5.4 -o 528-320-5.4-0-436.ogg > \ > dvd://1 > ... > That test transformed 122 minutes of DVD 1001x424 > (really 720x424=>1024x424) > into 670 MB of 750x320 (really 528x320) which my 800 > MHz Athlon can play > without frame drops.is there a way to know by advance the size of the ogg file you'll get (like some divx ripping tools do)? thx in advance Pat __________________________________ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/
On Tue, 29 Mar 2005, Ivan Popov wrote:> An excerpt from > http://lists.xiph.org/pipermail/theora/2004-December/000735.html > -------------------------------------------------------------------------- > ... > I encode like that: > > theora-encoder -va -vf -va crop=704:424,scale=528:320,hqdn3d=4:3:6 \ > -s 64 -S 45 \ > -a 0 -v 5.4 -o 528-320-5.4-0-436.ogg \ > dvd://1How do you detect these values? I guess 704:424 is from 'mplayer -vf cropdetect'. 528:320 and 4:3:6 is probably your own idea though it is not clear to me why you chose precisely these values. But where do -s 64 -S 45 come from? What I am after is: Could these be autodetected so the normal user will not need to figure these out? I am all for configurability. But if we have good defaults that give excellent results in most cases then it will be easier for non-geeks to use theora without tweaking. I am quite impressed with the speedup your suggestions made. From 90% CPU usage I am now around 40% - i.e no framedropping and quite usable. Thank you. /Ole -- The Patented Word Processor http://ole.tange.dk/swpat/