COPPCloseVideoSession 함수

샘플 COPPCloseVideoSession 함수는 현재 비디오 세션에 사용되는 COPP DirectX VA 디바이스 개체를 닫습니다.

구문

HRESULT COPPCloseVideoSession(
  _In_ COPP_DeviceData pThis
);

매개 변수

pThis [in]

  • COPP DirectX VA 디바이스 개체에 대한 포인터입니다.

반환 값

성공하면 0(S_OK 또는 DD_OK)을 반환합니다. 그렇지 않으면 오류 코드를 반환합니다.

설명

비디오 세션에서 출력 보호를 계속 적용하는 동안 COPPCloseVideoSession 함수를 호출할 수 있습니다. COPPCloseVideoSession은 COPP DirectX VA 디바이스 개체의 보호 설정을 실행 취소하고 그에 따라 전역 보호 설정을 조정해야 합니다.

COPPCloseVideoSession 함수는 DD_MOTIONCOMPCALLBACKS 구조체의 DestroyMoComp 멤버에 직접 매핑됩니다. DestroyMoComp 멤버는 디스플레이 드라이버 제공 DdMoCompDestroy 콜백 함수를 가리킵니다.

예제 코드

다음 코드는 COPPCloseVideoSession 함수를 구현하는 방법의 예를 제공합니다.

HRESULT
COPPCloseVideoSession(
    COPP_DeviceData* pThis
    )
{
    DWORD j, i;
    // enumerate all the protection types supported by this connector
    for (j = COPP_ProtectionType_HDCP, i = COPP_ProtectionTypeIndex_HDCP;
         j & COPP_ProtectionType_Mask; j <<= 1, i++) {
        // for each type supported, make sure the initial level
        // is set correctly
        if (g_ConnectorInfo[pThis->m_DevID].ProtectionTypeMask & j) {
            DWORD oldLevel = pThis->m_LocalLevel[i];
            g_COPPLevels[pThis->m_DevID].Levels[i][oldLevel]--;
        }
    }
    ResetKey(&pThis->m_AesHelper);
    return NO_ERROR;
}

Requirements

대상 플랫폼 버전
데스크톱 이 함수는 SP1 이상의 Windows Server 2003 및 SP2 이상에서 XP를 Windows 경우에만 적용됩니다.