Search code examples
video-streamingred5jwplayerrtmp

How do I play a video using Red5?


I had my hosting company install Red5 on my server and they sent me the address and the ports for the RMS and RMS HTTP protocols. So how do I actually upload a video and embed it in a webpage for playback? Is there a premade application I can use or do I have to create one myself? I can't find anything in the documentation but development code.

Edit: Looks like I can use JWPlayer to play the videos via RTMP. Is there a specific folder I need to upload the videos to, or can I put them anywhere on the Red5 server e.g. rtmp://myip/red5/myvideos/video1.mp4 ?

Edit: I've added the Video Whisper application to my webapps directory and moved the file to the videowhisperstreams directory, but still no luck (the JWPlayer shows, but the server can't be found) Here's my code:

<div id='mediaspace'>This text will be replaced</div>

<script type='text/javascript'>
  jwplayer('mediaspace').setup({
  'flashplayer': 'jwplayer/player.swf',
  'file': 'test.flv',
  'streamer': 'rtmp://myip/videowhisper',
  'controlbar': 'bottom',
  'width': '470',
  'height': '290'
});
</script>

Solution

  • I figured it out. The above script does work, but I was uploading the app and video to /root/red5/webapps instead of <root>/opt/red5/webapps