Sign in to follow this  

Help me! How to synchronize for play video and capture frame

This topic is 4360 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

HI ALL, I am using DirectShow to build an application. the app will play a video file (avi or wmv) by call IMediaControl->Run(); and capture frame by call ISampleGrabber::GetCurrentBuffer. Now , I want to the app can 'synchronize' play video and capture. My mean is at the same time when have any frame was read then capture will be performed. My question is can we this job by create a CALLBACK function? And how to do this? And more, please show me if you have any sample about this. Thanks for any help.

Share this post


Link to post
Share on other sites
Take a look at the video mixing renderer. I haven't done a lot with it personally but it can render each frame into a direct3d surface and notify you when it's ready for display.

http://msdn.microsoft.com/archive/default.asp?url=/archive/en-us/directx9_c/directx/htm/usingthevideomixingrenderer.asp

a search on www.codeproject.com turned up some samples that use it

http://www.codeproject.com/audio/vmr9.asp

http://www.codeproject.com/directx/DirectShowVMR9.asp



Share this post


Link to post
Share on other sites

This topic is 4360 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this