The Media Center Sandbox

Resources and discussion for developing experiences in the Windows Media Center platform.
Welcome to The Media Center Sandbox Sign in | Join | Help
in Search

Play stream TV in VMC

Last post 09-25-2008, 10:48 AM by babgvant. 7 replies.
Sort Posts: Previous Next
  •  09-07-2008, 4:45 AM 8338

    Play stream TV in VMC

    Hi,

    my Internet provider allows us to read many TV channels from our connexion. These streams are send with the RTSP protocol, are MPEG2 or HD (H264+AAC), and can be played with VideoLAN (VLC).

    My project shoud be to write a MCML / C# plugin for VMC, in order to play it, with timeshifting, recording...
    So, what is the best solution ?

    First, I looked for creating a virtual TV card, using DVBSBridge SDK ( http://www.dvblogic.com/sdk.php ). This solution seems perfect, but a bit complicated for me...

    Another solution should be to take the stream, send it to a StreamBufferSink (the way VMC uses for display TV) and play it in VMC, or write it into a DVR-MS file, and play it. I've tried this (thanks to andy's tv blog), but Media Player seems unable to play a dvr-ms file while writing (this is absurd !)

    Another problem I meet is that Media Player can't directly play the stream (maybe it doesn't support RTSP protocol), and the only way I found is to use VLC to send the stream locally with HTTP protocol, and using a specifical DirectShow graph. Moreover, I have not access to timeshifting functions...

    MCML seems poor for playing video, the only function available is PlayMedia (MediaType.Video ). Do you know a way to play a speficical DirectShow graph in VMC that I have coded in C# (and using the Default Video Render filter) ?
    Moreover, I found in the Microsoft documentation the MediaType Dvr and Datacast ( http://msdn.microsoft.com/en-us/library/ms816505.aspx ). Do you know what it is ?

    Any help, advice should be appreciated.
  •  09-07-2008, 8:49 AM 8340 in reply to 8338

    Re: Play stream TV in VMC

    You could try changing the merit of your filter so that it is used by default instead of the original one used by Media Center.  If you can get your filter to be used when doing a "Render file" in GraphEdit, then you may be able to get it to work in Media Center.

    Cheers,
    Andrew

  •  09-07-2008, 6:09 PM 8342 in reply to 8338

    Re: Play stream TV in VMC

    If you want to playback the file during recording you need to use the Global namespace when configuring the sbesink, this can only be done from a process with admin rights (although network service seems to be able to do it too).
  •  09-08-2008, 6:32 AM 8343 in reply to 8338

    Re: Play stream TV in VMC

    For Multicasts you could use the Elecard DirectShow Graph.
    Very important: You have to add a rule in Windows Firewall for ehshell.exe.
  •  09-10-2008, 3:43 AM 8354 in reply to 8343

    Re: Play stream TV in VMC

    Thanks for your advices.

  •  09-10-2008, 8:59 AM 8355 in reply to 8342

    Re: Play stream TV in VMC

    babgvant:
    If you want to playback the file during recording you need to use the Global namespace when configuring the sbesink, this can only be done from a process with admin rights (although network service seems to be able to do it too).


    Are you sure that it's possible to read a DVR-MS file while writing it ?
    I included some part of the ToDVRMS software in a MCML application (I use the SBEHelper class), but I can only read it when the file is finished (and never when it's a stream! )
    Can you please give more details on using Global namespaces with SBE sink ?
    What do I need to change to my code ?
  •  09-18-2008, 1:16 AM 8390 in reply to 8342

    Re: Play stream TV in VMC

    babgvant:
    If you want to playback the file during recording you need to use the Global namespace when configuring the sbesink, this can only be done from a process with admin rights (although network service seems to be able to do it too).


    Please could you give me an anwser, it's important for me.
    thanks
  •  09-25-2008, 10:48 AM 8421 in reply to 8355

    Re: Play stream TV in VMC

    earl:


    Are you sure that it's possible to read a DVR-MS file while writing it ?
    I included some part of the ToDVRMS software in a MCML application (I use the SBEHelper class), but I can only read it when the file is finished (and never when it's a stream! )
    Can you please give more details on using Global namespaces with SBE sink ?
    What do I need to change to my code ?


    Yes I'm sure, how else could MC let you watch recorded tv while it's recording?

    Did you look at the platform sdk section on the SBE, it's documented there.  I've only been able to get it working when running everything elevated (which would mean turning UAC off in most scenarios), and todvrms will be updated at some point with the necessary changes.

    I hope you read the EULA for todvrms before incorporating code from it into your application, it's a reciprocal viral license which forces you to publish your source should you choose to distribute the application.
View as RSS news feed in XML
Powered by Community Server, by Telligent Systems