Hello!I Have a problem using pause with IMediafilter.I read in msdn that pause in IMediafilter doesnt work like Imediacontrol.pause.So how can I make it work like Imediacontrol.pause.Imean when i pause a movie and after press play ,to start from the point i stopped the movie and no from the beginning...Any directions???
If IMediaControl does what you want, why not use that?
I Have syncronised two same videos playing on two monitors using mediafilter.run instead of media control.Thats why.What can i do?
And something else.My app cant dispaly same video mpeg2 on two monitors.This happens only with mpeg2,not with avi,not with wmv.Do you thing that is it good idea to use VMR mode renderless??
thank you for your time.....
What I don't understand is how many graphs have you (one or two) ?
And on which object do you call IMediaFilter.Pause (a single filter or the FilterGraph) ?
I have two graphs two instances of filter graph but same.I wanted to make this project and searching the Net I found this http://stackoverflow.com/questions/1299385/how-to-play-multiple-videos-in-sync-over-multiple-monitors-using-directshow .So I think(I am not so sure) I did what Geraint Davies described.The videos are working sunc but after a while I discovered that using IMediaFilter doesn't pause the way IMediaControl pauses.I am guessing that he proposed IMediaFilter cause it uses as argument the reference clock which is needed to syncronise the videos...Anyway if you have a suggestion I am here...I have to
tell you that I am beginner in directshow and I use VB.net.......
So you have implemented the (very good) Geraint's solution. What's the problem now ?
So Eric(thank you for your time)the problem now it is the pause.As I said before the IMediafilter it doesn't pause the graph the way IMediacontrol pauses.When I pause the graph with Imediafilter and try to rerun(btnplay)the movies are beginning from the start and no from the point I pressed pause.How I am gonna make this operate normally preserving the IMediaFilter??is there a way?or I have misunderstood something wrong?
So, why not use IMediaControl to pause the graph ? You can use a mix of IMediaControl and IMediaFilter methods...
What parameter are you passing to IMediaFilter.Run after a pause ?
I pass none and maybe here is the mistake..you gave me a hint maybe I should pass currentposition??And How can I mix IMediafilter with ImediaControl??If you like to give me a direction I will appreciate it a lot......
Sure, if you pass 0 to IMediaFilter.Run, you restart the graph from the beginning !
To get the current position, you can call IMediaSeeking.GetCurrentPosition or IMediaControl.Run that do that for you.
How to mix IMediaFilter & IMediaControl ? Just cast the same object with both interfaces.
Ok Eric thank you very much I will try it and write you back.....
Ok Eric Problem solved.....Now as I mentioned above i face another problem.It is impossible to play mpeg2 in both screens.I read somewhere that maybe renderless mode is my answer to my problem what do you think??
Thank you very much for your precius help...
Log in to post a comment.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.