Powered by MSDN

US - English
NEW! Silverlight 5 is available Learn More

How to use Windows Media Server and MMS in Silverlight? RSS

53 replies

Last post Mar 21, 2011 07:48 AM by guinxxx

(1)
  • moorecreative

    moorecreative

    Member

    18 Points

    9 Posts

    Re: Re: Re: Re: Re: How to use Windows Media Server and MMS in Silverlight?

    Nov 06, 2008 08:35 PM | LINK

    yes, samlan is right on there... some of this info wasn't easy to find earlier... now it's a bit more well documented.

    I'll update my earlier post, though, to mention that i've just completed tests this week with Silverlight 2, and no new protocols are supported. we still do not have true MMS or RTSP or HTTPS,

    AND, the port workaroudn of needing to have the mms://mydomain.com:1138/filename.wmv is still necessary.

    so from the many problems that we faced, none of them have been resolved and all the same workarounds are necessary and the same limitations still stick. this means that even though waiting for months and months for the final release of silverlight 2, in my opinion, there were no improvements to the problems faced with streaming from a traditional windows media streaming server (wms 9 series). now, there may be some improvements in this case with the new server 2008 version, but for those of us on older servers with series 9, there seem to be no improvements.

    Ryan Moore
    The Moore Creative Company
    http://www.moorecreative.com
  • paulxray

    paulxray

    Member

    14 Points

    2 Posts

    Re: Re: Re: How to use Windows Media Server and MMS in Silverlight?

    Nov 06, 2008 08:52 PM | LINK

    fyi, i figured out my problem , it was just having the mime types set correctly on the server, it turns out the one directory where it worked before was the exception that only worked because we were doing special handling of the files in that directory, and that threw me off for a couple days. so double check those mime type settings

  • ranjik2001

    ranjik2001

    Member

    4 Points

    2 Posts

    How to use Windows Media Server and Windows Media Encoder

    Mar 18, 2011 10:50 AM | LINK

    zI am working on a project where i need to broadcast Live videos using win Media Encoder 9,Win Media Services,Win server 2003,Asp.net 3.5/4.0,C#.

    i am facing much problems using win media Encoder sdk codes into my web application like Credentails issue,Unable to acquire network and much more.

    Even when i launch win media encoder wizard it throws me username and pwd invalid.Can anyone help me out.

     

     public static void Main()
        {
          try
          {
            // Create WMEncoderApp and WMEncoder objects.
            WMEncoderApp EncoderApp = new WMEncoderApp();
            WMEncoder wmEncoder = new WMEncoder();
            IWMEncoder Encoder = EncoderApp.Encoder;               
    
            wmEncoder.OnAcquireCredentials += new _IWMEncoderEvents_OnAcquireCredentialsEventHandler(wmEncoder_OnAcquireCredentials);
            // Display the predefined Encoder UI.
            EncoderApp.Visible = true;
            
            // Specify the source for the input stream.
            IWMEncSourceGroupCollection SrcGrpColl = wmEncoder.SourceGroupCollection;
            IWMEncSourceGroup SrcGrp = SrcGrpColl.Add("Test");
            IWMEncSource SrcAud = SrcGrp.AddSource(WMENC_SOURCE_TYPE.WMENC_AUDIO);
            IWMEncVideoSource2 SrcVid = (IWMEncVideoSource2)SrcGrp.AddSource(WMENC_SOURCE_TYPE.WMENC_VIDEO);
            SrcAud.SetInput("Default_Audio_Device", "Device", "");
            SrcVid.SetInput("Default_Video_Device", "Device", "");
    
            // Specify a profile.
            IWMEncProfile Pro;
            IWMEncProfileCollection ProColl = wmEncoder.ProfileCollection;
    
            for (int i = 0; i < ProColl.Count; i++)
            {
              Pro = ProColl.Item(i);
              if (Pro.Name == "Windows Media Video 8 for Local Area Network (384 Kbps)")
              {
                SrcGrp.set_Profile(Pro);
                break;
              }
            }
    
            string strServerName = "ServerName:PortNumber";
            string strPubPoint = "23";
            string strPubTemplate = "Live";
    
            //Broadcast a Live Event
            IWMEncPushDistribution PushDist = (IWMEncPushDistribution)wmEncoder.Broadcast;
            IWMEncBroadcast BrdCst = wmEncoder.Broadcast;
    
            BrdCst.set_PortNumber(WMENC_BROADCAST_PROTOCOL.WMENC_PROTOCOL_HTTP, 82);
            //BrdCst.set_PortNumber(WMENC_BROADCAST_PROTOCOL.WMENC_PROTOCOL_PUSH_DISTRIBUTION, 82);
            // Set the push distribution variables.
           
    
            //string MyNSCFile = "\\SNGS-DEMO\\Test\\MyPubPoint.nsc";
            //string MyNSCURL = "\\SNGS-DEMO\\Test\\MyPubPoint.nsc";
            // string MyASXFile = "\\SNGS-DEMO\\Test\\MyPubPoint.asx";
    
            PushDist.AutoRemovePublishingPoint = true;
            // Generate the announcement file.
            PushDist.ServerName = strServerName;
            PushDist.PublishingPoint = strPubPoint;
            PushDist.Template = strPubTemplate;
    
           
            // PushDist.GenerateMulticastInfoFile(MyNSCFile);
           // PushDist.GenerateAnnouncementFile(MyNSCURL, MyASXFile);
            
            // Retrieve the IWMSPublishingPoints object.
            //PubPoints = winMServer.PublishingPoints;
            // Create a new WMSServer object.       
    
            winMServer = new WMSServer();
            winMServer.AllowClientsToConnect = true;
            
            // Retrieve the IWMSPlugin object for the
            // WMS Publishing Points ACL Authorization plug-in.
            //Plugin = winMServer.EventHandlers["WMS Publishing Points ACL Authorization"];
    
            // Retrieve the administrative interface for the
            // WMS Publishing Points ACL Authorization plug-in.
            //IWMSACLCheckAdmin ACLCheckAdmin = (IWMSACLCheckAdmin)Plugin.CustomInterface;
    
            // Retrieve the list of access control entries.
            //IWMSAccessControlList AccessCtrlList = ACLCheckAdmin.AccessControlList;         
            
             //// Specify the push distribution variables, including the Windows Media
            //// server name, publishing point, and announcement files.              
       
            wmEncoder.OnStateChange += new _IWMEncoderEvents_OnStateChangeEventHandler(wmEncoder_OnStateChange);
            wmEncoder.OnSourceStateChange += new _IWMEncoderEvents_OnSourceStateChangeEventHandler(wmEncoder_OnSourceStateChange);
            //Server Credentials
    
            wmEncoder.PrepareToEncode(true);
            wmEncoder.Start();
          }
    
          catch (Exception e)
          {
            // TODO: Handle exceptions.
          }
    
        }

    Ranjith Kumar
  • guinxxx

    guinxxx

    Member

    2 Points

    1 Post

    Re: How to use Windows Media Server and Windows Media Encoder

    Mar 21, 2011 07:48 AM | LINK

    oh