GithubHelp home page GithubHelp logo

a4tunado / crtmpserver Goto Github PK

View Code? Open in Web Editor NEW
29.0 7.0 5.0 6.21 MB

This project is known by the name crtmpserver or rtmpd

Home Page: http://rtmpd.com/

License: GNU General Public License v3.0

Java 0.57% PHP 1.07% Lua 1.30% JavaScript 1.92% Shell 2.57% ActionScript 3.68% C 37.55% C++ 51.34%

crtmpserver's Introduction

Instructions how to compile and use C++ RTMP Server (a.k.a crtmpserver)

Requirements:
* GCC and other C++ tools
* SVN
* libdl, libssl, libcrypto
(make sure you have the "devel" packages of libdl, ssl and crypto installed prior to compiling)

In order to get the source code, issue the following command:

svn co --username anonymous https://svn.rtmpd.com/crtmpserver/trunk crtmpserver
When it asks for password, hit Enter key

Compile the package. Do the following steps:

cd crtmpserver/builders/cmake
cmake .

(this step will create all the Makefile's that are required. If some package is missing, the cmake will complain)

make

The compilation procedure should be finished within few minutes.

After you compiled the package, it's time to test it. Run the following command:

./crtmpserver/crtmpserver crtmpserver/crtmpserver.lua

If everything goes well, you'll get on your console a table with IP's, ports, protocols, and application names
If you see this table, then crtmpserver  is working.

Lets test it the server. Follow these simple steps:

* Download a simple FLV or MP4 file. You can dowload a sample file from here: http://www.mediacollege.com/adobe/flash/video/tutorial/example-flv.html
* Place the file you downloaded into the crtmpserver/media folder
* Download an FLV player. For this example, we'll use JW Player. Get it here: http://www.longtailvideo.com/players/jw-flv-player
* Extract the JW Player to a directory which is accessible through your web server
* Go to the extracted directory and create an HTML file which will include the player and play the file. Here's an example:

<html>
<body>
<script type='text/javascript' src='swfobject.js'></script>

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

<script type='text/javascript'>
  var so = new SWFObject('player.swf','mpl','640','360','9');
  so.addParam('allowfullscreen','true');
  so.addParam('allowscriptaccess','always');
  so.addParam('wmode','opaque');
  so.addVariable('file','file-download');
  so.addVariable('streamer','rtmp://127.0.0.1/flvplayback/');
  so.write('mediaspace');
</script>
</body>
</html>

* Change the 127.0.0.1 to either the IP of your crtmpserver or simply use a hostname of your machine
* Replace file-download with the actual filename of your sample you download. Remeber to omit the .flv if it's an FLV file
* Open a web browser and point it to to the web server IP/Hostname and the directory you installed the player
(example: http://127.0.0.1/player)
* You should see a player. Click the play button and the video should be played.

If you see the video, then everything works well.

Installing crtmpserver:

* Go to the directory crtmpserver/cmake
* Run the following command: cmake -DCRTMPSERVER_INSTALL_PREFIX=<path> (for example /usr/local/crtmpserver)
* After previous command done start build project with command: make
* After build comlete run command: make install
* After install you has installed crtmpserver in <path>(in our case /usr/local/crtmpserver)
* Now you can start crtmpserver with command: 
	sudo <path>/sbin/crtmpserver --uid=<UID> <path>/etc/crtmpserver.lua
  in our case:
	sudo /usr/local/crtmpserver/sbin/crtmpserver --uid=<UID> /usr/local/crtmpserver/etc/crtmpserver.lua

Also look into builders/packing directory. There are several OS specific builders.
* in directory "debian" builder for Debian, also can be used for Ubuntu and other distributions based on debian
* in directory "freebsd" builder(port) for FreeBSD

crtmpserver settings
* All crtmpserver settings are located in a detailed file calle: crtmpserver.lua

Support/Help:
If you're lookingo for assistance with crtmpserver, feel free to join us at:
http://groups.google.com/group/c-rtmp-server

Credits:
* crtmpserver written by: Gavriloaie Eugen-Andrei
* Documentation (this file): Hetz Ben Hamo, Andriy Beregovenko
* TinyXML: Lee Thomason
* lua: Roberto Ierusalimschy, Waldemar Celes, Luiz Henrique de Figueiredo
* Performance: Vlad Galu
* Protocols: Mircea Danila Dumitrescu

crtmpserver's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.