AudioAdapter
Description:
Provides audio adapter capabilities, including initializing ports, creating rendering and capturing tasks, and obtaining the port capability set.
Since:
1.0
Version:
1.0
Summary
Data Fields
Details
CreateCapture
Description:
Creates an AudioCapture object.
Parameters:
Returns:
Returns 0 if the AudioCapture object is created successfully; returns a negative value otherwise.
See also:
CreateRender
Description:
Creates an object.
Parameters:
Returns:
Returns 0 if the AudioRender object is created successfully; returns a negative value otherwise.
See also:
DestroyCapture
Description:
Destroys an object.
Parameters:
Attention:
Do not destroy the object during audio capturing.
Returns:
Returns 0 if the object is destroyed; returns a negative value otherwise.
See also:
Description:
Destroys an object.
Parameters:
adapter | Indicates the pointer to the audio adapter to operate. |
render | Indicates the pointer to the object to operate. |
Attention:
Do not destroy the object during audio rendering.
Returns:
See also:
GetPassthroughMode
Description:
Obtains the passthrough data transmission mode of the audio port driver.
Parameters:
adapter | Indicates the pointer to the audio adapter to operate. |
port | Indicates the pointer to the port. |
mode | Indicates the pointer to the passthrough transmission mode to obtain. |
Returns:
Returns 0 if the mode is successfully obtained; returns a negative value otherwise.
See also:
GetPortCapability
Description:
Obtains the capability set of the port driver for the audio adapter.
Parameters:
Returns:
Returns 0 if the capability set is successfully obtained; returns a negative value otherwise.
InitAllPorts
Description:
Initializes all ports of an audio adapter.
Call this function before calling other driver functions to check whether the initialization is complete. If the initialization is not complete, wait for a while (for example, 100 ms) and perform the check again until the port initialization is complete.
Parameters:
adapter | Indicates the pointer to the audio adapter to operate. |
Returns:
Returns 0 if the initialization is successful; returns a negative value otherwise.
Description:
Sets the passthrough data transmission mode of the audio port driver.
Parameters:
adapter | Indicates the pointer to the audio adapter to operate. |
port | Indicates the pointer to the port. |
mode | Indicates the passthrough transmission mode to set. |
Returns:
Returns 0 if the setting is successful; returns a negative value otherwise.