Create a new device of the specified type from an existing device.
This function performs the same action as av_hwdevice_ctx_create_derived,
however, it is able to set options for the new device to be derived.
@param dst_ctx On success, a reference to the newly-created
AVHWDeviceContext.
@param type The type of the new device to create.
@param src_ctx A reference to an existing AVHWDeviceContext which will be
used to create the new device.
@param options Options for the new device to create, same format as in
av_hwdevice_ctx_create.
@param flags Currently unused; should be set to zero.
@return Zero on success, a negative AVERROR code on failure.
Create a new device of the specified type from an existing device.
This function performs the same action as av_hwdevice_ctx_create_derived, however, it is able to set options for the new device to be derived.
@param dst_ctx On success, a reference to the newly-created AVHWDeviceContext. @param type The type of the new device to create. @param src_ctx A reference to an existing AVHWDeviceContext which will be used to create the new device. @param options Options for the new device to create, same format as in av_hwdevice_ctx_create. @param flags Currently unused; should be set to zero. @return Zero on success, a negative AVERROR code on failure.