pub unsafe extern "C" fn OH_AVSource_CreateWithDataSourceExt(
dataSource: *mut OH_AVDataSourceExt,
userData: *mut c_void,
) -> *mut OH_AVSourceAvailable on crate features
api-10 and api-20 only.Expand description
Creates an OH_AVSource instance with dataSource and userData.
Required System Capabilities: SystemCapability.Multimedia.Media.Spliter
§Arguments
-
dataSource- A pointer to the data source structure, which can obtain the input data. -
userData- A pointer to user-defined data.
§Returns
- Returns a pointer to an OH_AVSource instance if the execution is successful, otherwise returns nullptr. Possible failure causes:
- dataSource is nullptr.
- dataSource->size == 0.
- set data source failed.
- out of memory.
- demuxer engine is nullptr.
Available since API-level: 20