Home » Community » Forums » » The Basics to Using DirectShow
  Intel sponsors gamedev.net search:   
[Control Panel] [Register] [Bookmarks] [Who's Online] [Active Topics] [Stats] [FAQ] [Search]

Add Forum to Favorites |  Send Topic To a Friend | View Forum FAQ | Track this topic


 Last Thread Next Thread 
 The Basics to Using DirectShow
Post Reply 
It's a very interesting article you wrote. I am trying DirectShow right now and it works just fine. It's very simple to use but I have a few problems with an ASSERT:
ASSERT Failed
mtIn == mtOut
At line 423 of d:\nt_chk\multimedia\dshow\filters\core\filgraph\filgraph\filgraph.cpp
Continue? (Cancel to debug)

It occures each time I initialize DirectShow. I tried the sample from the SDK and I have the same problems. I tried BGMusic.exe, Jukebox.exe... But It perfectly works when I press the Yes button on the Assert message box.

Can you help ?

[Edited by - jmmolina on November 4, 2004 9:41:49 PM]

 User Rating: 1009   |  Rate This User  Send Private MessageView Profile Report this Post to a Moderator | Link

This is old but I bet someone will use it eventually.

The article is missing which libraries must be referenced:

Strmiids.lib
Exports class identifiers (CLSIDs) and interface identifiers (IIDs). All DirectShow applications require this library.

Quartz.lib
Exports the AMGetErrorText function. If you do not call this function, this library is not required.


 User Rating: 1070   |  Rate This User  Send Private MessageView Profile Report this Post to a Moderator | Link

Also,
pGB->Run() is incorrect.
pMC->Run() would be the correct one, since the MediaControl is the player not the graph builder.

 User Rating: 1070   |  Rate This User  Send Private MessageView Profile Report this Post to a Moderator | Link

I want creat button backward anh forward in media player of me,I use directshow,but i don't understand that function, and i don't understand about creat seek.
can somebody help me?

 User Rating: 1015   |  Rate This User  Send Private MessageView Profile Report this Post to a Moderator | Link

Add this

static IMediaSeeking *pMS = NULL;

and later, insert this

pGB->QueryInterface(IID_IMediaSeeking, (void **)&pMS);

I used the seeking control to find out when to continue my game, instead of using events

LONGLONG cur,dur;
pMS->GetDuration(&dur);
pMS->GetCurrentPosition(&cur);

if (cur>=dur-1)
{
pMC->StopWhenReady();
Play=FALSE;
}

 User Rating: 1015    Report this Post to a Moderator | Link

Nice article but i am having a problem, i want to capture the current frame and save it to file (jpg/bmp), for this ive started with the AmCap sample provided in the SDKs, added a binded button (ins) to start a function that should in the end do this, but i'm lost, i dont know at all what to do.

So please, could anyone help me out here? Im using Visual Studio 2008, C++, without MFC.

Contact me here or by e-mail caligo(at)nexilus.com


 User Rating: 1015   |  Rate This User  Send Private MessageView Profile Report this Post to a Moderator | Link

This is very good artical, very much helpful.
I am facing some issue with mouse and key events, once i set the owner to my child window, video is playing properly on child window, but i am not reciving the mouse event on the child window. I have tried put_MessageDrain() with both parent and child window, but the result is same.

//Set the child window
pVW->put_Owner((OAHWND)g_hwnd);

//Sets the child window
pVW->put_Windowstyle(WS_CHILD | WS_CLIPSIBLINGS);

//here we create a RECT in which to draw the child window on
RECT vwrect;

//get the size of the Parent
GetClientRect(g_hwnd,&vwrect);

//Set the Child to this position
pVW->SetWindowPosition(0,0,vwrect.right,vwrect.bottom);
pVW->put_MessageDrain((OAHWND) g_hwnd);



 User Rating: 1015   |  Rate This User  Send Private MessageView Profile Report this Post to a Moderator | Link

All times are ET (US)

Post Reply
 Last Thread Next Thread 
Forum Rules:
You may not post new threads
You may post replies
You may not edit your posts
You may not use HTML in your posts
Jump To:
Administrative Options: