Ignore:
Timestamp:
Jul 15, 2012, 5:06:35 AM (12 years ago)
Author:
roman
Message:

minor fix and EVR/DXVA2 logs

Location:
trunk/Utilities/RenderInterlacedVideo
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Utilities/RenderInterlacedVideo/MainPropertySheet.h

    r75 r76  
    11121112                        m_StopButton = GetDlgItem(IDC_MAIN_VMR9_STOP);
    11131113                        m_WeaveButton = GetDlgItem(IDC_MAIN_VMR9_WEAVE);
    1114                         m_ColorizeButton = GetDlgItem(IDC_MAIN_VMR9_WEAVE);
     1114                        m_ColorizeButton = GetDlgItem(IDC_MAIN_VMR9_COLORIZE);
    11151115                        DlgResize_Init(TRUE);
    11161116                        m_FilterGraph.CoCreateInstance();
     
    14241424                        _ATLTRY
    14251425                        {
    1426                                 // TODO: IMFVideoProcessor
     1426                                const CComQIPtr<IMFGetService> pMfGetService = m_RendererWindow.m_pBaseFilter;
     1427                                __D(pMfGetService, E_NOINTERFACE);
     1428                                CComQIPtr<IMFVideoProcessor> pMfVideoProcessor;
     1429                                __C(pMfGetService->GetService(MR_VIDEO_MIXER_SERVICE, __uuidof(IMFVideoProcessor), (VOID**) &pMfVideoProcessor));
     1430                                __D(pMfVideoProcessor, E_NOINTERFACE);
     1431                                UINT nModeCount = 0;
     1432                                CComHeapPtr<GUID> pModes;
     1433                                const HRESULT nGetAvailableVideoProcessorModesResult = pMfVideoProcessor->GetAvailableVideoProcessorModes(&nModeCount, &pModes);
     1434                                _Z4(atlTraceGeneral, 4, _T("nGetAvailableVideoProcessorModesResult 0x%08x, nModeCount %d\n"), nGetAvailableVideoProcessorModesResult, nModeCount);
     1435                                if(SUCCEEDED(nGetAvailableVideoProcessorModesResult))
     1436                                {
     1437                                        for(DWORD nModeIndex = 0; nModeIndex < nModeCount; nModeIndex++)
     1438                                        {
     1439                                                const GUID& Mode = pModes[nModeIndex];
     1440                                                _Z4(atlTraceGeneral, 4, _T("nModeIndex %d, Mode %s\n"), nModeIndex, FormatDeinterlaceMode(Mode));
     1441                                                DXVA2_VideoProcessorCaps Capabilities;
     1442                                                ZeroMemory(&Capabilities, sizeof Capabilities);
     1443                                                const HRESULT nGetVideoProcessorCapsResult = pMfVideoProcessor->GetVideoProcessorCaps(const_cast<GUID*>(&Mode), &Capabilities);
     1444                                                _Z4(atlTraceGeneral, 4, _T("nGetVideoProcessorCapsResult 0x%08x") _T(", ")
     1445                                                        _T("Capabilities")
     1446                                                        _T(".NumForwardRefSamples %d") _T(", ")
     1447                                                        _T(".NumBackwardRefSamples %d") _T(", ")
     1448                                                        _T(".DeinterlaceTechnology %d") _T(", ")
     1449                                                        _T(".ProcAmpControlCaps %d") _T(", ")
     1450                                                        _T(".VideoProcessorOperations %d") _T(", ")
     1451                                                        _T(".NoiseFilterTechnology %d") _T(", ")
     1452                                                        _T(".DetailFilterTechnology %d") _T(", ")
     1453                                                        _T("\n"),
     1454                                                        nGetVideoProcessorCapsResult,
     1455                                                        Capabilities.DeviceCaps,
     1456                                                        //Capabilities.InputPool,
     1457                                                        Capabilities.NumForwardRefSamples,
     1458                                                        Capabilities.NumBackwardRefSamples,
     1459                                                        Capabilities.DeinterlaceTechnology,
     1460                                                        Capabilities.ProcAmpControlCaps,
     1461                                                        Capabilities.VideoProcessorOperations,
     1462                                                        Capabilities.NoiseFilterTechnology,
     1463                                                        Capabilities.DetailFilterTechnology,
     1464                                                        0);
     1465                                        }
     1466                                }
     1467                                GUID Mode = GUID_NULL;
     1468                                const HRESULT nGetVideoProcessorModeResult = pMfVideoProcessor->GetVideoProcessorMode(&Mode);
     1469                                _Z4(atlTraceGeneral, 4, _T("nGetVideoProcessorModeResult 0x%08x\n"), nGetVideoProcessorModeResult);
     1470                                if(SUCCEEDED(nGetVideoProcessorModeResult) && !(nGetVideoProcessorModeResult == S_FALSE && Mode == GUID_NULL))
     1471                                        _Z4(atlTraceGeneral, 4, _T("Mode %s\n"), FormatDeinterlaceMode(Mode));
    14271472                        }
    14281473                        _ATLCATCHALL()
     
    15361581        {
    15371582                // NOTE: Windows SDK does not provide a linkable identifier...
     1583                #pragma region VMR-7/9
    15381584                struct __declspec(uuid("{335aa36e-7884-43a4-9c91-7f87faf3e37e}")) DXVA_DeinterlaceBobDevice;
    15391585                struct __declspec(uuid("{0e85cb93-3046-4ff0-aecc-d58cb5f035fd}")) DXVA_DeinterlaceContainerDevice;
     
    15421588                if(DeinterlaceMode == __uuidof(DXVA_DeinterlaceContainerDevice))
    15431589                        return _T("DXVA_DeinterlaceContainerDevice");
     1590                #pragma endregion
     1591                #pragma region EVR, DXVA2
     1592                struct __declspec(uuid("{5a54a0c9-c7ec-4bd9-8ede-f3c75dc4393b}")) DXVA2_VideoProcProgressiveDevice;
     1593                struct __declspec(uuid("{335aa36e-7884-43a4-9c91-7f87faf3e37e}")) DXVA2_VideoProcBobDevice;
     1594                struct __declspec(uuid("{4553d47f-ee7e-4e3f-9475-dbf1376c4810}")) DXVA2_VideoProcSoftwareDevice;
     1595                if(DeinterlaceMode == __uuidof(DXVA2_VideoProcProgressiveDevice))
     1596                        return _T("DXVA2_VideoProcProgressiveDevice");
     1597                if(DeinterlaceMode == __uuidof(DXVA2_VideoProcBobDevice))
     1598                        return _T("DXVA2_VideoProcBobDevice");
     1599                if(DeinterlaceMode == __uuidof(DXVA2_VideoProcSoftwareDevice))
     1600                        return _T("DXVA2_VideoProcSoftwareDevice");
    15441601                return CString(_PersistHelper::StringFromIdentifier(DeinterlaceMode));
    15451602        }
Note: See TracChangeset for help on using the changeset viewer.