Jump to content
  • Advertisement
Sign in to follow this  

Video and Audio playback to texture or overlay

This topic is 2603 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts


We are using DirectX 10 (or 9 if required) and C++ and would like to play back a video "in game".

That is to say there is either rendered to a quad within the game a video overlay. It will also need to play audio.

A bit of googling shows there is a managed control "AudioVideoPlayback" that does this, but nothing for C++ as far as we can find.

So any pointers on how to achieve this in C++ and DX 9/10?


Share this post

Link to post
Share on other sites
I've found a helpful library DSDX (http://sourceforge.net/projects/dsdxlibrary/) which uses direct show to decode the video to a texture.

I've only got the sample working in DX9c but hopefully will get it working in DX10 soon.

Notes for anyone wanting to use this:

1) Download the windows SDK (make sure you get the correct 32/AMD (64bit) version
2) Install the SDK including the samples
3) In the samples you'll find under multimedia the directshow code/includes and solution for building the strmbase(d).lib. Build this
4) In your DSDX project reference the directX and windows SDK and directshow includes. MAKE SURE you put the directshow includes before the windows/direct x ones.
5) build and hopefully bobs your uncle!

Note if you are trying to build the DSDX dlls from scratch you will need to use pragma export as I couldn't get the .def file working in VS2010 for some reason.

Eventually when I get DX10 sample working I'll commit them back to the sourceforge project.


Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!