Does anyone here know if the IVideoWindow is supported in WM5? The docs
included with the SDK seem to be in conflict with the docs on the MSDN site.
Combining this with the fact that I cant get the video to display .. I'm
wondering if it is just an empty implementation.
Many thx
-B
Gary Daniels
Windows CE Multimedia and Graphics
This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use.
"Brian Burgess" <bburg...@hotmail.com> wrote in message
news:OPqbwSHL...@tk2msftngp13.phx.gbl...
{
HRESULT hr;
// Create the filter graph manager and render the file.
CoCreateInstance(CLSID_FilterGraph, NULL, CLSCTX_INPROC, IID_IGraphBuilder,
(LPVOID*)&m_pGraph);
hr = m_pGraph->RenderFile(m_pStreamName, NULL);
if(hr != S_OK)
MessageBox(NULL,"Video filters could not connect","DSVideo",MB_OK)
// Specify the owner window.
IVideoWindow *pVidWin = NULL;
m_pGraph->QueryInterface(IID_IVideoWindow, (LPVOID*)&pVidWin);
pVidWin->put_Owner((OAHWND)m_hWnd); //m_hWnd is in the ATL control in this
case
pVidWin->put_WindowStyle(WS_CHILD | WS_CLIPCHILDREN | WS_CLIPSIBLINGS);
SIZEL Size;
AtlHiMetricToPixel(&m_sizeExtent, &Size);
pVidWin->SetWindowPosition(2,2,Size.cx-2,Size.cy-2);
// Set the owner window to receive event notices.
m_pGraph->QueryInterface(IID_IMediaEventEx, (LPVOID*)&m_pEvent);
m_pEvent->SetNotifyWindow((OAHWND)m_hWnd, WM_GRAPHNOTIFY, 0);
// Run the graph.
m_pGraph->QueryInterface(IID_IMediaControl, (LPVOID*)&m_pMediaControl);
m_pMediaControl->Run();
}
**********************************
This function works flawlessly in WinXP, but fails everytime in WM5 with the
following error code in 'hr' after running 'hr = m_pGraph->RenderFile':
0x80040218
The video files being tested in WM5 are identical to the ones in WinXP.
Also the same files do play in Windows Media Player on the WM5.
This HRESULT error code being returned is: VFW_E_CANNOT_RENDER No
combination of filters could be found to render the stream.
so what I would like to know is: Do I merely need to make the filter graph
manually? And, if so, how?.. like what filter names to use, what CLSIDs ,
Pins , etc .. etc .. or at least how to find out .. I am more than happy
to do homework .. just need to know where to look.
Many thx for the insights..
-BB
"Gary Daniels [MS]" <gar...@online.microsoft.com> wrote in message
news:OK1r9SOL...@TK2MSFTNGP09.phx.gbl...
Gary Daniels
Windows CE Multimedia and Graphics
This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use.
"Brian Burgess" <bburg...@hotmail.com> wrote in message
news:uG9oJIYL...@TK2MSFTNGP10.phx.gbl...
In the end I need to render a RGB565 stream. The file was intended only as
a proof of concept to a client. Thankfully I did this proof-of-concept on
'big-windows'. But still I need to render a file as proof enough to
continue on my current plan of development. What type of file then do you
suggest I use?
thx again
-BB
"Gary Daniels [MS]" <gar...@online.microsoft.com> wrote in message
news:eyB9%23qaLG...@TK2MSFTNGP12.phx.gbl...
It appears that you'll be able to use the media player object model to do
what you need.
Gary Daniels
Windows CE Multimedia and Graphics
This posting is provided "AS IS" with no warranties, and confers no rights.
You assume all risk for your use.
"Brian Burgess" <bburg...@hotmail.com> wrote in message
news:eAkfJFlL...@tk2msftngp13.phx.gbl...
Is there any info on what files I can play with DirectShow? I noted that
someone in the Embedded group here said they were able to get the DirectShow
to render a WMV file. Though they didn't show how...
Any thoughts?
thx
-B
"Gary Daniels [MS]" <gar...@online.microsoft.com> wrote in message
news:umDV%23PnLG...@TK2MSFTNGP12.phx.gbl...
CAxWindow axWnd(m_hWnd); // ActiveX host window class.
hr =
axWnd.CreateControlEx(CComBSTR(_T("{6BF52A52-394A-11d3-B153-00C04F79FAA6}")),
NULL, &pCntrUnk, &pUnk, GUID_NULL, NULL);
hr = pUnk->QueryInterface(__uuidof(IWMPPlayer), (LPVOID*)&pPlayer);
if(SUCCEEDED(hr))
{
hr = pPlayer->get_controls(&pControls);
hr = pPlayer->put_URL(CComBSTR(_T("\\My Documents\\Test.avi")));
hr = pControls->play();
}
return true;
}
*****************************
Any thoughts?
Many thx
-B
"Gary Daniels [MS]" <gar...@online.microsoft.com> wrote in message
news:umDV%23PnLG...@TK2MSFTNGP12.phx.gbl...
<code>
IGraphBuilder *pGraph = NULL;
IMediaControl *pMediaControl = NULL;
IMediaEventEx *pMediaEventEx = NULL;
TCHAR tsFile [] = L"\\Storage Card\\My Music\\Song2.mp3";
CoInitializeEx(NULL,COINIT_MULTITHREADED);
CoCreateInstance(CLSID_FilterGraph, NULL,
CLSCTX_INPROC, IID_IGraphBuilder, (LPVOID*)&pGraph);
pGraph->QueryInterface(IID_IMediaControl, (LPVOID*)&pMediaControl);
pGraph->QueryInterface(IID_IMediaEvent, (LPVOID*)&pMediaEventEx);
// (HERE IS THE CALL THAT FAILS ON SP 5.0)
pGraph->RenderFile(tsFile, NULL);// <-returns VFW_E_CANNOT_RENDER!!!
pMediaControl->Run();
//... handleDSEvents ...
</code>
I'm sure the file exists because I check for it. I'm also checking all
return values for the functions called before
pGraph->RenderFile(...)
The return values are okay (according the MSDN docs on expected return
values). I can play the same file with the Windows Media Player on the
SP 5.0 emulator (so the file is intact and accessible). Everything
appears just fine.
Could I add the necessary mp3 filters? Why can't I just use the
Smartphone 2003 mp3 filters?
According to Xiaoma in this post
http://groups.google.com/group/microsoft.public.smartphone.developer/browse_frm/thread/c708510418c1d81/3a79112622047b2b?q=VFW_E_CANNOT_RENDER&rnum=1#3a79112622047b2b
mp3 is not supported.
There's some other good DShow links here:
http://tmhare.mvps.org/links.htm
I couldn't find any websites addressing this Smartphone 5.0 and
DirectShow codec support issue.
-J Tom Moon
-Tom