|
|||||||||
|
Thread Tools | Search this Thread |
October 31st, 2005, 10:22 PM | #1 |
Wrangler
Join Date: Feb 2002
Location: Cleveland, Ohio
Posts: 1,933
|
Who has DirectShow programming experience?
I'm writing an application in DirectShow but I have a few questions. DVi has always been my first stop for expert help--so have any of our developers tinkered with writing DirectShow video applications?
Specifically, I'm trying to get two video clips to play, sequentially, in the same screen space, with no pause in between. I've been using the Jukebox sample as my template, but it produces a little blip of a pause between clips while it builds the filter graph for the new clip and places/resizes the video window. If I know that both clips share the same video codec and size properties, how do I get away with not rebuilding the filter graph and not resizing the video window? Also, do I need to queue one clip up and get it playing before the last one ends in order not to have any pause between them?
__________________
All the best, Robert K S Search DVinfo.net for quick answers | The best in the business: DVinfo.net sponsors |
November 1st, 2005, 10:32 AM | #2 | |
Major Player
Join Date: Oct 2005
Location: Hillsborough, NC, USA
Posts: 968
|
This is a common problem but there's also a solution!
Start here: http://www.gdcl.co.uk/articles/MultipleGraphs.pdf GDCL is Geraint Davies Consulting Limited in North Wales, UK. Geraint is really *the guru* for all things DirectShow. Here's part of his bio: "While working for Microsoft's UK Development Lab, Geraint was architect and lead developer of the Quartz multimedia technology. This is a component-based multimedia architecture which is the basis for Microsoft's ActiveMovie and DirectShow and is now widely used for digital video playback, DVD and digital audio editing solutions, as well as being a key part of Microsoft's multimedia architecture." John. Enosoft http://www.enosoft.net high performance tools for music and video Quote:
|
|
November 2nd, 2005, 05:10 AM | #3 |
Wrangler
Join Date: Feb 2002
Location: Cleveland, Ohio
Posts: 1,933
|
It indeed looks like it may provide a path to seamless playback of video clips using DirectShow. Unfortunately, I can't get the samples to build. Here's the first compiler complaint holding me up:
Compiling... source.cpp c:\Documents and Settings\Administrator\Desktop\GMFBridge\source.cpp(235) : error C3861: 'wsprintfWInternal': identifier not found, even with argument-dependent lookup The line of code it points to: wsprintfW(wsz, L"FilterGraph %08p pid %08x", (DWORD_PTR)(IUnknown*)pGraph, GetCurrentProcessId()); It turns out wsprintfW is defined in wxutil.h: #define wsprintfW wsprintfWInternal But if I look for any definition of wsprintfWInternal, it's undefined. Further down in wxutil.h there's this commented section: Code:
// miscellaneous string conversion functions // NOTE: as we need to use the same binaries on Win95 as on NT this code should // be compiled WITHOUT unicode being defined. Otherwise we will not pick up // these internal routines and the binary will not run on Win95. // int WINAPIV wsprintfWInternal(LPWSTR, LPCWSTR, ...); //LPWSTR //WINAPI //lstrcpyWInternal( // LPWSTR lpString1, // LPCWSTR lpString2 // ); Code:
// int WINAPIV wsprintfWInternal(LPWSTR wszOut, LPCWSTR pszFmt, ...) // { // char fmt[256]; // !!! // char ach[256]; // !!! // int i; // // va_list va; // va_start(va, pszFmt); // WideCharToMultiByte(GetACP(), 0, pszFmt, -1, fmt, 256, NULL, NULL); // (void)StringCchVPrintf(ach, NUMELMS(ach), fmt, va); // i = lstrlenA(ach); // va_end(va); // // MultiByteToWideChar(CP_ACP, 0, ach, -1, wszOut, i+1); // // return i; // } Any suggestions? How can I get this puppy to compile? Has anyone else had success?
__________________
All the best, Robert K S Search DVinfo.net for quick answers | The best in the business: DVinfo.net sponsors |
November 2nd, 2005, 07:47 PM | #4 | |
Wrangler
Join Date: Feb 2002
Location: Cleveland, Ohio
Posts: 1,933
|
Geraint Davies offered the following two solutions, both of which I'm ashamed not to have come up with myself! :)
Quote:
__________________
All the best, Robert K S Search DVinfo.net for quick answers | The best in the business: DVinfo.net sponsors |
|
| ||||||
|
|