[vdr] replace cDvbPlayer

Klaus Schmidinger Klaus.Schmidinger at cadsoft.de
Wed Nov 9 18:12:25 CET 2005


Patrick Fischer wrote:
> Hello
> A coupe of days ago I wrote to this list an question about current 
> running recordings and time shifting.
> I got no answer :-(
> 
> Now I would like to reword my question:
> 
> If I'm right, the cDVBPlayer(Control) handles all playing of recordings 
> and time shift.
> Now I would like to add some functions to the player to get some more 
> informations about the current running recording.
> I can't find a way to implement it by a plugin. I could "re" implement a 
> cMyDVBPlayer and the cMyDVBPlayerControl. But how to replace the 
> original cDVBPlayer with cMyDVBPlayer without patching?
> 
> By the way:
> 
> cReplayControl was derivative from cDvbPlayerControl
> cDvbPlayerControl has a cDvbPlayer
> 
> cDvbPlayer was derivative from cPlayer
> 
> every time a new recording should be played vdr cControl::Shutdown()
> and then cControl::Launch(new cReplayControl);
> 
> I cant see a possibility to replace it without patching.
> Maybe somebody (klaus, xine developer, softdevice developer,...) can 
> help me with some words.

If what you want to know is the progress of the current replay
session, you could do

   cControl *Control = cControl::Control();
   if (Control) {
      int Current, Total;
      if (Control->GetIndex(Current, Total)) {
         // do something with the values
         }
      }

This should work with any player that uses the cControl/cPlayer
facilities. Of course this doesn't return useful values in
transfer mode.

Klaus



More information about the vdr mailing list