Re: mplayerplug-in leaving zombies
Kevin DeKorte <[email protected]>
| Newsgroups | gmane.comp.mozilla.mplayerplug-in |
|---|---|
| Message-ID | <[email protected]> |
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Forest Bond wrote: > Hi Kevin, > > Thanks again for your time. > > On Mon, Oct 01, 2007 at 09:38:38AM -0600, Kevin DeKorte wrote: >> Forest Bond wrote: >>> As you may remember, my application uses the mplayer plug-in to display >>> television channels. I am conducting some testing where my code >>> continuously changes the television channel on a delay loop. The channel is >>> changed by calling Stop(), SetURL(), and then Play(). >> might want to try calling "quit()" instead of stop. As that should kill >> mplayer where Stop might try to pause the media. Also instead of >> "SetURL" you might try "Open" or "filename = "tv://x" where x is your >> channel. > > Why are there so many different ways to do these things? Compatibility with different plugins. And also how some of this stuff works. > On the other hand, I'm not entirely clear as to why the player process is being > killed at all. Why not keep the slave mplayer process alive for the entire > duration of the plugin instance's life? That would certainly simplify some of > the thread/process management issues, and would also result in shorter delay > between play, stop, etc. The main reason is this. When a media file is over in mplayer "-idle" mode. Mplayer doesn't say that the file is over. It just quits sending output. I've asked them to add this feature or even to add a property that can be queried to see if the file is complete. But so far no good. > > Also, I've found that things go bad when I do this: > > mplayer.filename = 'foo'; > mplayer.Play(); > mplayer.filename = 'bar'; > > This seems to be necessary, instead: > > mplayer.filename = 'foo'; > mplayer.Play(); > mplayer.Stop(); > # delay here ... > mplayer.filename = 'bar'; > mplayer.Play(); > Have you tried "quit()" instead of "Stop()"? They actually do different things. > However, I see there is a slave command "loadfile" which allows changing the > mplayer URL without stopping playback. mplayer does what you would expect and > immediately begins playing the new URL. > > At the very least, it would be nice to make this feature available as a new > portion of the API. It would be better, of course, to simplify the API a little > bit, too. Do you have any strong feelings about this? The API is derived from the various plugins we emulate. All those methods are there for a reason. If you would like something added, send a patch, I'll review it and most likely include it. Kevin - -- Get my public GnuPG key from http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x7D0BD5D1 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (GNU/Linux) Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org iD8DBQFHA4ek6w2kMH0L1dERAr2PAJ92aUeS7EnayUft30osNM5j8hK3zwCfeNuE FXL7ps2YC/ghx4xo4rzAdJ8= =qzTN -----END PGP SIGNATURE----- ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/