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

activeX and media center

Last post 08-02-2006, 6:29 AM by Maximka. 16 replies.
Page 1 of 2 (17 items)   1 2 Next >
Sort Posts: Previous Next
  •  07-25-2006, 8:21 AM 213

    activeX and media center

    I want to use my ActiveX control in media center program. But I don't know how define it in xml file and how working with it in C# code. I can't find solution in Windows Media Center SDK. Is anybody can help me?
  •  07-25-2006, 9:34 AM 214 in reply to 213

    Re: activeX and media center

    I don't think you can access ActiveX controls directly - you'd need to make a C# wrapper for the control, and reference the assembly within the MCML.

    To use the ActiveX control within C#, simply add a reference to the control (called a COM control in Visual Studio) and an interop wrapper will be created for you.  Now add methods in your C# code that correspond with controlling the ActiveX control functions, and you should be able to then use those methods within the MCML.

    Remember that you can't do any UI work in your own code, so if the ActiveX control is a visible control you can't use the UI (although you can use other functionality within the control).

    Cheers,
    Andy

  •  07-25-2006, 9:45 AM 216 in reply to 214

    Re: activeX and media center

    My activeX is visible. can you show simple example how add activeX in mcml? I am beginner in this technology documentation is not full at the moment.
  •  07-25-2006, 9:50 AM 218 in reply to 216

    Re: activeX and media center

    Sorry, but there's currently no way to embed a visible ActiveX control within an MCML UI
    Scott Moore (Microsoft)
  •  07-25-2006, 10:02 AM 220 in reply to 218

    Re: activeX and media center

    How about "WinFX XAML Browser Application (XBAP)"? Is this real to implement activeX in this application type?
  •  07-25-2006, 10:48 AM 224 in reply to 220

    Re: activeX and media center

    Yes, you should be able to embed an ActiveX control in XAML.Obviously, XBAP forums are the place to be looking for more information about this, but this link might be a good starting point:

    http://blogs.msdn.com/jgalasyn/archive/2005/10/22/483825.aspx

    -K

    Krishna Ravikumar (Microsoft)
  •  07-25-2006, 12:17 PM 225 in reply to 224

    Re: activeX and media center

    Suppose I want to build an application to stream my IP Security Cameras into Vista MCE. These cameras already have an activeX plugin that is very quick and easy to use.

    Are you saying that MCML doesnt support activeX right now?

    or  

    Are you saying MCML will never support activeX?


    blog.manghera.com
  •  07-25-2006, 1:45 PM 226 in reply to 225

    Re: activeX and media center

    soultaker,

     

    As previously mentioned, we don’t support embedding ActiveX (either windows or windowless) inside of MCML. From a technology standpoint, ActiveX isn’t readily compatible with our world which is built on DirectX devices and can be remoted at full video framerate to devices like the Xbox360. We simply don’t have HWNDs and GDI available in all our target scenarios (which ActiveX depends on). If there is sufficient customer demand for support for ActiveX compatibility in the future, of course, we’d definitely consider it. However, for Vista, we will not be supporting it.

     

    Is there any way to stream that video camera feed via http? If so, PlayMedia is an alternative method.

     

    Thanks,

     

    - Mark


    Mark Finocchio (Microsoft)
  •  07-25-2006, 11:00 PM 231 in reply to 225

    Re: activeX and media center

    If your camera ActiveX has a snapshot method you could always store that to file and update the MCML page with a timer - it's not going to be streaming, but using a timer with an interval of 40 you would get 25 frames per second which would be a close approximation of it.

    See the snowflake example in the MCML sampler for how to access files to display as images.

    Cheers,
    Andy

  •  07-25-2006, 11:13 PM 232 in reply to 226

    Re: activeX and media center

    I want to show my video in media center. I have the stream, but I don't know how I can show it. In XP I use ActiveX. How I can do it in Media center on mcml?
  •  07-26-2006, 12:10 AM 233 in reply to 232

    Re: activeX and media center

    Maximka,

    How is your stream surfaced? Media Center has the ability to play file or web-based video content via the PlayMedia API. This is a Media Center API, not MCML (but, can be accessed via MCML -- there are samples about "Media Center Integration"). If you have any video playing, simply putting in a Video tag under your Content will display the current playing stream within that Video tag's region.

    - Mark


    Mark Finocchio (Microsoft)
  •  07-26-2006, 12:26 AM 234 in reply to 233

    Re: activeX and media center

    I saw PlayMedia API. My stream is not a file or web-based video content. Is this real to create C# control and show it? I can draw my video on C# control, but I don't know how embed it in my program on "Windows Media Center Presentation Layer Applications".
  •  07-26-2006, 1:07 AM 235 in reply to 234

    Re: activeX and media center

    You can't add a visible UI element of your own to an MCML page though - you can only do it by outputting an image to a file, and reading the image back in to pass to a <graphic> element in MCML.

    Cheers,
    Andy

  •  07-26-2006, 9:27 AM 240 in reply to 235

    Re: activeX and media center

    Maximka, what codec does your video camera utilize. More than likely it's going to be some sort of industry standard I imagine. If you don't know for sure, post the make and model -- a search is bound to turn up information we can use to figure out if the stream coming from the camera is compatible with the PlayMedia API.
    Charlie Owen (Microsoft)
  •  07-27-2006, 1:42 AM 250 in reply to 240

    Re: activeX and media center

    How Can I play video file from hard disk?
    I have tag <Video> in my mcml file, but I can't get access to PlayMedia to start or stop playing
Page 1 of 2 (17 items)   1 2 Next >
View as RSS news feed in XML
Powered by Community Server, by Telligent Systems