453 lines
5.1 KiB
HTML
453 lines
5.1 KiB
HTML
<HTML
|
|
><HEAD
|
|
><TITLE
|
|
> Stream with VLC
|
|
|
|
</TITLE
|
|
><META
|
|
NAME="GENERATOR"
|
|
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"><LINK
|
|
REL="HOME"
|
|
TITLE="VideoLAN HOWTO"
|
|
HREF="index.html"><LINK
|
|
REL="UP"
|
|
TITLE="
|
|
Stream from an acquisition card or a webcam
|
|
|
|
"
|
|
HREF="softencoding.html"><LINK
|
|
REL="PREVIOUS"
|
|
TITLE="
|
|
|
|
Install the Video for Linux drivers
|
|
|
|
"
|
|
HREF="x980.html"><LINK
|
|
REL="NEXT"
|
|
TITLE="
|
|
Stream with VLS
|
|
|
|
"
|
|
HREF="x1074.html"></HEAD
|
|
><BODY
|
|
CLASS="sect1"
|
|
BGCOLOR="#FFFFFF"
|
|
TEXT="#000000"
|
|
LINK="#0000FF"
|
|
VLINK="#840084"
|
|
ALINK="#0000FF"
|
|
><DIV
|
|
CLASS="NAVHEADER"
|
|
><TABLE
|
|
SUMMARY="Header navigation table"
|
|
WIDTH="100%"
|
|
BORDER="0"
|
|
CELLPADDING="0"
|
|
CELLSPACING="0"
|
|
><TR
|
|
><TH
|
|
COLSPAN="3"
|
|
ALIGN="center"
|
|
>VideoLAN HOWTO</TH
|
|
></TR
|
|
><TR
|
|
><TD
|
|
WIDTH="10%"
|
|
ALIGN="left"
|
|
VALIGN="bottom"
|
|
><A
|
|
HREF="x980.html"
|
|
ACCESSKEY="P"
|
|
>Prev</A
|
|
></TD
|
|
><TD
|
|
WIDTH="80%"
|
|
ALIGN="center"
|
|
VALIGN="bottom"
|
|
>Chapter 8. Stream from an acquisition card or a webcam</TD
|
|
><TD
|
|
WIDTH="10%"
|
|
ALIGN="right"
|
|
VALIGN="bottom"
|
|
><A
|
|
HREF="x1074.html"
|
|
ACCESSKEY="N"
|
|
>Next</A
|
|
></TD
|
|
></TR
|
|
></TABLE
|
|
><HR
|
|
ALIGN="LEFT"
|
|
WIDTH="100%"></DIV
|
|
><DIV
|
|
CLASS="sect1"
|
|
><H1
|
|
CLASS="sect1"
|
|
><A
|
|
NAME="AEN988"
|
|
></A
|
|
>8.2. Stream with VLC</H1
|
|
><DIV
|
|
CLASS="note"
|
|
><P
|
|
></P
|
|
><TABLE
|
|
CLASS="note"
|
|
WIDTH="100%"
|
|
BORDER="0"
|
|
><TR
|
|
><TD
|
|
WIDTH="25"
|
|
ALIGN="CENTER"
|
|
VALIGN="TOP"
|
|
><IMG
|
|
SRC="../images/note.gif"
|
|
HSPACE="5"
|
|
ALT="Note"></TD
|
|
><TD
|
|
ALIGN="LEFT"
|
|
VALIGN="TOP"
|
|
><P
|
|
> You must add <B
|
|
CLASS="command"
|
|
>--enable-v4l</B
|
|
> to
|
|
<B
|
|
CLASS="command"
|
|
>./configure</B
|
|
> to use this feature
|
|
|
|
.</P
|
|
></TD
|
|
></TR
|
|
></TABLE
|
|
></DIV
|
|
><TABLE
|
|
BORDER="0"
|
|
BGCOLOR="#E0E0E0"
|
|
WIDTH="100%"
|
|
><TR
|
|
><TD
|
|
><FONT
|
|
COLOR="#000000"
|
|
><PRE
|
|
CLASS="screen"
|
|
>
|
|
<TT
|
|
CLASS="prompt"
|
|
>% </TT
|
|
><TT
|
|
CLASS="userinput"
|
|
><B
|
|
>vlc -vvv v4l:/dev/video:norm=secam:frequency=543250:size=640x480:channel=0:adev=/dev/dsp:audio=0
|
|
--sout '#transcode{vcodec=mp4v,acodec=mpga,vb=3000,ab=256,vt=800000,keyint=80,deinterlace}:std{access=udp,mux=ts,url=239.255.12.13}' --ttl 12</B
|
|
></TT
|
|
>
|
|
</PRE
|
|
></FONT
|
|
></TD
|
|
></TR
|
|
></TABLE
|
|
><P
|
|
>where
|
|
:</P
|
|
><P
|
|
></P
|
|
><UL
|
|
><LI
|
|
><P
|
|
><TT
|
|
CLASS="filename"
|
|
>/dev/video</TT
|
|
>
|
|
is the device corresponding to your acquisition
|
|
card or your webcam
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>norm=secam</EM
|
|
>
|
|
is name of the standard of the analogic signal
|
|
(possible values are pal, secam, and ntsc)
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>frequency=543250</EM
|
|
>
|
|
is the frequency of the channel in khz
|
|
(<EM
|
|
>Warning :</EM
|
|
> for VLC < 0.6.1, Frequency is channel
|
|
frequency in MHz multiplied by 16)
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
> <EM
|
|
>size=640x480</EM
|
|
>
|
|
is the size of the video you want (you can also put the
|
|
standard size like <EM
|
|
>subqcif</EM
|
|
> (128x96),
|
|
<EM
|
|
>qsif</EM
|
|
> (160x120), <EM
|
|
>qcif</EM
|
|
>
|
|
(176x144), <EM
|
|
>sif</EM
|
|
> (320x240), <EM
|
|
>cif</EM
|
|
>
|
|
(352x288) or <EM
|
|
>vga</EM
|
|
> (640x480))
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>channel=0</EM
|
|
>
|
|
is the number of the channel (usually 0 is for
|
|
tuner, 1 for composite and 2 for svideo)
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>adev=/dev/dsp</EM
|
|
>
|
|
is the audio device
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>audio=1</EM
|
|
>
|
|
is the number of the audio
|
|
channel (usually 0 is for mono and 1 for stereo)
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>vcodec=mp4v</EM
|
|
>
|
|
is the video format you want to encode in
|
|
(<EM
|
|
>mp4v</EM
|
|
> is MPEG-4, <EM
|
|
>mpgv</EM
|
|
> is
|
|
MPEG-1, and there is also
|
|
|
|
<EM
|
|
>h263</EM
|
|
>, <EM
|
|
>DIV1</EM
|
|
>,
|
|
<EM
|
|
>DIV2</EM
|
|
>, <EM
|
|
>DIV3</EM
|
|
>,
|
|
<EM
|
|
>I420</EM
|
|
>, <EM
|
|
>I422</EM
|
|
>,
|
|
<EM
|
|
>I444</EM
|
|
>, <EM
|
|
>RV24</EM
|
|
>,
|
|
<EM
|
|
>YUY2</EM
|
|
>),</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>acodec=mpga</EM
|
|
>
|
|
is the audio format you want to encode
|
|
in (<EM
|
|
>mpga</EM
|
|
> is MPEG audio layer 2,
|
|
<EM
|
|
>a52</EM
|
|
> is A52 i.e. AC3 sound)
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>vb=3000</EM
|
|
>
|
|
is the video bitrate in Kbit/s
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>ab=256</EM
|
|
>
|
|
is the audio bitrate in Kbit/s
|
|
|
|
</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>vt=800000</EM
|
|
>
|
|
is the video bitrate tolerance in bit/s
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>keyint=80</EM
|
|
>
|
|
is the maximum interval between two "I" images in
|
|
number of images
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>deinterlace</EM
|
|
>
|
|
tells VLC to deinterlace the video on the fly
|
|
|
|
,</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>192.168.0.42</EM
|
|
>
|
|
is either
|
|
|
|
:</P
|
|
><P
|
|
></P
|
|
><UL
|
|
><LI
|
|
><P
|
|
> the IP address of the machine you want to unicast
|
|
to
|
|
|
|
;</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
> or the DNS name the machine you want to unicast
|
|
to
|
|
|
|
;</P
|
|
></LI
|
|
><LI
|
|
><P
|
|
> or a multicast IP address
|
|
|
|
.</P
|
|
></LI
|
|
></UL
|
|
></LI
|
|
><LI
|
|
><P
|
|
><EM
|
|
>12</EM
|
|
>
|
|
is the value of the TTL (Time To
|
|
Live) of your IP packets (which means that the stream will be
|
|
able to cross 11 routers)
|
|
|
|
.</P
|
|
></LI
|
|
></UL
|
|
></DIV
|
|
><DIV
|
|
CLASS="NAVFOOTER"
|
|
><HR
|
|
ALIGN="LEFT"
|
|
WIDTH="100%"><TABLE
|
|
SUMMARY="Footer navigation table"
|
|
WIDTH="100%"
|
|
BORDER="0"
|
|
CELLPADDING="0"
|
|
CELLSPACING="0"
|
|
><TR
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="left"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="x980.html"
|
|
ACCESSKEY="P"
|
|
>Prev</A
|
|
></TD
|
|
><TD
|
|
WIDTH="34%"
|
|
ALIGN="center"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="index.html"
|
|
ACCESSKEY="H"
|
|
>Home</A
|
|
></TD
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="right"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="x1074.html"
|
|
ACCESSKEY="N"
|
|
>Next</A
|
|
></TD
|
|
></TR
|
|
><TR
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="left"
|
|
VALIGN="top"
|
|
>Install the Video for Linux drivers</TD
|
|
><TD
|
|
WIDTH="34%"
|
|
ALIGN="center"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="softencoding.html"
|
|
ACCESSKEY="U"
|
|
>Up</A
|
|
></TD
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="right"
|
|
VALIGN="top"
|
|
>Stream with VLS</TD
|
|
></TR
|
|
></TABLE
|
|
></DIV
|
|
></BODY
|
|
></HTML
|
|
> |