I am writing a File Source filter which has an Video output PIN, the output pin type is H.264 raw format:
HRESULT CVideoOutPin::GetMediaType(CMediaType *pMediaType)
{
CAutoLock lock(m_pFilter->pStateLock());
ZeroMemory(pMediaType, sizeof(CMediaType));
pMediaType->InitMediaType();
// {7807c3af-524f-11ce-9f53-0020af0ba770}
pMediaType->SetSubtype(&MEDIASUBTYPE_h264raw);
unsigned int * pSize = (unsigned int *) pMediaType->ReallocFormatBuffer(sizeof(unsigned int) * 2);
pSize[0] = m_pFlvFile->GetWidth();
pSize[1] = m_pFlvFile->GetHeight();
pMediaType->SetFormat((BYTE *)pSize, sizeof(unsigned int) * 2);
//*pMediaType = m_oVideoMediaType;
return S_OK;
}
I tried several decompress filter in GraphEdit.exe, and none of them can connect to my output pin.
Is there any DirectShow Filter I can use to complete the graph?
.AVI
or.MP4
with GraphEdit and inspect media types there. – Roman R.