Commit 106d2dfb authored by Damien Lucas's avatar Damien Lucas

In prevision of the release:

   . Correct the maximum PIDs filters to set (256 instead of 32)
   . Add a parameter to choose between sending the whole program or
     sending only the MPEG2 pids (some may want to look at dvb subtitles)
   . Fixed the NewPAT bug (by adding the correct Release)

DVB input have been tested with Nova Card not yet with DVB-S. Please report
any problem.
parent 1ca0c6c7
......@@ -8,7 +8,7 @@
url="mailto:asmax@via.ecp.fr" name="<asmax@via.ecp.fr>">
<date>
$Id: vls-guide.sgml,v 1.21 2002/10/04 11:32:30 alexis Exp $
$Id: vls-guide.sgml,v 1.22 2002/10/08 21:52:58 nitrox Exp $
</date>
<abstract>
This document describes how to install, configure, and run the VideoLAN Server
......@@ -629,6 +629,8 @@ BEGIN "DvbInputName"
LNB_Lof1 = "lnb_lof1"
LNB_Lof2 = "lnb_lof2"
LNB_SLof = "lnb_slof"
SendMethod = "0"
END
</verb>
<tscreen>
......@@ -636,11 +638,13 @@ END
"devicenumber" is the number of the DVB device you want to read from
(read from /dev/ost/dvr&lt;devicenumber&gt;, default is "").
"frequency" is the frequency of the transponder given in kHz.
"polarization" is "0" or "1". "symrate" is the symbol rate. "diseqc"
is the DiSEqC address of the used LNB. "lnb_lof1" is the local
"polarization" is "1" (Horizontal) or "0" (Vertical). "symrate"
is the symbol rate. "diseqc" is the DiSEqC address of the used
LNB. "lnb_lof1" is the local
frequency of lower LNB band. "lnb_lof2" is the local frequency of
upper LNB band. "lnb_slof" is the Switch frequency of LNB. All the
frequencies are given in kHz.
frequencies are given in kHz. "SendMethod" is "0" (All datas are
sent) or "1" (only MPEG2 datas are sent).
</tscreen>
</tscreen>
......
......@@ -2,9 +2,10 @@
* dvbinput.cpp: DVB streams
*-------------------------------------------------------------------------------
* (c)1999-2002 VideoLAN
* $Id: dvbinput.cpp,v 1.15 2002/10/07 15:15:20 tooney Exp $
* $Id: dvbinput.cpp,v 1.16 2002/10/08 21:52:58 nitrox Exp $
*
* Authors: Arnaud de Bossoreille de Ribou <bozo@via.ecp.fr>
* Damien Lucas <nitrox@videolan.org>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
......@@ -111,7 +112,7 @@ C_DvbInput::C_DvbInput(C_Module* pModule,
m_cCurrentPat(0, 0, true)
{
m_pConverter = NULL;
for(int i =0; i < 64; i++)
for(int i =0; i < 512; i++)
m_iDemuxes[i] = -1;
}
......@@ -152,6 +153,8 @@ void C_DvbInput::OnInit()
m_iLnbLof2 = pApp->GetSetting(GetName() + ".LNB_Lof2", "0").ToInt();
m_iLnbSLof = pApp->GetSetting(GetName() + ".LNB_SLof", "0").ToInt();
m_iSendMethod = pApp->GetSetting(GetName() + ".SendMethod", "0").ToInt();
// Hardware initialization
SecControl();
SetFrontend();
......@@ -267,14 +270,15 @@ C_List<C_Program> C_DvbInput::OnGetAvailablePgrms()
void C_DvbInput::OnSelectPid(u16 iPid, u8 iType)
{
int i;
for(i = 0; (i < 32) && (m_iDemuxes[2 * i] != -1); i++);
for(i = 0; (i < 256) && (m_iDemuxes[2 * i] != -1); i++);
if(i < 32)
if(i < 256)
{
// We don't need to send PES unknown by vlc
// We don't always need to send PES unknown by vlc
// Thx to Marian Durkovic
// but we may want to have private datas like subtitles
if(iType < TS_TYPE_MPEG2_PRIVATE)
if((m_iSendMethod == 0) || (iType < TS_TYPE_MPEG2_PRIVATE))
{
int iFd = open(m_strDemux.GetString(), O_RDWR|O_NONBLOCK);
......@@ -349,9 +353,9 @@ void C_DvbInput::OnSelectPid(u16 iPid, u8 iType)
void C_DvbInput::OnUnselectPid(u16 iPid)
{
int i;
for(i = 0; (i < 32) && (m_iDemuxes[2 * i] != iPid); i++);
for(i = 0; (i < 256) && (m_iDemuxes[2 * i] != iPid); i++);
if(i < 32)
if(i < 256)
{
ASSERT(m_iDemuxes[2 * i] == iPid);
ioctl(m_iDemuxes[2 * i + 1], DMX_STOP);
......@@ -435,6 +439,7 @@ void C_DvbInput::OnDvbPsiPatEvent(int iEvent)
// Kludge: signal the first PAT arrival.
m_cEndInit.Protect();
m_cEndInit.Signal();
m_cEndInit.Release();
}
}
......
......@@ -2,7 +2,7 @@
* dvbinput.h: DVB Input class definition
*-------------------------------------------------------------------------------
* (c)1999-2002 VideoLAN
* $Id: dvbinput.h,v 1.7 2002/09/26 16:05:32 jpsaman Exp $
* $Id: dvbinput.h,v 1.8 2002/10/08 21:52:58 nitrox Exp $
*
* Authors: Arnaud de Bossoreille de Ribou <bozo@via.ecp.fr>
*
......@@ -84,11 +84,13 @@ private:
int m_iLnbLof2;
int m_iLnbSLof;
int m_iSendMethod;
// Kludge: signal the first PAT arrival.
C_Condition m_cEndInit;
// Demuxes' file descriptors
int m_iDemuxes[64];
int m_iDemuxes[512];
// Only one netlist for all the programs
C_NetList m_cTsProvider;
......
......@@ -75,6 +75,9 @@ BEGIN "dvb"
# LNB_Lof1 = "9750000" # Local frequency of lower LNB band
# LNB_Lof2 = "10600000" # Local frequency of upper LNB band
# LNB_SLof = "11700000" # Switch frequency of LNB
# SendMethod ="0" # 0 - Send All Pids
# 1 - Send only MPEG2 datas
END
# Channel (outputs) declaration
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment