connect Send Transport Screen
Connects the send transport for screen sharing by producing screen data and updating the local screen producer and transport.
This function sets up and connects the screen stream for media sharing, handling updates to local screen streams and producer transports.
Features:
Handles screen track management
Manages screen capture constraints
Sets up stream and track management
Handles transport production for screen sharing
Updates screen producer state
Parameters:
options Configuration options for screen transport connection
Returns:
Example Usage:
val screenOptions = ConnectSendTransportScreenOptions(
stream = myScreenStream,
targetOption = "all",
parameters = myConnectSendTransportScreenParameters
)
val result = connectSendTransportScreen(screenOptions)
result.onSuccess {
}
result.onFailure { error ->
Logger.e("ConnectSendTransport", "Error setting up screen stream: ${error.message}")
}Content copied to clipboard
Error Handling:
Returns Result.failure if required parameters are missing
Logs errors for debugging
Handles transport creation failures gracefully