[MPlayer-dev-eng] mplayer.c, main

Attila Kinali attila at kinali.ch
Tue Sep 7 02:34:24 CEST 2004


On Mon, Sep 06, 2004 at 04:10:57PM +0100, Ed Wildgoose wrote:
> Kenny (Constantine Shulyupin) wrote:
> >Wold you like, I'll divide monolithic main in mplayer.c to subroutines?

Can be done, but very carefully.
main does a lot of things and is also a time critical routine.
If you split it, it still has to do the same thing and be as fast
as before (use a profiler to verify this).

 
> Sounds like a good idea.  It's on my ToDo list as well.
> 
> I think what would be extremely neat would be to not just break it up, 
> but tweak it slightly to be more like an event loop, so that we can 
> choose how often for example to scan keyboard input, have the ability to 
> spin feeding audio while waiting for the video frame to become due, 
> etc.  Looks fairly straightforward from here, but perhaps not...

Note that Ed is not a developer and note also that we the developers did
not agree that main should be rewriten as an event loop. Actually i
pointed out quite a few difficulties when Ed proposed this the first time
but he didnt respond to them at all.

Kenny: If you really want to do this, go ahead, but be aware that it
will be not easy to get it accepted as main is one of the core points of
mplayer which everything depends on. Any change there has to be done
very carefully and with a lot of testing.

				Attila Kinali




More information about the MPlayer-dev-eng mailing list