Функция AcxCircuitAddConnections (acxcircuit.h)
Функция AcxCircuitAddConnections добавляет подключения к ACXCIRCUIT.
Синтаксис
NTSTATUS AcxCircuitAddConnections(
ACXCIRCUIT Circuit,
PACX_CONNECTION Connections,
ULONG ConnectionsCount
);
Параметры
Circuit
Существующий объект ACXCIRCUIT. Дополнительные сведения о объектах ACX см. в сводке по объектам ACX.
Connections
Указатель на структуру ACX_CONNECTION, описывающую структуру закреплений, включая идентификаторы контактов.
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 |