Video as texture ?

Last post 05-07-2008, 8:42 AM by Rim van Wersch. 8 replies.
Sort Posts: Previous Next
  •  06-11-2007, 3:05 PM

    Video as texture ?

        Hi guys,

    i am actually learning xna, and i am using the GameStateManager sample to learn some of the basis.

    My question is :
     how can i use a video instead of the background texture ?

    it is maybe documented but do not find it ...

    thanks !
  •  06-11-2007, 4:18 PM

    Re: Video as texture ?

    There's no support for video in the XNA framework.

    Joel has a solution which may or may not work for you here http://www.codecube.net/item.asp?cc_ItemID=358



    The ZBuffer - News and information for XNA and Managed DirectX
  •  06-11-2007, 4:28 PM

    Re: Video as texture ?

    The ZMan:

    There's no support for video in the XNA framework.

    That sounds bad ...


    The ZMan:

    Joel has a solution which may or may not work for you here http://www.codecube.net/item.asp?cc_ItemID=358



    ... but that sounds good ! I will take a look a this solution.

    Thanks a lot.
  •  06-11-2007, 4:41 PM

    Re: Video as texture ?

    There's lots of things that some people regard as essential and other do not that are not in XNA framework... see http://forums.xna.com/thread/10379.aspx

    The ZBuffer - News and information for XNA and Managed DirectX
  •  06-11-2007, 5:44 PM

    Re: Video as texture ?

    I think video integration is an important part of what xna should have, but maybe it is not the top priority //TODO on the xna team's list :-) ...

    I was so happy to see the video texturing on directx, i tried to use it to perform some kind of 'squad monitor' on a little game which is now on my code graveyard ... I was using directshow graphs, webcams for multiplayer 'squad monitor' like on action's movie ( alien for exemple ) .. Should be so great to perform that with xna

  •  06-11-2007, 6:20 PM

    Re: Video as texture ?

    If your game is PC only then you can still use DirectShow or any of the alternatives. I'm not sure exactly how or if you can integrate it with XNA though.

    The ZBuffer - News and information for XNA and Managed DirectX
  •  06-12-2007, 1:21 PM

    Re: Video as texture ?

    I think it is always possible to use a COM wrapper to use DirectShow on .NET plateform ( with a lot of Marshal inside ;-)  )

    But i will wait that xna's team integrate video on xna ... that is not my highest priority =)
  •  05-06-2008, 3:16 PM

    Re: Video as texture ?

    Yeah, real-time video integration is important.  Things like Sony eye-toy and even streaming video into game worlds is important.  Video also has applications in government/defense applications which require real-time video in virtual worlds or virtual command centers.

    Would be awesome if XNA had a some kind of GrabVideoFrame( source_camera, dynamic_texture ) method to grab a frame from a webcam.
  •  05-07-2008, 8:42 AM

    Re: Video as texture ?

    clinic:
    I think it is always possible to use a COM wrapper to use DirectShow on .NET plateform ( with a lot of Marshal inside ;-)  )

    There are plenty of COM wrappers out there (like DShow.NET), the only challenge should be getting the image data onto the textures. I haven't tried this myself for XNA yet, but maybe my old MDX webcam thing could be of some help here.

    Edit

    Never mind my shabby old library, looks like Joel's got everything covered and in much better shape Smile The link ZMan posted was down, so: http://www.codeplex.com/ScurvyMedia

View as RSS news feed in XML
©2007 Microsoft Corporation. All rights reserved. Privacy Statement Terms of Use Code of Conduct Feedback