update command line description in README + print HLS/MPEG-DASH url

pull/33/head
mpromonet 8 years ago
parent 1a53adc870
commit c29cef007e

@ -79,7 +79,7 @@ This workflow could be set using :
Usage
-----
./h264_v4l2_rtspserver [-v[v]] [-Q queueSize] [-O file] \
[-I interface] [-P RTSP port] [-T RTSP/HTTP port] [-m multicast url] [-u unicast url] [-M multicast addr] [-c] [-t timeout] \
[-I interface] [-P RTSP port] [-p RTSP/HTTP port] [-m multicast url] [-u unicast url] [-M multicast addr] [-c] [-t timeout] \
[-r] [-s] [-W width] [-H height] [-F fps] [device1] [device2]
-v : verbose
-vv : very verbose
@ -88,16 +88,20 @@ Usage
RTSP options :
-I addr : RTSP interface (default autodetect)
-P port : RTSP port (default 8554)
-T port : RTSP over HTTP port (default 0)
-p port : RTSP over HTTP port (default 0)
-u url : unicast url (default unicast)
-m url : multicast url (default multicast)
-M addr : multicast group:port (default is random_address:20000)
-c : don't repeat config (default repeat config before IDR frame)
-t secs : RTCP expiration timeout (default 65)
-T : send Transport Stream instead of elementary Stream
-S secs : HTTP segment duration (enable HLS & MPEG-DASH)
V4L2 options :
-r : V4L2 capture using read interface (default use memory mapped buffers)
-w : V4L2 capture using write interface (default use memory mapped buffers)
-s : V4L2 capture using live555 mainloop (default use a separated reading thread)
-f : V4L2 capture using current format (-W,-H,-F are ignored)
-f : V4L2 capture using current capture format (-W,-H,-F are ignored)
-fformat : V4L2 capture using format (-W,-H,-F are used)
-W width : V4L2 capture width (default 640)
-H height: V4L2 capture height (default 480)
-F fps : V4L2 capture framerate (default 25)

@ -173,7 +173,7 @@ int main(int argc, char** argv)
bool repeatConfig = true;
int timeout = 65;
bool muxTS = false;
unsigned int hlsSegment = 10;
unsigned int hlsSegment = -1;
// decode parameters
int c = 0;
@ -230,7 +230,7 @@ int main(int argc, char** argv)
std::cout << "\t -w : V4L2 capture using write interface (default use memory mapped buffers)"<< std::endl;
std::cout << "\t -s : V4L2 capture using live555 mainloop (default use a reader thread)" << std::endl;
std::cout << "\t -f : V4L2 capture using current capture format (-W,-H,-F are ignored)" << std::endl;
std::cout << "\t -f format : V4L2 capture using format (-W,-H,-F are used)" << std::endl;
std::cout << "\t -fformat : V4L2 capture using format (-W,-H,-F are used)" << std::endl;
std::cout << "\t -W width : V4L2 capture width (default "<< width << ")" << std::endl;
std::cout << "\t -H height : V4L2 capture height (default "<< height << ")" << std::endl;
std::cout << "\t -F fps : V4L2 capture framerate (default "<< fps << ")" << std::endl;
@ -351,9 +351,13 @@ int main(int argc, char** argv)
}
// Create Unicast Session
if (muxTS)
if (hlsSegment > 0)
{
addSession(rtspServer, baseUrl+url, HLSServerMediaSubsession::createNew(*env,replicator,rtpFormat, hlsSegment));
struct in_addr ip;
ip.s_addr = ourIPAddress(*env);
LOG(NOTICE) << "HLS http://" << inet_ntoa(ip) << ":" << rtspPort << baseUrl+url << ".m3u8";
LOG(NOTICE) << "MPEG-DASH http://" << inet_ntoa(ip) << ":" << rtspPort << baseUrl+url << ".mpd";
}
else
{

Loading…
Cancel
Save