Multicam is a simple Python application consisting of HTTP server, hub and client. Its goal is to send frames captured from webcamera on device running client script to hub, which modifies received frames adding details about client's name, current timestamp and client's ordinal number starting from 1. Server constantly pops made by hub frames and send them through HTTP to be available for watch in web browser or e.g. VLC.
- Python 3.8 installed on your system,
- required dependencies installed - to install them, run
pip install -r requirements.txtcommand in project directory
- server:
python3 server/server.py -h
usage: server.py [-h] [-p PORT]
optional arguments:
-h, --help show this help message and exit
-p PORT, --port PORT Port on which server starts
- hub:
python3 hub/hub.py -h
usage: hub.py [-h] [-r ROWS] [-c COLS] [-d]
optional arguments:
-h, --help show this help message and exit
-r ROWS, --rows ROWS No. of rows created in resulting stream, default = 2
-c COLS, --cols COLS No. of columns created in resulting stream, default = 2
-d, --dynamic Enable dynamic resizing resulting video stream basing on clients count
- client:
python3 client/client.py -h
usage: client.py [-h] [-ip SERVERIP] [-n NAME]
optional arguments:
-h, --help show this help message and exit
-ip SERVERIP, --serverip SERVERIP
ip address of streaming server
-n NAME, --name NAME Name of client which will be printed on streamed video, default = [{hostname}/{IP}]
Example montage made by combining frames from 6 clients (with covered up webcameras 🕵️):
python .\server\server.pyto start http serverpython .\hub\hub.pyto start hub which intermediates between client and serverpython .\client\client.pyto start client which captures image from camera- Open stream: http://localhost:4000 in your browser or e.g. using VLC program
- Python 3.8
- ImageZMQ 1.1.1
- imutils 0.5.4
- OpenCV 4.5.1.48
- Flask 1.1.2
