Stream on own website.

858 views
Skip to first unread message

Avon de Tade

unread,
Jun 18, 2021, 2:13:00 AM6/18/21
to MonaServer
Hey i just starting with streaming on the Internet. Now i tried to get my  own livestream on my website, without using any other Provider, i just want to do it on my own. So not Youtube, twich or somethink like that. I tried many casting Programs like manycam, obs etc. I i stucked on XSplit.
I Youse Xsplit to send the videosignal to Monaserver.
That works. If i use the VLC Player ic can see my Videosignal. It looks great und it is fast. URL: rtmp://localhost/123/123
Now i want to bring that on my website. I read soame pages on the internet an it seams to be reliseable with video.js.

So i tried a lot of thinks, but i will not work with my URL:
rtmp://localhost/123/123

Can someone knwo how to realise that an give me an example code for that ?
Like:  <source src="rtmp://localhost/123/123" type="rtmp/mp4">

THX for help Avon

MonaServer

unread,
Jun 18, 2021, 12:53:25 PM6/18/21
to MonaServer
Hi Avon!

RTMP is not supported anymore by Videojs and in general in the browser since Flash is no more available. But you can use HTTP to play your stream.

If you have a publication named "123" in MonaServer2 you can play it with videojs using the following html file for example :

<html>
<head>
    <link href="https://vjs.zencdn.net/7.11.4/video-js.css" rel="stylesheet" />
  
    <!-- If you'd like to support IE8 (for Video.js versions prior to v7) -->
    <!-- <script src="https://vjs.zencdn.net/ie8/1.1.2/videojs-ie8.min.js"></script> -->
  </head>
  
  <body>
    <video
      id="my-video"
      class="video-js"
      controls
      preload="auto"
      width="640"
      height="264"
      poster="MY_VIDEO_POSTER.jpg"
      data-setup="{}"
    >
      <source src="Sintel.mp4" type="video/mp4" />
      <p class="vjs-no-js">
        To view this video please enable JavaScript, and consider upgrading to a
        web browser that
        <a href="https://videojs.com/html5-video-support/" target="_blank"
          >supports HTML5 video</a
        >
      </p>
    </video>
  
    <script src="https://vjs.zencdn.net/7.11.4/video.min.js"></script>
  </body>
</html>

Note that you can also play the video using VLC with the url http://localhost/123.mp4

I hope it will help you

Regards

Thomas

Avon de Tade

unread,
Jun 19, 2021, 12:16:50 AM6/19/21
to MonaServer
Hello Thomas, a lot of thanks for your fasat replay. 
First of all i have to say,that i found a way with "nginx" and "HLS" that worked for me. 

The information that you give mit, that RTMP is not supported any more by video.jx is great. I google for a few hours and i found no way to do it without flash. 

I do not know, if understand you example. But i think that will just work with a recorded file and not with a livestream ? I want to stream a webcam or my desktop in realtime. 

Perhaps there a a few configuration files missing for Monaserver, that it works. I just testet MonyTiny. That isjust an EXE file with no Configuration. So i iave no ideo what i have to do to config that. But all fine, i will go on with the Nginx thing. 

Thx for you help.
Avon

Thomas Jammet

unread,
Jun 19, 2021, 3:37:04 AM6/19/21
to Avon de Tade, MonaServer
Hi Avon,

It's fine if you have found a solution, there is always many ones for the same problem ;-)

MonaServer (or MonaTiny) is built for realtime streaming. Our main goal is to share streams with different protocols in a generic way, without configuration or plugin.

So definitely you can publish your stream with Xsplit in RTMP (or another protocol) to MonaServer and then you will be able to play the stream from MonaServer using one of our supported protocols (RTMP, RTMFP, HTTP, HLS, WebSocket, SRT).

With HTTP (progressive download) there is a useful trick, when you you want to play a stream named "test123" you can add one of the following extensions :
.ts
.mp4
.flv 
So for example to play test123 from vlc in MP4 format you write the url http://localhost/test123.mp4

That's all, you don't need any configuration

There are other useful features and some configuration which you can find in the MonaServer.ini example. Let us know if you have other questions.

Regards


--
You received this message because you are subscribed to a topic in the Google Groups "MonaServer" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/monaserver/AgZgOMDx5Ig/unsubscribe.
To unsubscribe from this group and all its topics, send an email to monaserver+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/monaserver/14867233-94f8-4eef-b475-5b469eecca4dn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages