Closed TheFe91 closed 1 year ago
More logs:
E/RtmpProducer(28643): java.net.SocketException: Connection error
E/RtmpProducer(28643): at video.api.rtmpdroid.Rtmp.write(Rtmp.kt:139)
E/RtmpProducer(28643): at io.github.thibaultbee.streampack.ext.rtmp.internal.endpoints.RtmpProducer.write(RtmpProducer.kt:94)
E/RtmpProducer(28643): at io.github.thibaultbee.streampack.streamers.bases.BaseStreamer$muxListener$1.onOutputFrame(BaseStreamer.kt:132)
E/RtmpProducer(28643): at io.github.thibaultbee.streampack.internal.muxers.flv.FlvMuxer.encode(FlvMuxer.kt:77)
E/RtmpProducer(28643): at io.github.thibaultbee.streampack.streamers.bases.BaseStreamer$videoEncoderListener$1.onOutputFrame(BaseStreamer.kt:120)
E/RtmpProducer(28643): at io.github.thibaultbee.streampack.internal.encoders.MediaCodecEncoder$encoderCallback$1.onOutputBufferAvailable(MediaCodecEncoder.kt:109)
E/RtmpProducer(28643): at android.media.MediaCodec$EventHandler.handleCallback(MediaCodec.java:1854)
E/RtmpProducer(28643): at android.media.MediaCodec$EventHandler.handleMessage(MediaCodec.java:1752)
E/RtmpProducer(28643): at android.os.Handler.dispatchMessage(Handler.java:106)
E/RtmpProducer(28643): at android.os.Looper.loopOnce(Looper.java:226)
E/RtmpProducer(28643): at android.os.Looper.loop(Looper.java:313)
E/RtmpProducer(28643): at android.os.HandlerThread.run(HandlerThread.java:67)
Just tried with Android emulator (Pixel 6A API 33) and it works... I really don't understand, I'm astonished
I tried from my app to stream over my youtube channel and it worked. So it must be something related to my app + mux...From the example app + mux however it worked as I wrote above. Hope these details help!
I think I solved the problem. I was missing the scaffoldKey
from the main Scaffold, so it probably had a re-render that caused an error within StreamPack.
Closing
Version
v1.1.1
Which operating systems have you used?
Environment that reproduces the issue
Is it reproducible in the example application?
No
RTMP Server
MUX
Reproduction steps
await apiVideoLiveStreamController.initialize();
await apiVideoLiveStreamController.startStreaming( streamKey: sc.currentStreamKey.value!, url: Strings.muxBaseRtmpUrl, );
Flutter 3.10.3 • channel stable • https://github.com/flutter/flutter.git Framework • revision f92f44110e (5 days ago) • 2023-06-01 18:17:33 -0500 Engine • revision 2a3401c9bb Tools • Dart 3.0.3 • DevTools 2.23.1