old-www/HOWTO/VideoLAN-HOWTO/x867.html

501 lines
6.5 KiB
HTML

<HTML
><HEAD
><TITLE
>&#13;
Stream with the Hauppauge WinTV-PVR-250 card
</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 MPEG encoding card
"
HREF="hardencoding.html"><LINK
REL="PREVIOUS"
TITLE="
Stream from an MPEG encoding card
"
HREF="hardencoding.html"><LINK
REL="NEXT"
TITLE="
Stream with the Visiontech Kfir card
"
HREF="x932.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="hardencoding.html"
ACCESSKEY="P"
>Prev</A
></TD
><TD
WIDTH="80%"
ALIGN="center"
VALIGN="bottom"
>Chapter 7. Stream from an MPEG encoding card</TD
><TD
WIDTH="10%"
ALIGN="right"
VALIGN="bottom"
><A
HREF="x932.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
></TABLE
><HR
ALIGN="LEFT"
WIDTH="100%"></DIV
><DIV
CLASS="sect1"
><H1
CLASS="sect1"
><A
NAME="AEN867"
></A
>7.1. Stream with the Hauppauge WinTV-PVR-250 card</H1
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="AEN869"
></A
>7.1.1. Install the drivers</H2
><P
>&#13;First, you will have to patch your kernel to support
the v4l2 API (Video 4 Linux version 2). The patch is available on the
<A
HREF="http://bytesex.org/v4l/"
TARGET="_top"
>Video4Linux HQ</A
>
.</P
><P
>&#13;Once your kernel is ready, install the CVS version
of the Linux drivers for the Hauppauge WinTV-PVR-250. They are hosted on
<A
HREF="http://ivtv.sourceforge.net/"
TARGET="_top"
>ivtv.sourceforge.net</A
>.
Then, you will have to create the device and load the modules; for this,
please refer to the documentation shipped with the drivers
.</P
></DIV
><DIV
CLASS="sect2"
><H2
CLASS="sect2"
><A
NAME="AEN875"
></A
>7.1.2. Stream with VLC</H2
><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
>&#13;You must add <B
CLASS="command"
>--enable-pvr</B
>
to <B
CLASS="command"
>./configure</B
> to use this
feature. You may want to change the value of
<EM
>CR_MAX_AVERAGE_COUNTER</EM
> to <EM
>1000</EM
>
in <TT
CLASS="filename"
>src/input/input_clock.c</TT
> to work around a problem
with the card
.</P
></TD
></TR
></TABLE
></DIV
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>% </TT
><TT
CLASS="userinput"
><B
>vlc -vvv pvr:/dev/video0:norm=secam:size=720x576:frequency=576250:
bitrate=3000000:maxbitrate=4000000 --sout udp:192.168.0.42 --ttl 12</B
></TT
>
</PRE
></FONT
></TD
></TR
></TABLE
><P
>where
:</P
><P
></P
><UL
><LI
><P
><EM
>/dev/video0</EM
>
is the device corresponding to the encoding card
,</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
>size=720x576</EM
>
is the size of the video you want to stream
,</P
></LI
><LI
><P
><EM
>frequency=567250</EM
>
is the frequency in kHz of the channel you want to
stream
,</P
></LI
><LI
><P
><EM
>bitrate=3000000</EM
>
is the average bitrate of the stream
,</P
></LI
><LI
><P
><EM
>maxbitrate=4000000</EM
>
is the maximum bitrate of the stream
,</P
></LI
><LI
><P
><EM
>192.168.0.42</EM
>
is either
:</P
><P
></P
><UL
><LI
><P
>&#13;the IP address of the machine you want to unicast
to
;</P
></LI
><LI
><P
>&#13;or the DNS name the machine you want to unicast
to
;</P
></LI
><LI
><P
>&#13;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="sect2"
><H2
CLASS="sect2"
><A
NAME="AEN920"
></A
>7.1.3. Stream with VLS</H2
><P
>&#13;There is no command line interface for this input
for the moment, so you will have to use the configuration file
.</P
><P
>&#13;You cannot set-up the parameters of the drivers
(norm, size, frequency, bitrate, etc...) with VLS: for that, you will
have to use the program <B
CLASS="command"
>ptune.pl</B
> that come with the
drivers. Please refer to the documentation shipped with the drivers to
learn how to use this program
.</P
><P
>&#13;Here is a typical configuration file
<TT
CLASS="filename"
>vls.cfg</TT
>to run VLS with a Hauppauge WinTV-PVR-250
encoding card
:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="programlisting"
>&#13;# vls.cfg (VLS configuration file)
# Example of the VideoLAN HOWTO for the Hauppauge WinTV-PVR-250 encoding card
BEGIN "Inputs"
pvr = "video"
END
BEGIN "pvr"
# Hauppauge WinTV-PVR-250 device
Device = "/dev/video0"
# Stream type
Type = "Mpeg2-PS"
END
BEGIN "Channels"
channel1 = "network"
END
BEGIN "channel1"
# Unicast or multicast IP address
DstHost = "192.168.0.42"
# Destination port
DstPort = "1234"
# If it's a multicast IP address, uncomment the line below
#Type = "multicast"
# If it's a multicast IP address, set the "Time To Live" below
#TTL = "12"
END
BEGIN "LaunchOnStartUp"
command1 = "start video channel1 pvr"
END
</PRE
></FONT
></TD
></TR
></TABLE
><P
>&#13;Once you have adapted the configuration file above,
run VLS
:</P
><TABLE
BORDER="0"
BGCOLOR="#E0E0E0"
WIDTH="100%"
><TR
><TD
><FONT
COLOR="#000000"
><PRE
CLASS="screen"
>&#13;<TT
CLASS="prompt"
>% </TT
><TT
CLASS="userinput"
><B
>vls -vv -f vls.cfg</B
></TT
>
</PRE
></FONT
></TD
></TR
></TABLE
></DIV
></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="hardencoding.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="x932.html"
ACCESSKEY="N"
>Next</A
></TD
></TR
><TR
><TD
WIDTH="33%"
ALIGN="left"
VALIGN="top"
>Stream from an MPEG encoding card</TD
><TD
WIDTH="34%"
ALIGN="center"
VALIGN="top"
><A
HREF="hardencoding.html"
ACCESSKEY="U"
>Up</A
></TD
><TD
WIDTH="33%"
ALIGN="right"
VALIGN="top"
>Stream with the Visiontech Kfir card</TD
></TR
></TABLE
></DIV
></BODY
></HTML
>