<div dir="ltr"><div>Hello folks. I'm building an Android app that needs to play mjpeg video. So far I've been able to successfully get the video playing on the Android device following the tutorial here <a href="https://cgit.freedesktop.org/~slomo/gst-sdk-tutorials/tree/gst-sdk/tutorials/android-tutorial-5/">https://cgit.freedesktop.org/~slomo/gst-sdk-tutorials/tree/gst-sdk/tutorials/android-tutorial-5/</a> . That said, right now I'm seeing it take roughly 5 seconds to get the video playback started. To be very specific, in the `gst_native_play` function in that tutorial there is a call to `gst_element_set_state`. I've modified the code, splitting the lines apart so I capture the GstStateChangeReturn value being returned from that call. This result is a GST_STATE_CHANGE_ASYNC. Then, I call `gst_element_get_state` on the pipeline (which blocks until the actual result is available). By the time that function call returns, roughly 5 seconds have gone by since we originally called `gst_element_set_state`. The specific line that I'm talking about (the one I broke apart into separate lines) is this one: <a href="https://cgit.freedesktop.org/~slomo/gst-sdk-tutorials/tree/gst-sdk/tutorials/android-tutorial-5/jni/tutorial-5.c#n457">https://cgit.freedesktop.org/~slomo/gst-sdk-tutorials/tree/gst-sdk/tutorials/android-tutorial-5/jni/tutorial-5.c#n457</a></div><div><br></div><div>More details about the stream. It's a live mjpeg stream playing off of a local network (not public internet). I'd like to decrease this 5s figure as much as I can so that video playback begins sooner. Can anyone point me in the right direction on how I'd go about doing that? </div><div><br></div><div>Thanks in advance,</div><div>Bryan</div></div>