AcxCircuitAddConnections 函数 (acxcircuit.h)
AcxCircuitAddConnections 函数将连接添加到 ACXCIRCUIT。
语法
NTSTATUS AcxCircuitAddConnections(
ACXCIRCUIT Circuit,
PACX_CONNECTION Connections,
ULONG ConnectionsCount
);
参数
Circuit
现有的 ACXCIRCUIT 对象。 有关 ACX 对象的详细信息,请参阅 ACX 对象的摘要。
Connections
指向 ACX_CONNECTION 结构的指针,该结构描述包括引脚 ID 的引脚结构。
ConnectionsCount
将添加到线路的连接数。 这是一个基于计数。
返回值
如果调用成功,则返回 STATUS_SUCCESS
。 否则,它将返回适当的错误代码。 有关详细信息,请参阅 使用 NTSTATUS 值。
言论
例
示例用法如下所示。
//
// Explicitly connect the circuit/elements. Note that driver doesn't
// need to perform this step when circuit/elements are connected in the
// same order as they were added to the circuit. By default ACX connects
// the elements starting from the sink circuit pin and ending with the
// source circuit pin for both render and capture devices.
//
// circuit.pin[default_sink] -> 1st element.pin[default_in]
// 1st element.pin[default_out] -> 2nd element.pin[default_in]
// 2nd element.pin[default_out] -> circuit.pin[default_source]
//
const int numElements = 2;
const int numConnections = numElements + 1;
ACXCIRCUIT Circuit;
ACX_CONNECTION connections[numConnections];
ACX_CONNECTION_INIT(&connections[0], Circuit, Elements[ElementCount - 2]);
ACX_CONNECTION_INIT(&connections[1], Elements[ElementCount - 2], Elements[ElementCount - 1]);
ACX_CONNECTION_INIT(&connections[2], Elements[ElementCount - 1], Circuit);
//
// Add the connections linking circuit to elements.
//
status = AcxCircuitAddConnections(Circuit, connections, SIZEOF_ARRAY(connections));
ACX 要求
最低 ACX 版本: 1.0
有关 ACX 版本的详细信息,请参阅 ACX 版本概述。
要求
要求 | 价值 |
---|---|
标头 | acxcircuit.h |
IRQL | PASSIVE_LEVEL |