MCPcopy Create free account
hub / github.com/Aleksoid1978/VideoRenderer / VerifyMediaType

Method VerifyMediaType

Source/DX9VideoProcessor.cpp:1027–1044  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1025}
1026
1027BOOL CDX9VideoProcessor::VerifyMediaType(const CMediaType* pmt)
1028{
1029 const auto& FmtParams = GetFmtConvParams(pmt);
1030 if (FmtParams.DXVA2Format == D3DFMT_UNKNOWN && FmtParams.D3DFormat == D3DFMT_UNKNOWN) {
1031 return FALSE;
1032 }
1033
1034 const BITMAPINFOHEADER* pBIH = GetBIHfromVIHs(pmt);
1035 if (!pBIH) {
1036 return FALSE;
1037 }
1038
1039 if (pBIH->biWidth <= 0 || !pBIH->biHeight) {
1040 return FALSE;
1041 }
1042
1043 return TRUE;
1044}
1045
1046BOOL CDX9VideoProcessor::GetAlignmentSize(const CMediaType& mt, SIZE& Size)
1047{

Callers 1

CheckMediaTypeMethod · 0.45

Calls 1

GetBIHfromVIHsFunction · 0.85

Tested by

no test coverage detected