unosquare / ffmediaelement

FFME: The Advanced WPF MediaElement (based on FFmpeg)
https://unosquare.github.io/ffmediaelement/
Other
1.17k stars 241 forks source link

Can't play h264 video stream transmitted from socket #621

Open RDPCoder opened 2 years ago

RDPCoder commented 2 years ago

Can't play h264 video stream transmitted from socket

I need to use mediaelement to play the h264 video stream transmitted from the socket. Although I customized IMediaInputStream, it still cannot be played. It seems that IMediaInputStream can only read from the file but not from the socket. Because I found that if I don't set the StreamUri property, then Read and Seek will not be called, but the h264 video stream is transmitted from the socket, and he has no url

Issue Categories

Sample Code

XAML

    <ffme:MediaElement x:Name="Media" Background="Gray" LoadedBehavior="Play" UnloadedBehavior="Manual" />

C

        Media.Open(new H264InputStream(_h264StreamPipe.Reader));