Comments (8)
You can get live video from target device using this RTSP-link (using VLC):
vlc -vvv "rtsp://xx.xx.xx.xx:554/Streaming/Channels/101?transportmode=unicast&profile=Profile_1"
or simply get media info about stream (using FFmpeg):
ffprobe -i "rtsp://xx.xx.xx.xx:554/Streaming/Channels/101?transportmode=unicast&profile=Profile_1"
or record stream to file (using FFmpeg):
ffmpeg -rtsp_transport tcp -i "rtsp://xx.xx.xx.xx:554/Streaming/Channels/101?transportmode=unicast&profile=Profile_1" -vcodec copy -preset ultrafast -analyzeduration 500000 -tune zerolatency -acodec aac -ar 44100 -ac 1 -f mp4 /path/to/file.mp4
or restream to RTMP server (broadcast to Youtube, or somewhere else) (using FFmpeg):
ffmpeg -rtsp_transport tcp -i "rtsp://xx.xx.xx.xx:554/Streaming/Channels/101?transportmode=unicast&profile=Profile_1" -vcodec copy -preset ultrafast -analyzeduration 500000 -tune zerolatency -acodec aac -ar 44100 -ac 1 -f flv "rtmp://host:1935/path"
or whatever you want.
from ponvif.
Hi. Thanks for your quick reply. However we want to display it on browser. Is it possible to stream using either PHP or Java Web servlet?
I've read from several site or community that there are no the best way to do this on browser. Is iy true?
from ponvif.
Most usable (and cross platform) way to play live video in a browser IMHO is HLS with RTMP fallback, but it uses flash player. And it needed media server, of course.
For my testing i build chain:
[IP camera] --RTSP--> [FFmpeg] --RTMP--> [Nginx RTMP module] --HLS, RTMP--> [web flash player]
Other way - WebRTC, but i have not expirity in it.
from ponvif.
Is there any references? Or maybe some example for us? I
from ponvif.
Nginx RTMP module - https://github.com/arut/nginx-rtmp-module
Complete guide (by nginx module author) - https://habrahabr.ru/post/162237/ (Russian)
Flash player with HLS support - https://github.com/denivip/StrobeMediaPlayback
FFmpeg settings above - from real build, you can use it as is.
Linux skills required.
If extremely needed i can build virtual machine (OpenVZ or VMware) with compiled software, but it takes time.
from ponvif.
I think is it very tricky, isn't it? is there any simple method? I've read from many site and it is hard to do. Very upset regarding this. However, how any CCTV VMS can generally access cctv on browser?
from ponvif.
You need a streaming server if you're using RTSP. If the camera supports RTMP, you can use Youtube to get an embed link to put into your webpage.
from ponvif.
All answers given.
from ponvif.
Related Issues (12)
- can not discover function HOT 9
- PHP4 hell HOT 1
- Discovery need multicast route HOT 1
- Discovery returns only 1 endpoint in array HOT 3
- Ask for help HOT 2
- System Upgrade Errors
- Added media_GetSnapshotUri HOT 1
- Add composer.json HOT 1
- Errors when stream url HOT 3
- Start/Stop record command HOT 2
- NVT option adds 000 to array with no index keys
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ponvif.