共用方式為


AcxDeviceDetachCircuit 函式 (acxdevice.h)

AcxDeviceDetachCircuit 函式會在移除之前,先將音訊線路與 WDFDEVICE 中斷連結。

語法

NTSTATUS AcxDeviceDetachCircuit(
  WDFDEVICE  Device,
  ACXCIRCUIT Circuit
);

參數

Device

WDFDEVICE,要從中卸離 Circuit 參數所指定的音訊線路。

Circuit

要從 Device 參數所指定的 WDFDEVICE 中移除的音訊線路。

傳回值

AcxDeviceDetachCircuit 如果呼叫成功,就會傳回STATUS_SUCCESS。 否則,它會傳回 NTSTATUS 錯誤碼。

此函式只能從此裝置的 EVT_WDF_DEVICE_RELEASE_HARDWARE 回呼函式呼叫。

AcxDeviceDetachCircuit 將線路與裝置中斷連結。 呼叫端負責刪除 ACXCIRCUIT 物件。

言論

WDFDEVICE                    Device;
NTSTATUS                     status;
PCODEC_RENDER_DEVICE_CONTEXT renderDevCtx = NULL;

// Code to initialize WDFDEVICE...

renderDevCtx = GetRenderDeviceContext(Device);

ASSERT(renderDevCtx->Circuit);
status = AcxDeviceDetachCircuit(Device, renderDevCtx->Circuit);

if (!NT_SUCCESS(status))
{
    ASSERT(FALSE);
    goto exit;
}

ACX 需求

ACX 最低版本: 1.0

如需 ACX 版本的詳細資訊,請參閱 ACX 版本概觀

要求

要求 價值
標頭 acxdevice.h
IRQL PASSIVE_LEVEL

另請參閱