0

i'm using nodejs and react (both with typescript) and i'm trying to get the video from an IP Camera through RTSP,

i tried using node-rtsp-stream but this library uses jsmpeg as a consumer in the front-end and it does not work with react & typescript.

i need some recommandations or other solutions

redd_d0gg
  • 1
  • 3
  • you may review accepted ans - https://stackoverflow.com/questions/23011302/best-approach-to-get-rtsp-streaming-into-web-browser-from-ip-camera AND consider a back-end piece to coordinate the stream for the react piece – Robert Rowntree Mar 19 '21 at 13:31
  • i already tried to use the jsmpeg in my front-end code but i alway got type errors. Is there a way to use a readableStream after getting the stream from RTSP ? – redd_d0gg Mar 20 '21 at 08:46
  • well look at - https://www.npmjs.com/package/media-stream-player. seems appropiate to your components. OR... with a stream, if you need to u can look into wrappering the stream in a pipe . with a pipe , any of the players should work. they all accept piped input using the CLI "-" in place of input file – Robert Rowntree Mar 20 '21 at 12:16
  • thanks, i'm going to try this one – redd_d0gg Mar 22 '21 at 06:32

1 Answers1

0

I have an idea that we can transfer the RTSP to HTTP format(like HLS) first, then many of the video players and js libraries are able to play it.

wiwengweng
  • 352
  • 1
  • 4
  • 16