Go to file
2012-04-11 17:23:40 +04:00
doc implement ext timestamp fix to make flash client recognize 32-bit timestamps 2012-03-22 01:00:52 +04:00
test added example nginx.conf 2012-04-11 17:23:40 +04:00
AUTHORS improved frame timing & added meta files 2012-03-20 03:52:39 +04:00
config added more flags & extended types to AMF 2012-03-30 19:07:14 +04:00
LICENSE improved frame timing & added meta files 2012-03-20 03:52:39 +04:00
ngx_rtmp.c implemented amf_create & fixed memory keak 2012-04-05 14:58:10 +04:00
ngx_rtmp.h added more features to recorder 2012-04-11 17:07:06 +04:00
ngx_rtmp_access_module.c reimplemented amf0 callbacks from arrays to chains to enable async processing 2012-03-27 20:26:43 +04:00
ngx_rtmp_amf.c fixed crash in amf reader 2012-04-11 17:23:23 +04:00
ngx_rtmp_amf.h added more flags & extended types to AMF 2012-03-30 19:07:14 +04:00
ngx_rtmp_cmd_module.c changed char* to ngx_str_t in AMF declarations 2012-03-29 16:51:17 +04:00
ngx_rtmp_cmd_module.h adjusted AMF arg sizes to reasonable values 2012-03-30 19:10:01 +04:00
ngx_rtmp_core_module.c implemented chunk size change 2012-04-05 21:28:41 +04:00
ngx_rtmp_handler.c implemented deferred session close 2012-04-08 01:44:57 +04:00
ngx_rtmp_live_module.c added more features to recorder 2012-04-11 17:07:06 +04:00
ngx_rtmp_netcall_module.c implemented deferred session close 2012-04-08 01:44:57 +04:00
ngx_rtmp_netcall_module.h added more flags & extended types to AMF 2012-03-30 19:07:14 +04:00
ngx_rtmp_notify_module.c added more flags & extended types to AMF 2012-03-30 19:07:14 +04:00
ngx_rtmp_receive.c implemented chunk size change 2012-04-05 21:28:41 +04:00
ngx_rtmp_record_module.c added more features to recorder 2012-04-11 17:07:06 +04:00
ngx_rtmp_send.c fixed memleak in AMF sender 2012-04-07 22:59:25 +04:00
ngx_rtmp_shared.c implemented frame dropping 2012-03-18 17:09:19 +04:00
README added one-worker note 2012-04-11 09:23:58 +04:00
TODO updated README & TODO 2012-04-09 15:59:12 +04:00

== nginx-rtmp-module ==

NGINX-based RTMP server

* Live streaming of video/audio

* Recording published streams in FLV file

* HTTP callbacks on publish/play/record

* Advanced buffering techniques
  to keep memory allocations at a minimum
  level for faster streaming and low
  memory footprint

* Works with Flash RTMP clients as well as
  ffmpeg/rtmpdump/flvstreamer etc
  (see examples in test/ subdir)


Build:

cd to NGINX source directory & run this:

./configure --add-module=<path-to-nginx-rtmp-module>
make
make install


Note the module does not share data between workers
and only works in one-worker mode. 


RTMP URL format:

rtmp://rtmp.example.com/<app>[/<name>]

<app> -  should match one of application {}
         blocks in config
<name> - interpreted by each application
         can be empty


Example nginx.conf:

rtmp {

    server {

        listen 1935;

        chunk_size 128;

        max_buf 1000000;

        # TV mode: one publisher, many subscribers
        application mytv {

            # enable live streaming
            live on;

            # record flvs to this dir
            record /tmp/av;

            # max flv size
            record_size 3000000;

            # publish only from localhost
            allow publish 127.0.0.1;
            deny publish all;

            #allow play all;
        }

        # Many publishers, many subscribers
        # no checks, no recording
        application videochat {

            live on;

            # The following notifications receive all 
            # the session variables as well as 
            # particular call arguments in HTTP POST
            # request

            # Make HTTP request & use HTTP retcode
            # to decide whether to allow publishing
            # from this connection or not
            on_publish http://localhost:8080/publish;

            # Same with playing
            on_play http://localhost:8080/play;

            # Async notify about an flv recorded
            on_record_done http://localhost:8080/record_done;

        }

    }
}