项目作者: ramsafin

项目描述 :
RTSP video streaming server implementation based on Live555 and FFmpeg
高级语言: C++
项目地址: git://github.com/ramsafin/rtsp-video-server.git
创建时间: 2018-05-16T13:23:54Z
项目社区:https://github.com/ramsafin/rtsp-video-server

开源协议:MIT License

下载


RTSP Video Streaming

Prerequisites

  • Ubuntu 16.04
  • GCC (gcc and g++) ver. 5.4
  • USB camera (v4l2 compatible)

Getting Started

Clone the repository:

  1. git clone https://github.com/ramilsafnab1996/rtsp-video-server.git
  2. git submodule update --init
  3. cd rtsp-video-server

Dependencies

Install the dependencies (using apt package manager):

  1. sudo apt-get install liblog4cpp5-dev

Install the dependencies from the contrib:

  1. cd contrib
  2. # Live555 video streaming server framework
  3. cd live && ./genMakefiles linux-64bit && make -j$(nproc)
  4. cd ../..

The most time- and nerve-consuming part, installing FFMpeg …:

cd into the scripts directory (prepared bash scripts for installation):

  1. cd scripts && chmod +x *
  2. ./install_ffmpeg_with_deps.sh
  3. cd ..

Build

  1. mkdir build
  2. cd build
  3. cmake -DCMAKE_BUILD_TYPE=RELEASE ..
  4. make -j$(nproc)

Run

Edit config.yaml for your needs.

Then you can run the server:

  1. ./video_server ../config.yaml

Testing

For simple testing whether the server works or not you can use MPlayer (preferred) or VLC:

  1. sudo apt install mplayer
  2. mplayer -benchmark rtsp://<ip address>:8554/webcam_0

Limitations

  • Currently there is no support for the already compressed raw camera formats (e.g. MJPEG). In this case we have 2 options: send the data as it is (e.g. MJPEG stream) or transcode the original video stream into the format we need (e.g. H.264).
  • Lack of control of camera parameters (fps, resolution, etc.) at runtime (no API for that is provided).
  • RTSP multicast broadcasting is not supported (It can be implemted using Live555 API).
  • SSL is not supported (see SRTP).