I am trying to show H.264 encoded rtsp video on an Android device. The stream is coming from a Raspberry Pi, using vlc to encode /dev/video1
which is a \"Pi NoI
After an amazing amount of dead-ends, I can show a H264 RTSP stream on an Android SurfaceView
. This answer is only sort of an answer because I still can't address my original three questions, but even full of bug and shortcuts as it is, my 75K apk is a lot better than Vlc for Android or the osmo4 player: It has sub-second latency (at least when the sender and the receiver are on the same wifi router!) and fills the SurfaceView
.
A few takeaways, to help anyone trying to do anything similar:
vlc
seems to always give me 01.)queueInputBuffer()
. In particular, don't try to put them in a "csd-0" buffer attached to the MediaFormat
!