com.ant-automation.antcity.video.streaming.client
v1.0.4
Published
Multiple streaming protocol support based on CameraReceiverServer.
Downloads
3
Readme
SteramingReceiverServer Unity client
Receive rtsp and mjpg video stremaing protocols in unity Texture2D.
USE
Client
- Add UI RawImage gameobject to scene
- Create empty gameobject
- Add CameraReceiverMemory Component to empty gameobject
- Set Cameras Size to number of received streaming cameras (example 1)
- Set Cameras Elements
5.1. Set RawImage created in (2) to Camera Source
5.2. Set streaming camera size (example X:640 Y:480)
CameraReceiverServer
- Clone streaming.receiver.server Console C# project.
- Edit
cameraConfig.json
to receive streaming. Example:
{
"MemoryFile": "CameraReceiveStream",
"CameraIP": [
"127.0.0.1",
],
"CameraPort": [ 10000],
"Protocol": [ "rtsp"]
}
Protocol: "rtsp" or " http".
- Run project
rtsp Emitting Application
Create an Unity Scene and follow the instruction at rtsp.h264.streaming.server
ReplicANT Emitting Application
You can combine rtsp and ReplicANT Camera Server streaming.
To receive a ReplicaANT Camera Server stremings:
- set
"Protocol": [ "http"]
incameraConfig.json
file - Set the proper streaming camera size in client application
- Run ReplicANT with CameraServer plugin
- Run the ReplicANT Unity application with security cameras.
You can download ReplicANT here
Execution
(3.) Client (2.) CameraReceiverServer (1.) rtsp Emitting App
Unity App Memory File Console App ╔══════════╗
╔════════════════════╗Camera[0]┌─────────────────────┐ ╔═════════════════════════╗ Streaming[0]┌╢ Server ║
║ GameObject With ╟─────────┤ ├─╢ ╟ ─ ─ ─ ─ ─ ─ ┘╚══════════╝
║CameraReceiverMemory║ │"CameraReceiveStream"│ ║streaming.Receiver.server║ (1.) ReplicANT Unity
║ Component ╟─────────┤ ├─╢ ╟ ─ ─ ─ ─ ─ ─ ┐╔════════════╗ ┌─┐ ╔════════════╗
╚════════════════════╝Camera[n]└─────────────────────┘ ╚═════════════════════════╝ Streaming[n]└╢CameraServer╟─┤ ├─╢Emitting App║
╚════════════╝ └─┘ ╚════════════╝
- Run Emitting Application (and ReplicANT if it is necesary)
- Run CameraReceiverServer
- Run Client Application